This repository was archived by the owner on Sep 27, 2019. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Expand file tree Collapse file tree 1 file changed +8
-6
lines changed Original file line number Diff line number Diff line change @@ -55,14 +55,13 @@ function install_protobuf3.4.0() {
55
55
echo " Only Ubuntu and Fedora is supported currently!"
56
56
return 0
57
57
fi
58
- CWD=` pwd`
59
- cd $TMPDIR
60
58
wget -O protobuf-cpp-3.4.0.tar.gz https://github.com/google/protobuf/releases/download/v3.4.0/protobuf-cpp-3.4.0.tar.gz
61
59
tar -xzf protobuf-cpp-3.4.0.tar.gz
62
60
cd protobuf-3.4.0
63
61
./autogen.sh && ./configure && make -j4 && sudo make install && sudo ldconfig
64
- # Do cleanup
65
- cd $CWD
62
+ cd ..
63
+ # Cleanup
64
+ rm -rf protobuf-3.4.0 protobuf-cpp-3.4.0.tar.gz
66
65
}
67
66
68
67
# Utility function for installing tensorflow components of python/C++
@@ -72,14 +71,16 @@ function install_tf() {
72
71
LinkerConfigCmd=$3
73
72
TARGET_DIRECTORY=" /usr/local"
74
73
# Install Tensorflow Python Binary
75
- sudo pip3 install --upgrade ${TFBinaryURL}
74
+ sudo -E pip3 install --upgrade ${TFBinaryURL}
76
75
77
76
# Install C-API
78
77
TFCApiURL=" https://storage.googleapis.com/tensorflow/libtensorflow/${TFCApiFile} "
79
78
wget -O $TFCApiFile $TFCApiURL
80
- sudo tar -C $TARGET_DIRECTORY -xzf $TFCApiFile
79
+ sudo tar -C $TARGET_DIRECTORY -xzf $TFCApiFile || true
81
80
# Configure the Linker
82
81
eval $LinkerConfigCmd
82
+ # Cleanup
83
+ rm -rf ${TFCApiFile}
83
84
}
84
85
85
86
# # ------------------------------------------------
@@ -333,6 +334,7 @@ elif [ "$DISTRO" = "DARWIN" ]; then
333
334
334
335
brew install postgresql
335
336
brew install curl
337
+ brew install wget
336
338
brew install python
337
339
brew upgrade python
338
340
# Brew installs correct version of Protobuf(3.5.1 >= 3.4.0)
You can’t perform that action at this time.
0 commit comments