r253099 - [CMake] Don't install c-index-test when LLVM_INSTALL_TOOLCHAIN_ONLY=ON.

Argyrios Kyrtzidis via cfe-commits cfe-commits at lists.llvm.org
Fri Nov 13 14:41:15 PST 2015


Author: akirtzidis
Date: Fri Nov 13 16:41:14 2015
New Revision: 253099

URL: http://llvm.org/viewvc/llvm-project?rev=253099&view=rev
Log:
[CMake] Don't install c-index-test when LLVM_INSTALL_TOOLCHAIN_ONLY=ON.

Modified:
    cfe/trunk/tools/c-index-test/CMakeLists.txt

Modified: cfe/trunk/tools/c-index-test/CMakeLists.txt
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/tools/c-index-test/CMakeLists.txt?rev=253099&r1=253098&r2=253099&view=diff
==============================================================================
--- cfe/trunk/tools/c-index-test/CMakeLists.txt (original)
+++ cfe/trunk/tools/c-index-test/CMakeLists.txt Fri Nov 13 16:41:14 2015
@@ -29,20 +29,22 @@ if (CLANG_HAVE_LIBXML)
   target_link_libraries(c-index-test ${LIBXML2_LIBRARIES})
 endif()
 
-if(INTERNAL_INSTALL_PREFIX)
-  set(INSTALL_DESTINATION "${INTERNAL_INSTALL_PREFIX}/bin")
-else()
-  set(INSTALL_DESTINATION bin)
-endif()
+if (NOT LLVM_INSTALL_TOOLCHAIN_ONLY)
+  if(INTERNAL_INSTALL_PREFIX)
+    set(INSTALL_DESTINATION "${INTERNAL_INSTALL_PREFIX}/bin")
+  else()
+    set(INSTALL_DESTINATION bin)
+  endif()
 
-install(TARGETS c-index-test
-  RUNTIME DESTINATION "${INSTALL_DESTINATION}"
-  COMPONENT c-index-test)
+  install(TARGETS c-index-test
+    RUNTIME DESTINATION "${INSTALL_DESTINATION}"
+    COMPONENT c-index-test)
 
-if (NOT CMAKE_CONFIGURATION_TYPES) # don't add this for IDE's.
-  add_custom_target(install-c-index-test
-    DEPENDS c-index-test
-    COMMAND "${CMAKE_COMMAND}"
-            -DCMAKE_INSTALL_COMPONENT=c-index-test
-            -P "${CMAKE_BINARY_DIR}/cmake_install.cmake")
+  if (NOT CMAKE_CONFIGURATION_TYPES) # don't add this for IDE's.
+    add_custom_target(install-c-index-test
+      DEPENDS c-index-test
+      COMMAND "${CMAKE_COMMAND}"
+              -DCMAKE_INSTALL_COMPONENT=c-index-test
+              -P "${CMAKE_BINARY_DIR}/cmake_install.cmake")
+  endif()
 endif()




More information about the cfe-commits mailing list