Skip to content

Instantly share code, notes, and snippets.

@jbd
Created March 16, 2017 16:18
Show Gist options
  • Select an option

  • Save jbd/dba2dc45d7e85921464c070669ec9b5b to your computer and use it in GitHub Desktop.

Select an option

Save jbd/dba2dc45d7e85921464c070669ec9b5b to your computer and use it in GitHub Desktop.
tensorflow crosstool patch
--- ./third_party/gpus/crosstool/CROSSTOOL.tpl.orig 2017-02-21 16:18:02.410601465 +0100
+++ ./third_party/gpus/crosstool/CROSSTOOL.tpl 2017-02-21 16:25:01.177124380 +0100
@@ -44,7 +44,7 @@
tool_path { name: "ar" path: "/usr/bin/ar" }
tool_path { name: "compat-ld" path: "/usr/bin/ld" }
- tool_path { name: "cpp" path: "/usr/bin/cpp" }
+ tool_path { name: "cpp" path: "/local/gensoft2/exe/gcc/4.9.0/scripts/cpp" }
tool_path { name: "dwp" path: "/usr/bin/dwp" }
# As part of the TensorFlow release, we place some cuda-related compilation
# files in @local_config_cuda//crosstool/clang/bin, and this relative
@@ -54,9 +54,15 @@
# Use "-std=c++11" for nvcc. For consistency, force both the host compiler
# and the device compiler to use "-std=c++11".
cxx_flag: "-std=c++11"
+ linker_flag: "-L/local/gensoft2/exe/gcc/4.9.0/lib64/"
linker_flag: "-Wl,-no-as-needed"
linker_flag: "-lstdc++"
linker_flag: "-B/usr/bin/"
+ linker_flag: "-Wl,-rpath, /local/gensoft2/exe/gcc/4.9.0/lib64/"
+
+ cxx_builtin_include_directory: "/local/gensoft2/exe/gcc/4.9.0/lib/gcc/x86_64-unknown-linux-gnu/4.9.0/include"
+ cxx_builtin_include_directory: "/local/gensoft2/exe/gcc/4.9.0/lib/gcc/x86_64-unknown-linux-gnu/4.9.0/include-fixed"
+ cxx_builtin_include_directory: "/local/gensoft2/exe/gcc/4.9.0/include/c++/4.9.0"
%{gcc_host_compiler_includes}
tool_path { name: "gcov" path: "/usr/bin/gcov" }
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment