2024-11-12 19:56:02 +00:00
|
|
|
file(GLOB_RECURSE common_sources *.c *.h include/ivy/*.h)
|
|
|
|
|
|
2024-12-07 19:32:35 +00:00
|
|
|
if (WIN32)
|
2024-12-16 20:57:30 +00:00
|
|
|
set(rc_file ${CMAKE_CURRENT_SOURCE_DIR}/../res/win32/common.rc)
|
2024-12-07 19:32:35 +00:00
|
|
|
endif ()
|
|
|
|
|
|
2024-12-06 19:48:20 +00:00
|
|
|
if (IVY_STATIC)
|
2024-12-07 19:32:35 +00:00
|
|
|
add_library(ivy-common STATIC ${common_sources} ${rc_file})
|
2024-12-06 19:48:20 +00:00
|
|
|
else ()
|
2024-12-07 19:32:35 +00:00
|
|
|
add_library(ivy-common SHARED ${common_sources} ${rc_file})
|
2024-12-06 19:48:20 +00:00
|
|
|
endif ()
|
|
|
|
|
|
2024-11-12 19:56:02 +00:00
|
|
|
target_include_directories(ivy-common PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include/)
|
2024-12-13 12:25:40 +00:00
|
|
|
target_compile_definitions(ivy-common PRIVATE IVY_EXPORT=1 IVY_STATIC=${IVY_STATIC})
|
|
|
|
|
target_link_libraries(ivy-common Bluelib::Core Bluelib::Object)
|