Reduce deps on linux
This commit is contained in:
parent
db3096a9f5
commit
30fbd04678
1 changed files with 10 additions and 1 deletions
|
@ -18,7 +18,6 @@ find_package(glm REQUIRED)
|
||||||
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
|
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||||
add_definitions(-DDEBUG)
|
add_definitions(-DDEBUG)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(APPLE AND NOT TARGET SDL2::SDL2)
|
if(APPLE AND NOT TARGET SDL2::SDL2)
|
||||||
add_library(SDL2::SDL2 UNKNOWN IMPORTED)
|
add_library(SDL2::SDL2 UNKNOWN IMPORTED)
|
||||||
set_target_properties(SDL2::SDL2 PROPERTIES
|
set_target_properties(SDL2::SDL2 PROPERTIES
|
||||||
|
@ -26,6 +25,12 @@ if(APPLE AND NOT TARGET SDL2::SDL2)
|
||||||
INTERFACE_INCLUDE_DIRECTORIES ${SDL2_INCLUDE_DIRS})
|
INTERFACE_INCLUDE_DIRECTORIES ${SDL2_INCLUDE_DIRS})
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
# workaround for linking dbus/glib ourselves
|
||||||
|
if(UNIX AND NOT APPLE)
|
||||||
|
set_target_properties(SDL2::SDL2 PROPERTIES
|
||||||
|
IMPORTED_LINK_INTERFACE_LIBRARIES_NOCONFIG "")
|
||||||
|
endif()
|
||||||
|
|
||||||
if(NOT TARGET assimp::assimp)
|
if(NOT TARGET assimp::assimp)
|
||||||
add_library(assimp::assimp UNKNOWN IMPORTED)
|
add_library(assimp::assimp UNKNOWN IMPORTED)
|
||||||
|
|
||||||
|
@ -46,6 +51,10 @@ add_executable(Graph
|
||||||
src/postpass.cpp
|
src/postpass.cpp
|
||||||
src/dofpass.cpp
|
src/dofpass.cpp
|
||||||
src/imguipass.cpp)
|
src/imguipass.cpp)
|
||||||
|
target_compile_options(Graph
|
||||||
|
PUBLIC
|
||||||
|
-fno-exceptions
|
||||||
|
-fno-rtti)
|
||||||
target_link_libraries(Graph
|
target_link_libraries(Graph
|
||||||
PUBLIC
|
PUBLIC
|
||||||
SDL2::SDL2
|
SDL2::SDL2
|
||||||
|
|
Reference in a new issue