add clang flags so that libcds will be compiled with llvm pass
authorweiyu <weiyuluo1232@gmail.com>
Fri, 21 Jun 2019 23:06:06 +0000 (16:06 -0700)
committerweiyu <weiyuluo1232@gmail.com>
Fri, 21 Jun 2019 23:06:06 +0000 (16:06 -0700)
gdax-orderbook-hpp/demo/dependencies/libcds-2.3.2/CMakeLists.txt

index a198e26..146ece8 100644 (file)
@@ -110,6 +110,10 @@ endif()
 
 if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID STREQUAL "Clang")
     string(REGEX MATCHALL "-std=[^ ]+" cxx_std_found ${CMAKE_CXX_FLAGS} " dummy@rg")
+
+    # compile with CDSPass
+    set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Xclang -load -Xclang /scratch/llvm/build/lib/libCDSPass.so -O1")
+
     if(cxx_std_found)
         message("C++ std: ${cxx_std_found}")
     else()