cmake: further cleanup
parent
52d61551a9
commit
294d35c0c4
|
@ -3,14 +3,9 @@ project(eco2d)
|
||||||
include(cmake/utils.cmake)
|
include(cmake/utils.cmake)
|
||||||
|
|
||||||
set(CMAKE_C_STANDARD 11)
|
set(CMAKE_C_STANDARD 11)
|
||||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/)
|
setup_build_dirs()
|
||||||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/)
|
|
||||||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY_DEBUG ${CMAKE_BINARY_DIR})
|
|
||||||
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE ${CMAKE_BINARY_DIR})
|
|
||||||
|
|
||||||
include_directories(eco2d-cli code/vendors code/common)
|
include_directories(code/common code/vendors code/vendors/flecs)
|
||||||
include_directories(eco2d-client code/vendors code/common)
|
|
||||||
include_directories(eco2d-server code/vendors code/vendors/flecs code/common)
|
|
||||||
|
|
||||||
add_subdirectory(code/common)
|
add_subdirectory(code/common)
|
||||||
add_subdirectory(code/vendors)
|
add_subdirectory(code/vendors)
|
||||||
|
|
|
@ -7,3 +7,10 @@ function(link_system_libs target_name)
|
||||||
target_link_libraries(${target_name} pthread m dl atomic)
|
target_link_libraries(${target_name} pthread m dl atomic)
|
||||||
endif()
|
endif()
|
||||||
endfunction()
|
endfunction()
|
||||||
|
|
||||||
|
function(setup_build_dirs)
|
||||||
|
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/)
|
||||||
|
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/)
|
||||||
|
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY_DEBUG ${CMAKE_BINARY_DIR})
|
||||||
|
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY_RELEASE ${CMAKE_BINARY_DIR})
|
||||||
|
endfunction()
|
||||||
|
|
|
@ -1,2 +1,3 @@
|
||||||
file(GLOB SRCS *.c *.h)
|
file(GLOB SRCS *.c *.h)
|
||||||
add_library(flecs-bundle STATIC ${SRCS})
|
add_library(flecs-bundle STATIC ${SRCS})
|
||||||
|
include_directories(flecs-bundle .)
|
||||||
|
|
Loading…
Reference in New Issue