Skip to content

Commit

Permalink
I am applying Andrew Fasano's CMake update from omg.cpp to the other …
Browse files Browse the repository at this point in the history
…binaries, and got new LLVM issues. Progress!
  • Loading branch information
AndrewQuijano committed Jul 9, 2024
1 parent ab95b05 commit 308bc39
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions tools/lavaTool/src/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ include_directories(${CMAKE_SOURCE_DIR}/include)

message(STATUS "PROJECT_SOURCE_DIR: ${PROJECT_SOURCE_DIR}")
message(STATUS "CMAKE_SOURCE_DIR: ${CMAKE_SOURCE_DIR}")
message(STATUS "LLVM_CLANG_LINK_LIBRARIES: ${LLVM_CLANG_LINK_LIBRARIES}")

if(NOT EXISTS "${CMAKE_SOURCE_DIR}/include/lava_version.h")
message(FATAL_ERROR "Missing lava_version.h")
Expand All @@ -59,40 +60,43 @@ target_link_libraries(omg PRIVATE ${LLVM_CLANG_LINK_LIBRARIES})

# Create lavaTool executable
add_executable(lavaTool lavaTool.cpp)
target_compile_features(lavaTool PRIVATE cxx_std_14)
target_compile_options(lavaTool PRIVATE -D_GLIBCXX_USE_CXX11_ABI=0 -fno-omit-frame-pointer -O3 -fexceptions -frtti)
target_compile_features(lavaTool PRIVATE cxx_std_17)
target_include_directories(lavaTool PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/../../lavaDB/include
${CMAKE_CURRENT_SOURCE_DIR}/../../lavaODB/generated
${CMAKE_CURRENT_SOURCE_DIR}/../../lavaODB/include
${CMAKE_CURRENT_SOURCE_DIR}/../../include
${CMAKE_CURRENT_SOURCE_DIR}/../include
${LLVM_INCLUDE_DIRS}
${CLANG_INCLUDE_DIRS}
)
target_link_libraries(lavaTool PRIVATE lavaDB_x64 omg odb odb-pgsql lava-odb_x64 ${LLVM_CLANG_LINK_LIBRARIES})
set_target_properties(lavaTool PROPERTIES LINK_FLAGS "-flto -fuse-ld=gold")

# Create lavaFnTool executable
add_executable(lavaFnTool lavaFnTool.cpp)
target_compile_features(lavaFnTool PRIVATE cxx_std_14)
target_compile_options(lavaFnTool PRIVATE -D_GLIBCXX_USE_CXX11_ABI=0 -fno-omit-frame-pointer -O3 -fexceptions -frtti)
target_compile_features(lavaFnTool PRIVATE cxx_std_17)
target_include_directories(lavaFnTool PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/../../lavaDB/include
${CMAKE_CURRENT_SOURCE_DIR}/../../lavaODB/generated
${CMAKE_CURRENT_SOURCE_DIR}/../../lavaODB/include
${CMAKE_CURRENT_SOURCE_DIR}/../../include
${CMAKE_CURRENT_SOURCE_DIR}/../include
${LLVM_INCLUDE_DIRS}
${CLANG_INCLUDE_DIRS}
)
target_link_libraries(lavaFnTool PRIVATE lavaDB_x64 omg odb odb-pgsql lava-odb_x64 ${LLVM_CLANG_LINK_LIBRARIES})
set_target_properties(lavaFnTool PROPERTIES LINK_FLAGS "-flto -fuse-ld=gold")

# Create lavaInitTool executable
add_executable(lavaInitTool lavaInitTool.cpp)
target_compile_features(lavaInitTool PRIVATE cxx_std_14)
target_compile_options(lavaInitTool PRIVATE -D_GLIBCXX_USE_CXX11_ABI=0 -fno-omit-frame-pointer -O3 -fexceptions -frtti)
target_compile_features(lavaInitTool PRIVATE cxx_std_17)
target_include_directories(lavaInitTool PRIVATE
${CMAKE_CURRENT_SOURCE_DIR}/../../lavaODB/include
${CMAKE_CURRENT_SOURCE_DIR}/../../include
${CMAKE_CURRENT_SOURCE_DIR}/../include
${LLVM_INCLUDE_DIRS}
${CLANG_INCLUDE_DIRS}
)
target_link_libraries(lavaInitTool PRIVATE ${LLVM_CLANG_LINK_LIBRARIES})
set_target_properties(lavaInitTool PROPERTIES LINK_FLAGS "-flto -fuse-ld=gold")
Expand Down

0 comments on commit 308bc39

Please sign in to comment.