Michael J. Spencer | 560a921 | 2010-09-13 23:54:41 +0000 | [diff] [blame] | 1 | set( LLVM_LINK_COMPONENTS |
Peter Collingbourne | 4b93d66 | 2011-02-19 23:03:58 +0000 | [diff] [blame] | 2 | support |
Michael J. Spencer | 560a921 | 2010-09-13 23:54:41 +0000 | [diff] [blame] | 3 | mc |
Steve Naroff | 5039819 | 2009-08-28 15:28:48 +0000 | [diff] [blame] | 4 | ) |
Douglas Gregor | 9a3dcf2 | 2009-10-05 22:29:42 +0000 | [diff] [blame] | 5 | |
Michael J. Spencer | 560a921 | 2010-09-13 23:54:41 +0000 | [diff] [blame] | 6 | add_clang_executable(c-index-test |
| 7 | c-index-test.c |
Michael J. Spencer | 5a7f349 | 2010-09-10 21:13:16 +0000 | [diff] [blame] | 8 | ) |
| 9 | |
Chandler Carruth | b0d8671 | 2012-06-21 01:30:21 +0000 | [diff] [blame] | 10 | target_link_libraries(c-index-test |
| 11 | libclang |
| 12 | ) |
| 13 | |
Douglas Gregor | 9a3dcf2 | 2009-10-05 22:29:42 +0000 | [diff] [blame] | 14 | set_target_properties(c-index-test |
| 15 | PROPERTIES |
| 16 | LINKER_LANGUAGE CXX) |
Dmitri Gribenko | f303d4c | 2012-08-07 17:54:38 +0000 | [diff] [blame^] | 17 | |
| 18 | # If libxml2 is available, make it available for c-index-test. |
| 19 | if (LIBXML2_FOUND) |
| 20 | add_definitions(${LIBXML2_DEFINITIONS} "-DCLANG_HAVE_LIBXML") |
| 21 | include_directories(${LIBXML2_INCLUDE_DIR}) |
| 22 | target_link_libraries(c-index-test ${LIBXML2_LIBRARIES}) |
| 23 | endif() |