summaryrefslogtreecommitdiffstats
path: root/tools/c-index-test/CMakeLists.txt
diff options
context:
space:
mode:
authordim <dim@FreeBSD.org>2012-08-15 20:02:54 +0000
committerdim <dim@FreeBSD.org>2012-08-15 20:02:54 +0000
commit554bcb69c2d785a011a30e7db87a36a87fe7db10 (patch)
tree9abb1a658a297776086f4e0dfa6ca533de02104e /tools/c-index-test/CMakeLists.txt
parentbb67ca86b31f67faee50bd10c3b036d65751745a (diff)
downloadFreeBSD-src-554bcb69c2d785a011a30e7db87a36a87fe7db10.zip
FreeBSD-src-554bcb69c2d785a011a30e7db87a36a87fe7db10.tar.gz
Vendor import of clang trunk r161861:
http://llvm.org/svn/llvm-project/cfe/trunk@161861
Diffstat (limited to 'tools/c-index-test/CMakeLists.txt')
-rw-r--r--tools/c-index-test/CMakeLists.txt13
1 files changed, 10 insertions, 3 deletions
diff --git a/tools/c-index-test/CMakeLists.txt b/tools/c-index-test/CMakeLists.txt
index c44b34b..6379194 100644
--- a/tools/c-index-test/CMakeLists.txt
+++ b/tools/c-index-test/CMakeLists.txt
@@ -1,5 +1,3 @@
-set(LLVM_USED_LIBS libclang)
-
set( LLVM_LINK_COMPONENTS
support
mc
@@ -9,8 +7,17 @@ add_clang_executable(c-index-test
c-index-test.c
)
+target_link_libraries(c-index-test
+ libclang
+ )
+
set_target_properties(c-index-test
PROPERTIES
LINKER_LANGUAGE CXX)
-install(TARGETS c-index-test RUNTIME DESTINATION bin)
+# If libxml2 is available, make it available for c-index-test.
+if (LIBXML2_FOUND)
+ add_definitions(${LIBXML2_DEFINITIONS} "-DCLANG_HAVE_LIBXML")
+ include_directories(${LIBXML2_INCLUDE_DIR})
+ target_link_libraries(c-index-test ${LIBXML2_LIBRARIES})
+endif()
OpenPOWER on IntegriCloud