This is an automated email from the ASF dual-hosted git repository.

mssun pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-teaclave.git


The following commit(s) were added to refs/heads/master by this push:
     new d5bd1b6  Add TVM in the docker image (#536)
d5bd1b6 is described below

commit d5bd1b6ffc35d3610b819aba4174b23cda38acb6
Author: Hongbo <[email protected]>
AuthorDate: Wed Aug 4 19:06:33 2021 -0400

    Add TVM in the docker image (#536)
---
 docker/build.ubuntu-1804.sgx-2.14.Dockerfile      | 13 +++++++++++++
 docker/build.ubuntu-1804.sgx-dcap-1.11.Dockerfile | 15 ++++++++++++++-
 2 files changed, 27 insertions(+), 1 deletion(-)

diff --git a/docker/build.ubuntu-1804.sgx-2.14.Dockerfile 
b/docker/build.ubuntu-1804.sgx-2.14.Dockerfile
index b120fad..6baa248 100644
--- a/docker/build.ubuntu-1804.sgx-2.14.Dockerfile
+++ b/docker/build.ubuntu-1804.sgx-2.14.Dockerfile
@@ -96,6 +96,19 @@ RUN apt-get install -q -y \
 # TVM Python builder dependencies
 RUN pip3 install onnx==1.9.0 numpy decorator attrs spicy
 
+# Build TVM
+RUN git clone https://github.com/apache/tvm /tvm                && \
+    cd /tvm                                                     && \
+    git checkout df06c5848f59108a8e6e7dffb997b4b659b573a7       && \
+    git submodule init                                          && \
+    git submodule update                                        && \
+    mkdir build                                                 && \
+    cd build                                                    && \
+    cp ../cmake/config.cmake ./                                 && \
+    sed -i '/set(USE_LLVM OFF)/c\set(USE_LLVM ON)' config.cmake && \
+    cmake -DUSE_LLVM=ON ..                                      && \
+    make -j$(nproc)
+
 # clean up apt caches
 
 RUN apt-get clean && \
diff --git a/docker/build.ubuntu-1804.sgx-dcap-1.11.Dockerfile 
b/docker/build.ubuntu-1804.sgx-dcap-1.11.Dockerfile
index 592c372..fd1804f 100644
--- a/docker/build.ubuntu-1804.sgx-dcap-1.11.Dockerfile
+++ b/docker/build.ubuntu-1804.sgx-dcap-1.11.Dockerfile
@@ -75,7 +75,7 @@ RUN apt-get update && apt-get install -q -y \
     pypy-dev
 
 RUN add-apt-repository ppa:git-core/ppa && \
-  apt-get update && apt-get install -q -y git
+    apt-get update && apt-get install -q -y git
 
 # install dependencies for testing and coverage
 
@@ -104,6 +104,19 @@ RUN apt-get install -q -y \
 # TVM Python builder dependencies
 RUN pip3 install onnx==1.9.0 numpy decorator attrs spicy
 
+# Build TVM
+RUN git clone https://github.com/apache/tvm /tvm                && \
+    cd /tvm                                                     && \
+    git checkout df06c5848f59108a8e6e7dffb997b4b659b573a7       && \
+    git submodule init                                          && \
+    git submodule update                                        && \
+    mkdir build                                                 && \
+    cd build                                                    && \
+    cp ../cmake/config.cmake ./                                 && \
+    sed -i '/set(USE_LLVM OFF)/c\set(USE_LLVM ON)' config.cmake && \
+    cmake -DUSE_LLVM=ON ..                                      && \
+    make -j$(nproc)
+
 # clean up apt caches
 
 RUN apt-get clean && \

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to