[polly] r279730 - Add LLVM libdir to library search path in out-of-tree builds.
Michael Kruse via llvm-commits
llvm-commits at lists.llvm.org
Thu Aug 25 04:28:53 PDT 2016
Author: meinersbur
Date: Thu Aug 25 06:28:52 2016
New Revision: 279730
URL: http://llvm.org/viewvc/llvm-project?rev=279730&view=rev
Log:
Add LLVM libdir to library search path in out-of-tree builds.
This previously was not required because in an out-of-tree build Polly would
only build libraries (LLVMPolly, libPolly, libPollyISL, libPollyPPCG), but no
executables where the libraries would be linked to. This will change when adding
unittests in a follow-up commit.
Modified:
polly/trunk/CMakeLists.txt
Modified: polly/trunk/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/CMakeLists.txt?rev=279730&r1=279729&r2=279730&view=diff
==============================================================================
--- polly/trunk/CMakeLists.txt (original)
+++ polly/trunk/CMakeLists.txt Thu Aug 25 06:28:52 2016
@@ -38,6 +38,11 @@ if (NOT DEFINED LLVM_MAIN_SRC_DIR)
set(${return_var} ${system_libs} PARENT_SCOPE)
endfunction(get_system_libs)
+ execute_process(COMMAND "${LLVM_INSTALL_ROOT}/bin/llvm-config" --libdir
+ OUTPUT_VARIABLE LLVM_LIBRARY_DIR
+ OUTPUT_STRIP_TRAILING_WHITESPACE)
+ link_directories("${LLVM_LIBRARY_DIR}")
+
# Now set the header paths.
execute_process(COMMAND "${LLVM_INSTALL_ROOT}/bin/llvm-config" --includedir
OUTPUT_VARIABLE LLVM_INCLUDE_DIR
More information about the llvm-commits
mailing list