File tree Expand file tree Collapse file tree 2 files changed +37
-19
lines changed
Expand file tree Collapse file tree 2 files changed +37
-19
lines changed Original file line number Diff line number Diff line change @@ -13,25 +13,7 @@ for key in "$@"; do
1313done
1414
1515# install requirements
16- export DEBIAN_FRONTEND=noninteractive
17- apt-get -y update
18- apt-get -y install \
19- cmake \
20- g++-7 \
21- git \
22- python3-dev \
23- python3-numpy \
24- sudo \
25- wget
26-
27- # install bazel
28- export BAZEL_VERSION=${BAZEL_VERSION:- `cat ./ tensorflow_cc/ Dockerfiles/ BAZEL_VERSION`}
29- apt-get -y install pkg-config zip g++ zlib1g-dev unzip python
30- bazel_installer=bazel-${BAZEL_VERSION} -installer-linux-x86_64.sh
31- wget -P /tmp https://github.com/bazelbuild/bazel/releases/download/${BAZEL_VERSION} /${bazel_installer}
32- chmod +x /tmp/${bazel_installer}
33- /tmp/${bazel_installer}
34- rm /tmp/${bazel_installer}
16+ ./tensorflow_cc/ubuntu-requirements.sh
3517
3618if $cuda ; then
3719 # install libcupti
Original file line number Diff line number Diff line change 1+ #! /bin/bash
2+ set -e
3+
4+ if [[ $UID != 0 ]]; then
5+ echo " Please run this script with sudo:"
6+ echo " sudo $0 $* "
7+ exit 1
8+ fi
9+
10+ if [[ " $OSTYPE " == " linux-gnu" ]]; then
11+ # install requirements
12+ export DEBIAN_FRONTEND=noninteractive
13+ apt-get -y update
14+ apt-get -y install \
15+ cmake \
16+ g++-7 \
17+ git \
18+ python3-dev \
19+ python3-numpy \
20+ sudo \
21+ wget
22+
23+ # install bazel
24+ export BAZEL_VERSION=${BAZEL_VERSION:- `cat $(dirname " $0 " )/ Dockerfiles/ BAZEL_VERSION`}
25+ apt-get -y install pkg-config zip g++ zlib1g-dev unzip python
26+ bazel_installer=bazel-${BAZEL_VERSION} -installer-linux-x86_64.sh
27+ wget -P /tmp https://github.com/bazelbuild/bazel/releases/download/${BAZEL_VERSION} /${bazel_installer}
28+ chmod +x /tmp/${bazel_installer}
29+ /tmp/${bazel_installer}
30+ rm /tmp/${bazel_installer}
31+
32+ else
33+ echo " This script supports only Debian-based operating systems (like Ubuntu)." \
34+ " Please consult README file for manual installation on your '$OSTYPE ' OS."
35+ exit 1
36+ fi
You can’t perform that action at this time.
0 commit comments