Remove deprecated llvm.experimental.gc.result.{int,float,ptr} intrinsics.
[oota-llvm.git] / utils / unittest / CMakeLists.txt
index b6d2d6d9e0e99df82067d6182f3b3c9c15027538..b34e22ae0cb42258f9096f675c49d8efc96134f7 100644 (file)
@@ -32,17 +32,20 @@ if (NOT LLVM_ENABLE_THREADS)
   add_definitions( -DGTEST_HAS_PTHREAD=0 )
 endif()
 
-# Visual Studio 2012 only supports up to 8 template parameters in
-# std::tr1::tuple by default, but gtest requires 10
-if(MSVC AND MSVC_VERSION EQUAL 1700)
-  add_definitions(-D_VARIADIC_MAX=10)
-endif ()
+set(LIBS
+  LLVMSupport # Depends on llvm::raw_ostream
+)
+
+find_library(PTHREAD_LIBRARY_PATH pthread)
+if (PTHREAD_LIBRARY_PATH)
+  list(APPEND LIBS pthread)
+endif()
 
 add_llvm_library(gtest
   googletest/src/gtest-all.cc
 
   LINK_LIBS
-  LLVMSupport # Depends on llvm::raw_ostream
-  )
+  ${LIBS}
+)
 
 add_subdirectory(UnitTestMain)