[med-svn] [Git][med-team/fast][master] 2 commits: Prevent tensorflow download as this is not even needed in the project
Shayan Doust
gitlab at salsa.debian.org
Fri Aug 9 16:17:44 BST 2019
Shayan Doust pushed to branch master at Debian Med / fast
Commits:
645b441f by Shayan Doust at 2019-08-09T01:44:32Z
Prevent tensorflow download as this is not even needed in the project
- - - - -
61aac010 by Shayan Doust at 2019-08-09T04:01:52Z
Use libdcmtk-dev instead of local download and compilation
- - - - -
3 changed files:
- debian/control
- debian/patches/prevent_cmake_downloading.patch
- debian/patches/use_system_libs.patch
Changes:
=====================================
debian/control
=====================================
@@ -15,6 +15,7 @@ Build-Depends: debhelper-compat (= 12),
ocl-icd-opencl-dev,
libopenslide-dev,
libopenigtlink-dev,
+ libdcmtk-dev,
git
Standards-Version: 4.3.0
Vcs-Browser: https://salsa.debian.org/med-team/fast
=====================================
debian/patches/prevent_cmake_downloading.patch
=====================================
@@ -6,8 +6,8 @@ Last-Update: 2019-08-08
Index: fast/cmake/ExternalEigen.cmake
===================================================================
---- fast.orig/cmake/ExternalEigen.cmake 2019-08-08 19:27:20.692513417 +0100
-+++ fast/cmake/ExternalEigen.cmake 2019-08-08 19:27:20.684513350 +0100
+--- fast.orig/cmake/ExternalEigen.cmake 2019-08-09 02:46:34.137292526 +0100
++++ fast/cmake/ExternalEigen.cmake 2019-08-09 02:46:34.129292460 +0100
@@ -1,21 +1,21 @@
# Download and set up Eigen
@@ -50,8 +50,8 @@ Index: fast/cmake/ExternalEigen.cmake
+#list(APPEND FAST_EXTERNAL_DEPENDENCIES eigen)
Index: fast/cmake/ExternalOpenSlide.cmake
===================================================================
---- fast.orig/cmake/ExternalOpenSlide.cmake 2019-08-08 19:27:20.692513417 +0100
-+++ fast/cmake/ExternalOpenSlide.cmake 2019-08-08 19:27:20.684513350 +0100
+--- fast.orig/cmake/ExternalOpenSlide.cmake 2019-08-09 02:46:34.137292526 +0100
++++ fast/cmake/ExternalOpenSlide.cmake 2019-08-09 02:46:34.129292460 +0100
@@ -1,17 +1,17 @@
# Download and set up OpenSlide
@@ -85,8 +85,8 @@ Index: fast/cmake/ExternalOpenSlide.cmake
+#endif()
Index: fast/cmake/ExternalZlib.cmake
===================================================================
---- fast.orig/cmake/ExternalZlib.cmake 2019-08-08 19:27:20.692513417 +0100
-+++ fast/cmake/ExternalZlib.cmake 2019-08-08 19:27:20.688513383 +0100
+--- fast.orig/cmake/ExternalZlib.cmake 2019-08-09 02:46:34.137292526 +0100
++++ fast/cmake/ExternalZlib.cmake 2019-08-09 02:46:34.129292460 +0100
@@ -1,24 +1,24 @@
# Download and set up zlib
@@ -136,8 +136,8 @@ Index: fast/cmake/ExternalZlib.cmake
+#list(APPEND FAST_EXTERNAL_DEPENDENCIES zlib)
Index: fast/cmake/ExternalOpenIGTLink.cmake
===================================================================
---- fast.orig/cmake/ExternalOpenIGTLink.cmake 2019-08-08 19:21:36.965659511 +0100
-+++ fast/cmake/ExternalOpenIGTLink.cmake 2019-08-08 19:27:50.364759670 +0100
+--- fast.orig/cmake/ExternalOpenIGTLink.cmake 2019-08-09 02:46:34.137292526 +0100
++++ fast/cmake/ExternalOpenIGTLink.cmake 2019-08-09 02:46:34.129292460 +0100
@@ -1,30 +1,30 @@
# Download and set up zlib
@@ -196,3 +196,470 @@ Index: fast/cmake/ExternalOpenIGTLink.cmake
+#endif()
+#list(APPEND LIBRARIES ${OpenIGTLink_LIBRARY})
+#list(APPEND FAST_EXTERNAL_DEPENDENCIES OpenIGTLink)
+Index: fast/cmake/ExternalFreenect2.cmake
+===================================================================
+--- fast.orig/cmake/ExternalFreenect2.cmake 2019-08-09 02:46:34.137292526 +0100
++++ fast/cmake/ExternalFreenect2.cmake 2019-08-09 02:46:34.129292460 +0100
+@@ -1,20 +1,20 @@
+ # Download and set up libfreenect2
+
+-include(cmake/Externals.cmake)
++#include(cmake/Externals.cmake)
+
+-ExternalProject_Add(freenect2
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/freenect2
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/freenect2
+- GIT_REPOSITORY "https://github.com/OpenKinect/libfreenect2.git"
+- GIT_TAG "v0.2.0"
+- CMAKE_ARGS
+- -DENABLE_VAAPI:BOOL=OFF
+- CMAKE_CACHE_ARGS
+- -DCMAKE_BUILD_TYPE:STRING=Release
+- -DCMAKE_VERBOSE_MAKEFILE:BOOL=OFF
+- -DCMAKE_INSTALL_MESSAGE:BOOL=LAZY
+- -DCMAKE_INSTALL_PREFIX:STRING=${FAST_EXTERNAL_INSTALL_DIR}
+- )
++#ExternalProject_Add(freenect2
++# PREFIX ${FAST_EXTERNAL_BUILD_DIR}/freenect2
++# BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/freenect2
++# GIT_REPOSITORY "https://github.com/OpenKinect/libfreenect2.git"
++# GIT_TAG "v0.2.0"
++# CMAKE_ARGS
++# -DENABLE_VAAPI:BOOL=OFF
++# CMAKE_CACHE_ARGS
++# -DCMAKE_BUILD_TYPE:STRING=Release
++# -DCMAKE_VERBOSE_MAKEFILE:BOOL=OFF
++# -DCMAKE_INSTALL_MESSAGE:BOOL=LAZY
++# -DCMAKE_INSTALL_PREFIX:STRING=${FAST_EXTERNAL_INSTALL_DIR}
++# )
+
+-list(APPEND LIBRARIES libfreenect2${CMAKE_SHARED_LIBRARY_SUFFIX})
+-list(APPEND FAST_EXTERNAL_DEPENDENCIES freenect2)
++#list(APPEND LIBRARIES libfreenect2${CMAKE_SHARED_LIBRARY_SUFFIX})
++#list(APPEND FAST_EXTERNAL_DEPENDENCIES freenect2)
+Index: fast/cmake/ExternalTensorflow.cmake
+===================================================================
+--- fast.orig/cmake/ExternalTensorflow.cmake 2019-08-09 02:46:34.137292526 +0100
++++ fast/cmake/ExternalTensorflow.cmake 2019-08-09 02:46:34.133292493 +0100
+@@ -1,177 +1,177 @@
+ # Download and set up Tensorflow
+
+-include(${PROJECT_SOURCE_DIR}/cmake/Externals.cmake)
++#include(${PROJECT_SOURCE_DIR}/cmake/Externals.cmake)
+
+-if(WIN32)
+- set(GIT_EXECUTABLE "git.exe")
++#if(WIN32)
++# set(GIT_EXECUTABLE "git.exe")
+ # Use CMake to build tensorflow on windows
+- ExternalProject_Add(tensorflow
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- GIT_REPOSITORY "https://github.com/smistad/tensorflow.git"
+- GIT_TAG "fast"
+- # Need to override this because tensorflow creates a file in the source dir
+- # and cmake files to stash these files
+- UPDATE_COMMAND
+- ${GIT_EXECUTABLE} pull origin fast
+- # Must use CONFIGURE_COMMAND because CMakeLists.txt is not in the src root of tensorflow
+- CONFIGURE_COMMAND
+- ${CMAKE_COMMAND}
+- ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/tensorflow/contrib/cmake/
+- -G${CMAKE_GENERATOR}
+- -Thost=x64
+- -DCMAKE_BUILD_TYPE:STRING=Release
+- -Dtensorflow_BUILD_PYTHON_BINDINGS=OFF
+- -Dtensorflow_ENABLE_SNAPPY_SUPPORT=ON
+- -Dtensorflow_BUILD_CC_EXAMPLE=OFF
+- -Dtensorflow_BUILD_SHARED_LIB=ON
+- -Dtensorflow_BUILD_CONTRIB_KERNELS=OFF
+- -Dtensorflow_ENABLE_GRPC_SUPPORT=OFF
+- -Dtensorflow_WIN_CPU_SIMD_OPTIONS=/arch:AVX
+- #-Dtensorflow_ENABLE_GPU=ON
+- -DCMAKE_VERBOSE_MAKEFILE:BOOL=OFF
+- -DCMAKE_INSTALL_MESSAGE:BOOL=LAZY
+- -DCMAKE_INSTALL_PREFIX:STRING=${FAST_EXTERNAL_INSTALL_DIR}
+- )
+-else(WIN32)
++ # ExternalProject_Add(tensorflow
++ # PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # GIT_REPOSITORY "https://github.com/smistad/tensorflow.git"
++ # GIT_TAG "fast"
++ # # Need to override this because tensorflow creates a file in the source dir
++ # # and cmake files to stash these files
++ # UPDATE_COMMAND
++ # ${GIT_EXECUTABLE} pull origin fast
++ # # Must use CONFIGURE_COMMAND because CMakeLists.txt is not in the src root of tensorflow
++ # CONFIGURE_COMMAND
++ # ${CMAKE_COMMAND}
++ # ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/tensorflow/contrib/cmake/
++ # -G${CMAKE_GENERATOR}
++ # -Thost=x64
++ # -DCMAKE_BUILD_TYPE:STRING=Release
++ # -Dtensorflow_BUILD_PYTHON_BINDINGS=OFF
++ # -Dtensorflow_ENABLE_SNAPPY_SUPPORT=ON
++ # -Dtensorflow_BUILD_CC_EXAMPLE=OFF
++ # -Dtensorflow_BUILD_SHARED_LIB=ON
++ # -Dtensorflow_BUILD_CONTRIB_KERNELS=OFF
++ # -Dtensorflow_ENABLE_GRPC_SUPPORT=OFF
++ # -Dtensorflow_WIN_CPU_SIMD_OPTIONS=/arch:AVX
++ # #-Dtensorflow_ENABLE_GPU=ON
++ # -DCMAKE_VERBOSE_MAKEFILE:BOOL=OFF
++ # -DCMAKE_INSTALL_MESSAGE:BOOL=LAZY
++ # -DCMAKE_INSTALL_PREFIX:STRING=${FAST_EXTERNAL_INSTALL_DIR}
++ # )
++ #else(WIN32)
+ # Use bazel to build tensorflow on linux
+- set(GIT_EXECUTABLE "git")
+- if(FAST_BUILD_TensorFlow_CPU OR FAST_BUILD_TensorFlow_CUDA)
+- ExternalProject_Add(tensorflow_download
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- GIT_REPOSITORY "https://github.com/smistad/tensorflow.git"
+- GIT_TAG "fast-updated"
+- UPDATE_COMMAND ""
+- CONFIGURE_COMMAND ""
+- BUILD_COMMAND ""
+- INSTALL_COMMAND ""
+- )
+- endif()
+- if(FAST_BUILD_TensorFlow_ROCm)
+- # Need a seperate repo for rocm atm
+- ExternalProject_Add(tensorflow_download_rocm
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
+- GIT_REPOSITORY "https://github.com/ROCmSoftwarePlatform/tensorflow-upstream"
+- GIT_TAG "r1.14-rocm"
+- UPDATE_COMMAND ""
+- CONFIGURE_COMMAND ""
+- BUILD_COMMAND ""
+- INSTALL_COMMAND ""
+- )
+- ExternalProject_Add(tensorflow_ROCm
+- DEPENDS tensorflow_download_rocm
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
+- DOWNLOAD_COMMAND ""
+- UPDATE_COMMAND ""
+- # Run TF configure in the form of a shell script.
+- CONFIGURE_COMMAND
+- cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/ && sh ${PROJECT_SOURCE_DIR}/cmake/TensorflowConfigureROCm.sh
+- # Build using bazel
+- BUILD_COMMAND
+- echo "Building tensorflow with bazel and ROCm (AMD) GPU support" &&
+- cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/ && bazel build -c opt --config=rocm //tensorflow:libtensorflow_cc.so
+- INSTALL_COMMAND
+- echo "Installing tensorflow binary" &&
+- cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-bin/tensorflow/libtensorflow_cc.so.1.14.0 ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
+- cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-bin/tensorflow/libtensorflow_framework.so.1.14.0 ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_ROCm.so &&
+- chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
+- chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_ROCm.so &&
+- patchelf --set-soname libtensorflow_cc_ROCm.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
+- patchelf --set-soname libtensorflow_framework_ROCm.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_ROCm.so &&
+- patchelf --replace-needed libtensorflow_framework.so.1 libtensorflow_framework_ROCm.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
+- echo "Installing tensorflow headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing tensorflow generated headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-genfiles/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing tensorflow third_party headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/third_party/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing protobuf headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-out/)/../../../external/protobuf_archive/src/google/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
+- echo "Installing nsync headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-out/)/../../../external/nsync/public/*.h ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
+- echo "Installing absl headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-out/)/../../../external/com_google_absl/absl/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf"
+- )
+- endif()
+- if(FAST_BUILD_TensorFlow_CUDA)
+- ExternalProject_Add(tensorflow_CUDA
+- DEPENDS tensorflow_download
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- DOWNLOAD_COMMAND ""
+- UPDATE_COMMAND ""
+- # Run TF configure in the form of a shell script. CUDA should be installed in /usr/local/cuda
+- CONFIGURE_COMMAND
+- cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && sh ${PROJECT_SOURCE_DIR}/cmake/TensorflowConfigureCUDA.sh
+- # Build using bazel
+- BUILD_COMMAND
+- echo "Building tensorflow with bazel and CUDA GPU support" &&
+- cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && bazel build -c opt --config=cuda --copt=-mfpmath=both --copt=-march=core-avx2 //tensorflow:libtensorflow_cc.so
+- INSTALL_COMMAND
+- echo "Installing tensorflow binary" &&
+- cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_cc.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
+- cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_framework.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CUDA.so &&
+- chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
+- chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CUDA.so &&
+- patchelf --set-soname libtensorflow_cc_CUDA.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
+- patchelf --set-soname libtensorflow_framework_CUDA.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CUDA.so &&
+- patchelf --replace-needed libtensorflow_framework.so libtensorflow_framework_CUDA.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
+- #echo "Installing mkl binaries" &&
+- #bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/mkl/lib/libmklml_intel.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/ -Rf" &&
+- #bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/mkl/lib/libiomp5.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/ -Rf" &&
+- echo "Installing tensorflow headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing tensorflow generated headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-genfiles/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing tensorflow third_party headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/third_party/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing protobuf headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/protobuf_archive/src/google/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
+- echo "Installing nsync headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/nsync/public/*.h ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
+- echo "Installing absl headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/com_google_absl/absl/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf"
+- )
+- endif()
+- if(FAST_BUILD_TensorFlow_CPU)
+- ExternalProject_Add(tensorflow_CPU
+- DEPENDS tensorflow_download
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
+- DOWNLOAD_COMMAND ""
+- UPDATE_COMMAND ""
+- # Run TF configure in the form of a shell script.
+- CONFIGURE_COMMAND
+- cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && sh ${PROJECT_SOURCE_DIR}/cmake/TensorflowConfigureCPU.sh
+- # Build using bazel
+- BUILD_COMMAND
+- echo "Building tensorflow with bazel for CPU" &&
+- cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && bazel build --config=opt --copt=-mfpmath=both --copt=-march=core-avx2 //tensorflow:libtensorflow_cc.so
+- INSTALL_COMMAND
+- echo "Installing tensorflow binary" &&
+- cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_cc.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
+- cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_framework.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CPU.so &&
+- chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
+- chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CPU.so &&
+- patchelf --set-soname libtensorflow_cc_CPU.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
+- patchelf --set-soname libtensorflow_framework_CPU.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CPU.so &&
+- patchelf --replace-needed libtensorflow_framework.so libtensorflow_framework_CPU.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
+- echo "Installing tensorflow headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing tensorflow generated headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-genfiles/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing tensorflow third_party headers" &&
+- cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/third_party/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
+- echo "Installing protobuf headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/protobuf_archive/src/google/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
+- echo "Installing nsync headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/nsync/public/*.h ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
+- echo "Installing absl headers" &&
+- bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/com_google_absl/absl/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf"
+- )
+- endif()
+-endif(WIN32)
++ #set(GIT_EXECUTABLE "git")
++ #if(FAST_BUILD_TensorFlow_CPU OR FAST_BUILD_TensorFlow_CUDA)
++ # ExternalProject_Add(tensorflow_download
++ # PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # GIT_REPOSITORY "https://github.com/smistad/tensorflow.git"
++ # GIT_TAG "fast-updated"
++ # UPDATE_COMMAND ""
++ # CONFIGURE_COMMAND ""
++ # BUILD_COMMAND ""
++ # INSTALL_COMMAND ""
++ # )
++ #endif()
++ #if(FAST_BUILD_TensorFlow_ROCm)
++ # # Need a seperate repo for rocm atm
++ # ExternalProject_Add(tensorflow_download_rocm
++ # PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
++ # BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
++ # GIT_REPOSITORY "https://github.com/ROCmSoftwarePlatform/tensorflow-upstream"
++ # GIT_TAG "r1.14-rocm"
++ # UPDATE_COMMAND ""
++ # CONFIGURE_COMMAND ""
++ # BUILD_COMMAND ""
++ # INSTALL_COMMAND ""
++ # )
++ # ExternalProject_Add(tensorflow_ROCm
++ # DEPENDS tensorflow_download_rocm
++ # PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
++ # BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm
++ # DOWNLOAD_COMMAND ""
++ # UPDATE_COMMAND ""
++ # # Run TF configure in the form of a shell script.
++ # CONFIGURE_COMMAND
++ # cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/ && sh ${PROJECT_SOURCE_DIR}/cmake/TensorflowConfigureROCm.sh
++ # # Build using bazel
++ # BUILD_COMMAND
++ # echo "Building tensorflow with bazel and ROCm (AMD) GPU support" &&
++ # cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/ && bazel build -c opt --config=rocm //tensorflow:libtensorflow_cc.so
++ # INSTALL_COMMAND
++ # echo "Installing tensorflow binary" &&
++ # cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-bin/tensorflow/libtensorflow_cc.so.1.14.0 ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
++ # cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-bin/tensorflow/libtensorflow_framework.so.1.14.0 ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_ROCm.so &&
++ # chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
++ # chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_ROCm.so &&
++ # patchelf --set-soname libtensorflow_cc_ROCm.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
++ # patchelf --set-soname libtensorflow_framework_ROCm.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_ROCm.so &&
++ # patchelf --replace-needed libtensorflow_framework.so.1 libtensorflow_framework_ROCm.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_ROCm.so &&
++ # echo "Installing tensorflow headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing tensorflow generated headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-genfiles/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing tensorflow third_party headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/third_party/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing protobuf headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-out/)/../../../external/protobuf_archive/src/google/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
++ # echo "Installing nsync headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-out/)/../../../external/nsync/public/*.h ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
++ # echo "Installing absl headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow_rocm/src/tensorflow_download_rocm/bazel-out/)/../../../external/com_google_absl/absl/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf"
++ #)
++ #endif()
++ #if(FAST_BUILD_TensorFlow_CUDA)
++ #ExternalProject_Add(tensorflow_CUDA
++ # DEPENDS tensorflow_download
++ # PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # DOWNLOAD_COMMAND ""
++ # UPDATE_COMMAND ""
++ # # Run TF configure in the form of a shell script. CUDA should be installed in /usr/local/cuda
++ # CONFIGURE_COMMAND
++ # cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && sh ${PROJECT_SOURCE_DIR}/cmake/TensorflowConfigureCUDA.sh
++ # # Build using bazel
++ # BUILD_COMMAND
++ # echo "Building tensorflow with bazel and CUDA GPU support" &&
++ # cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && bazel build -c opt --config=cuda --copt=-mfpmath=both --copt=-march=core-avx2 //tensorflow:libtensorflow_cc.so
++ # INSTALL_COMMAND
++ # echo "Installing tensorflow binary" &&
++ # cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_cc.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
++ # cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_framework.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CUDA.so &&
++ # chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
++ # chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CUDA.so &&
++ # patchelf --set-soname libtensorflow_cc_CUDA.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
++ # patchelf --set-soname libtensorflow_framework_CUDA.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CUDA.so &&
++ # patchelf --replace-needed libtensorflow_framework.so libtensorflow_framework_CUDA.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CUDA.so &&
++ # #echo "Installing mkl binaries" &&
++ # #bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/mkl/lib/libmklml_intel.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/ -Rf" &&
++ # #bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/mkl/lib/libiomp5.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/ -Rf" &&
++ # echo "Installing tensorflow headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing tensorflow generated headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-genfiles/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing tensorflow third_party headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/third_party/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing protobuf headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/protobuf_archive/src/google/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
++ # echo "Installing nsync headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/nsync/public/*.h ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
++ # echo "Installing absl headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/com_google_absl/absl/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf"
++ #)
++ #endif()
++ #if(FAST_BUILD_TensorFlow_CPU)
++ #ExternalProject_Add(tensorflow_CPU
++ # DEPENDS tensorflow_download
++ # PREFIX ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/tensorflow
++ # DOWNLOAD_COMMAND ""
++ # UPDATE_COMMAND ""
++ # # Run TF configure in the form of a shell script.
++ # CONFIGURE_COMMAND
++ # cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && sh ${PROJECT_SOURCE_DIR}/cmake/TensorflowConfigureCPU.sh
++ # # Build using bazel
++ # BUILD_COMMAND
++ # echo "Building tensorflow with bazel for CPU" &&
++ # cd ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/ && bazel build --config=opt --copt=-mfpmath=both --copt=-march=core-avx2 //tensorflow:libtensorflow_cc.so
++ # INSTALL_COMMAND
++ # echo "Installing tensorflow binary" &&
++ # cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_cc.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
++ # cp -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-bin/tensorflow/libtensorflow_framework.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CPU.so &&
++ # chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
++ # chmod a+w ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CPU.so &&
++ # patchelf --set-soname libtensorflow_cc_CPU.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
++ # patchelf --set-soname libtensorflow_framework_CPU.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_framework_CPU.so &&
++ # patchelf --replace-needed libtensorflow_framework.so libtensorflow_framework_CPU.so ${FAST_EXTERNAL_INSTALL_DIR}/lib/libtensorflow_cc_CPU.so &&
++ # echo "Installing tensorflow headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing tensorflow generated headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-genfiles/tensorflow/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing tensorflow third_party headers" &&
++ # cp -rf ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/third_party/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ &&
++ # echo "Installing protobuf headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/protobuf_archive/src/google/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
++ # echo "Installing nsync headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/nsync/public/*.h ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf" &&
++ # echo "Installing absl headers" &&
++ # bash -c "cp $(readlink -f ${FAST_EXTERNAL_BUILD_DIR}/tensorflow/src/tensorflow_download/bazel-out/)/../../../external/com_google_absl/absl/ ${FAST_EXTERNAL_INSTALL_DIR}/include/ -Rf"
++ #)
++ #endif()
++ #endif(WIN32)
+
+Index: fast/cmake/ExternalDCMTK.cmake
+===================================================================
+--- fast.orig/cmake/ExternalDCMTK.cmake 2019-08-09 02:35:51.324008777 +0100
++++ fast/cmake/ExternalDCMTK.cmake 2019-08-09 02:47:25.669716111 +0100
+@@ -1,36 +1,36 @@
+ # Download and set up DCMTK
+
+-include(cmake/Externals.cmake)
++#include(cmake/Externals.cmake)
+
+-set(MODULES ofstd oflog dcmdata dcmimgle)
++#set(MODULES ofstd oflog dcmdata dcmimgle)
+
+-ExternalProject_Add(dcmtk
+- PREFIX ${FAST_EXTERNAL_BUILD_DIR}/dcmtk
+- BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/dcmtk
+- GIT_REPOSITORY "https://github.com/DCMTK/dcmtk.git"
+- GIT_TAG "DCMTK-3.6.3"
+- CMAKE_ARGS
+- -DCMAKE_MACOSX_RPATH=ON
+- -DBUILD_SHARED_LIBS=ON
+- -DBUILD_APPS=OFF
+- -DDCMTK_WITH_DOXYGEN=OFF
+- -DCMAKE_INSTALL_RPATH:STRING=$ORIGIN/../lib
+- CMAKE_CACHE_ARGS
+- -DDCMTK_MODULES:STRING=${MODULES}
+- -DCMAKE_BUILD_TYPE:STRING=Release
+- -DCMAKE_VERBOSE_MAKEFILE:BOOL=OFF
+- -DCMAKE_INSTALL_MESSAGE:BOOL=LAZY
+- -DCMAKE_INSTALL_PREFIX:STRING=${FAST_EXTERNAL_INSTALL_DIR}
+-)
+-if(WIN32)
+- set(DCMTK_LIBRARIES ofstd.lib oflog.lib dcmdata.lib dcmimgle.lib)
+-else(WIN32)
+- set(DCMTK_LIBRARIES
+- ${CMAKE_SHARED_LIBRARY_PREFIX}ofstd${CMAKE_SHARED_LIBRARY_SUFFIX}
+- ${CMAKE_SHARED_LIBRARY_PREFIX}oflog${CMAKE_SHARED_LIBRARY_SUFFIX}
+- ${CMAKE_SHARED_LIBRARY_PREFIX}dcmdata${CMAKE_SHARED_LIBRARY_SUFFIX}
+- ${CMAKE_SHARED_LIBRARY_PREFIX}dcmimgle${CMAKE_SHARED_LIBRARY_SUFFIX}
+- )
+-endif(WIN32)
+-list(APPEND LIBRARIES ${DCMTK_LIBRARIES})
+-list(APPEND FAST_EXTERNAL_DEPENDENCIES dcmtk)
++#ExternalProject_Add(dcmtk
++# PREFIX ${FAST_EXTERNAL_BUILD_DIR}/dcmtk
++# BINARY_DIR ${FAST_EXTERNAL_BUILD_DIR}/dcmtk
++# GIT_REPOSITORY "https://github.com/DCMTK/dcmtk.git"
++# GIT_TAG "DCMTK-3.6.3"
++# CMAKE_ARGS
++# -DCMAKE_MACOSX_RPATH=ON
++# -DBUILD_SHARED_LIBS=ON
++# -DBUILD_APPS=OFF
++# -DDCMTK_WITH_DOXYGEN=OFF
++# -DCMAKE_INSTALL_RPATH:STRING=$ORIGIN/../lib
++# CMAKE_CACHE_ARGS
++# -DDCMTK_MODULES:STRING=${MODULES}
++# -DCMAKE_BUILD_TYPE:STRING=Release
++# -DCMAKE_VERBOSE_MAKEFILE:BOOL=OFF
++# -DCMAKE_INSTALL_MESSAGE:BOOL=LAZY
++# -DCMAKE_INSTALL_PREFIX:STRING=${FAST_EXTERNAL_INSTALL_DIR}
++#)
++#if(WIN32)
++# set(DCMTK_LIBRARIES ofstd.lib oflog.lib dcmdata.lib dcmimgle.lib)
++#else(WIN32)
++# set(DCMTK_LIBRARIES
++# ${CMAKE_SHARED_LIBRARY_PREFIX}ofstd${CMAKE_SHARED_LIBRARY_SUFFIX}
++# ${CMAKE_SHARED_LIBRARY_PREFIX}oflog${CMAKE_SHARED_LIBRARY_SUFFIX}
++# ${CMAKE_SHARED_LIBRARY_PREFIX}dcmdata${CMAKE_SHARED_LIBRARY_SUFFIX}
++# ${CMAKE_SHARED_LIBRARY_PREFIX}dcmimgle${CMAKE_SHARED_LIBRARY_SUFFIX}
++# )
++#endif(WIN32)
++#list(APPEND LIBRARIES ${DCMTK_LIBRARIES})
++#list(APPEND FAST_EXTERNAL_DEPENDENCIES dcmtk)
=====================================
debian/patches/use_system_libs.patch
=====================================
@@ -5,9 +5,9 @@ Author: Shayan Doust <hello at shayandoust.me>
Index: fast/CMakeLists.txt
===================================================================
---- fast.orig/CMakeLists.txt 2019-08-08 19:28:18.008989077 +0100
-+++ fast/CMakeLists.txt 2019-08-08 19:28:40.589176448 +0100
-@@ -170,6 +170,13 @@
+--- fast.orig/CMakeLists.txt 2019-08-09 04:17:42.918244664 +0100
++++ fast/CMakeLists.txt 2019-08-09 04:17:57.242362402 +0100
+@@ -170,6 +170,17 @@
qt5_use_modules(FAST Widgets OpenGL) # Add Qt 5 modules
endif()
@@ -17,6 +17,10 @@ Index: fast/CMakeLists.txt
+target_link_libraries(FAST PUBLIC openslide)
+target_link_libraries(FAST PUBLIC z)
+target_link_libraries(FAST PUBLIC OpenIGTLink)
++target_link_libraries(FAST PUBLIC ofstd)
++target_link_libraries(FAST PUBLIC oflog)
++target_link_libraries(FAST PUBLIC dcmdata)
++target_link_libraries(FAST PUBLIC dcmimgle)
+
## Build test executable
if(FAST_BUILD_TESTS)
View it on GitLab: https://salsa.debian.org/med-team/fast/compare/8cc83f9935d1c947a292bb10c4a55d631cdc0237...61aac01069637c02b10a550339d39199b5fb9404
--
View it on GitLab: https://salsa.debian.org/med-team/fast/compare/8cc83f9935d1c947a292bb10c4a55d631cdc0237...61aac01069637c02b10a550339d39199b5fb9404
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/debian-med-commit/attachments/20190809/8cc20269/attachment-0001.html>
More information about the debian-med-commit
mailing list