@@ -13,11 +13,11 @@ Step 1: Install some build dependencies
13
13
.. code-block :: bash
14
14
15
15
$ apt-get update
16
- $ apt-get install -y libgoogle-glog-dev curl build-essential cmake git automake libgmp3-dev libtool ssh libyaml-dev realpath wget valgrind software-properties-common unzip
16
+ $ apt-get install -y libgoogle-glog-dev curl build-essential cmake git automake libgmp3-dev libtool ssh libyaml-dev realpath wget valgrind software-properties-common unzip libz-dev
17
17
18
18
.. note ::
19
19
20
- You might additionally need to install :code: `cmake3 ` and :code: ` libz-dev ` , if these packages are not found by apt-get, you can proceed otherwise install them by running :code: ` apt-get install libz-dev `
20
+ You might additionally need to install :code: `cmake3 `, if this package is not found by apt-get, you can proceed.
21
21
22
22
Step 2: Setup gcc / g++
23
23
^^^^^^^^^^^^^^^^^^^^^^^
@@ -70,10 +70,11 @@ Now, clone the repo, build and install LLVM+Tapir:
70
70
71
71
$ git clone --recursive https://github.com/wsmoses/Tapir-LLVM llvm
72
72
$ mkdir -p ${LLVM_SOURCES} /llvm_build && cd ${LLVM_SOURCES} /llvm_build
73
- $ ${CMAKE_VERSION} -DCMAKE_INSTALL_PREFIX=${CLANG_PREFIX} -DLLVM_TARGETS_TO_BUILD=X86 -DCOMPILER_RT_BUILD_CILKTOOLS=OFF -DLLVM_ENABLE_CXX1Y=ON -DLLVM_ENABLE_TERMINFO=OFF -DLLVM_BUILD_TESTS=OFF -DLLVM_ENABLE_ASSERTIONS=ON -DCMAKE_BUILD_TYPE=Release -DLLVM_BUILD_LLVM_DYLIB=ON -DLLVM_ENABLE_RTTI=ON ../llvm/
73
+ $ ${CMAKE_VERSION} -DLLVM_ENABLE_OCAMLDOC=OFF -DLLVM_INSTALL_OCAMLDOC_HTML_DIR=/tmp -DLLVM_OCAML_INSTALL_PATH=/tmp - DCMAKE_INSTALL_PREFIX=${CLANG_PREFIX} -DLLVM_TARGETS_TO_BUILD=X86 -DCOMPILER_RT_BUILD_CILKTOOLS=OFF -DLLVM_ENABLE_CXX1Y=ON -DLLVM_ENABLE_TERMINFO=OFF -DLLVM_BUILD_TESTS=OFF -DLLVM_ENABLE_ASSERTIONS=ON -DCMAKE_BUILD_TYPE=Release -DLLVM_BUILD_LLVM_DYLIB=ON -DLLVM_ENABLE_RTTI=ON ../llvm/
74
74
$ make -j $CORES -s && make install -j $CORES -s
75
75
$ cd $HOME && rm -rf $LLVM_SOURCES
76
76
77
+
77
78
Step 4: Get CUDA and CUDNN
78
79
^^^^^^^^^^^^^^^^^^^^^^^^^^
79
80
In order to build TC, you also need to have :code: `CUDA ` and :code: `CUDNN `. If you already have it
@@ -97,9 +98,14 @@ Now, Install cuDNN v6.0 (skip if you have it already):
97
98
$ CUDNN_TAR_FILE=" cudnn-8.0-linux-x64-v6.0.tgz"
98
99
$ wget http://developer.download.nvidia.com/compute/redist/cudnn/v6.0/${CUDNN_TAR_FILE}
99
100
$ tar -xzvf ${CUDNN_TAR_FILE}
100
- $ sudo cp -P cuda/include/cudnn.h /usr/local/cuda/include
101
- $ sudo cp -P cuda/lib64/libcudnn* /usr/local/cuda/lib64/
102
- $ sudo chmod a+r /usr/local/cuda/lib64/libcudnn*
101
+ $ cp -P cuda/include/cudnn.h /usr/local/cuda/include
102
+ $ cp -P cuda/lib64/libcudnn* /usr/local/cuda/lib64/
103
+ $ chmod a+r /usr/local/cuda/lib64/libcudnn*
104
+
105
+ .. note ::
106
+
107
+ Please use :code: `sudo ` to run the command that might fail with permission issues. Otherwise, run
108
+ the commands as is.
103
109
104
110
Set environment variables:
105
111
@@ -118,7 +124,12 @@ to install the protobuf.
118
124
119
125
$ mkdir -p /tmp/proto-install && cd /tmp/proto-install
120
126
$ wget --quiet https://github.com/google/protobuf/archive/v3.4.0.zip -O proto.zip && unzip -qq proto.zip -d .
121
- $ cd protobuf-3.4.0 && ./autogen.sh && ./configure && make -j 8 && sudo make install && sudo ldconfig
127
+ $ cd protobuf-3.4.0 && ./autogen.sh && ./configure && make -j 8 && make install && ldconfig
128
+
129
+ .. note ::
130
+
131
+ Please use :code: `sudo ` to run the command that might fail with permission issues. Otherwise, run
132
+ the commands as is.
122
133
123
134
Now check your proto version by running:
124
135
@@ -136,7 +147,7 @@ dependencies and updating your Python:
136
147
137
148
.. code-block :: bash
138
149
139
- $ sudo apt-get install -y python3-dev python3-pip python3-setuptools
150
+ $ apt-get install -y python3-dev python3-pip python3-setuptools
140
151
$ pip3 install --upgrade pip
141
152
$ pip3 install numpy pyyaml
142
153
0 commit comments