Skip to content

Commit 40fb015

Browse files
committed
Add a bash script to automcatically install requirements on Ubuntu
1 parent 5667be0 commit 40fb015

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

install-requirements.sh

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
#!/bin/bash
2+
set -e
3+
4+
# install requirements
5+
export DEBIAN_FRONTEND=noninteractive
6+
apt-get -y update
7+
apt-get -y install \
8+
cmake \
9+
g++-7 \
10+
git \
11+
python3-dev \
12+
python3-numpy \
13+
sudo \
14+
wget
15+
16+
# install bazel
17+
export BAZEL_VERSION=${BAZEL_VERSION:-`cat ./Dockerfiles/BAZEL_VERSION`}
18+
apt-get -y install pkg-config zip g++ zlib1g-dev unzip python
19+
bazel_installer=bazel-${BAZEL_VERSION}-installer-linux-x86_64.sh
20+
wget -P /tmp https://github.com/bazelbuild/bazel/releases/download/${BAZEL_VERSION}/${bazel_installer}
21+
chmod +x /tmp/${bazel_installer}
22+
/tmp/${bazel_installer}
23+
rm /tmp/${bazel_installer}
24+
25+
if [[ ${BUILD_WITH_CUDA:-"OFF"} == "ON" ]]; then
26+
# install libcupti
27+
apt-get -y install cuda-command-line-tools-10-1
28+
fi

0 commit comments

Comments
 (0)