blob: aed45979c06929cc5d25e1bcaad9416871e0a8d7 [file] [log] [blame]
Chandler Carruth94d02512012-06-21 09:51:26 +00001set(LLVM_LINK_COMPONENTS
2 asmparser
Chandler Carruth94d02512012-06-21 09:51:26 +00003 core
4 ipa
Chandler Carruth94d02512012-06-21 09:51:26 +00005 )
6
Chandler Carruth74b6a772013-01-07 15:35:46 +00007set(IRSources
Benjamin Kramer410780b2013-01-12 14:13:45 +00008 AttributesTest.cpp
Chandler Carruth94d02512012-06-21 09:51:26 +00009 ConstantsTest.cpp
10 DominatorTreeTest.cpp
Chandler Carruthebabadf2012-07-16 07:44:45 +000011 IRBuilderTest.cpp
Chandler Carruth94d02512012-06-21 09:51:26 +000012 InstructionsTest.cpp
Chandler Carruthec7ad652012-07-15 23:26:50 +000013 MDBuilderTest.cpp
Chandler Carruth94d02512012-06-21 09:51:26 +000014 MetadataTest.cpp
15 PassManagerTest.cpp
Chandler Carruth36e2ecf2012-07-15 23:45:24 +000016 TypeBuilderTest.cpp
Benjamin Kramer6d29c292012-08-04 09:52:39 +000017 TypesTest.cpp
Chandler Carruth94d02512012-06-21 09:51:26 +000018 ValueMapTest.cpp
19 VerifierTest.cpp
Gabor Greiffea6a552012-11-12 10:01:17 +000020 WaymarkTest.cpp
Chandler Carruth94d02512012-06-21 09:51:26 +000021 )
22
23# MSVC9 and 8 cannot compile ValueMapTest.cpp due to their bug.
24# See issue#331418 in Visual Studio.
25if(MSVC AND MSVC_VERSION LESS 1600)
Chandler Carruth74b6a772013-01-07 15:35:46 +000026 list(REMOVE_ITEM IRSources ValueMapTest.cpp)
Chandler Carruth94d02512012-06-21 09:51:26 +000027endif()
28
NAKAMURA Takumie14e13d2012-06-21 22:17:39 +000029# HACK: Declare a couple of source files as optionally compiled to satisfy the
30# missing-file-checker in LLVM's weird CMake build.
31set(LLVM_OPTIONAL_SOURCES
32 ValueMapTest.cpp
33 )
34
Chandler Carruth74b6a772013-01-07 15:35:46 +000035add_llvm_unittest(IRTests
36 ${IRSources}
Chandler Carruth94d02512012-06-21 09:51:26 +000037 )