From d7fa74b226bdf7c4fea541ce0745e707c7a4558d Mon Sep 17 00:00:00 2001 From: Yao Wang Date: Thu, 3 Dec 2020 18:13:44 +0000 Subject: [PATCH 1/2] Update CI to use Thrust for GPU --- docker/Dockerfile.ci_gpu | 3 +++ docker/install/install_ubuntu_cmake.sh | 25 +++++++++++++++++++++++++ tests/scripts/task_config_build_gpu.sh | 1 + 3 files changed, 29 insertions(+) create mode 100644 docker/install/install_ubuntu_cmake.sh diff --git a/docker/Dockerfile.ci_gpu b/docker/Dockerfile.ci_gpu index ac76af6b0a1e..cd48e3802d7a 100644 --- a/docker/Dockerfile.ci_gpu +++ b/docker/Dockerfile.ci_gpu @@ -40,6 +40,9 @@ RUN bash /install/ubuntu_install_python_package.sh COPY install/ubuntu_install_sphinx.sh /install/ubuntu_install_sphinx.sh RUN bash /install/ubuntu_install_sphinx.sh +COPY install/ubuntu_install_cmake.sh /install/ubuntu_install_cmake.sh +RUN bash /install/ubuntu_install_cmake.sh + # Enable doxygen for c++ doc build RUN apt-get update && apt-get install -y doxygen libprotobuf-dev protobuf-compiler diff --git a/docker/install/install_ubuntu_cmake.sh b/docker/install/install_ubuntu_cmake.sh new file mode 100644 index 000000000000..8403bb1c8d76 --- /dev/null +++ b/docker/install/install_ubuntu_cmake.sh @@ -0,0 +1,25 @@ +#!/bin/bash +# Licensed to the Apache Software Foundation (ASF) under one +# or more contributor license agreements. See the NOTICE file +# distributed with this work for additional information +# regarding copyright ownership. The ASF licenses this file +# to you under the Apache License, Version 2.0 (the +# "License"); you may not use this file except in compliance +# with the License. You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, +# software distributed under the License is distributed on an +# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +# KIND, either express or implied. See the License for the +# specific language governing permissions and limitations +# under the License. + +sudo apt install build-essential libssl-dev -y +wget https://github.com/Kitware/CMake/releases/download/v3.16.5/cmake-3.16.5.tar.gz +tar -zxvf cmake-3.16.5.tar.gz +cd cmake-3.16.5 +./bootstrap +make +sudo make install diff --git a/tests/scripts/task_config_build_gpu.sh b/tests/scripts/task_config_build_gpu.sh index 155bac80533f..216e3a6e4426 100755 --- a/tests/scripts/task_config_build_gpu.sh +++ b/tests/scripts/task_config_build_gpu.sh @@ -45,3 +45,4 @@ echo set\(USE_BLAS openblas\) >> config.cmake echo set\(CMAKE_CXX_COMPILER g++\) >> config.cmake echo set\(CMAKE_CXX_FLAGS -Werror\) >> config.cmake echo set\(USE_TENSORRT_CODEGEN ON\) >> config.cmake +echo set\(USE_THRUST ON\) >> config.cmake From 5c5ab19a072fb9c7dbad873ee91814e571a6213f Mon Sep 17 00:00:00 2001 From: Yao Wang Date: Thu, 3 Dec 2020 19:25:57 +0000 Subject: [PATCH 2/2] Remove Thrust enabling in this PR --- tests/scripts/task_config_build_gpu.sh | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/scripts/task_config_build_gpu.sh b/tests/scripts/task_config_build_gpu.sh index 216e3a6e4426..155bac80533f 100755 --- a/tests/scripts/task_config_build_gpu.sh +++ b/tests/scripts/task_config_build_gpu.sh @@ -45,4 +45,3 @@ echo set\(USE_BLAS openblas\) >> config.cmake echo set\(CMAKE_CXX_COMPILER g++\) >> config.cmake echo set\(CMAKE_CXX_FLAGS -Werror\) >> config.cmake echo set\(USE_TENSORRT_CODEGEN ON\) >> config.cmake -echo set\(USE_THRUST ON\) >> config.cmake