Move SDL/OpenGL dependencies into the SDL port

This commit is contained in:
Jeffrey Pfau 2014-01-30 23:58:48 -08:00
parent 8e3d104625
commit 4dae440670
1 changed files with 6 additions and 6 deletions

View File

@ -20,7 +20,7 @@ if(WIN32)
file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/windows/*.c) file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/windows/*.c)
else() else()
add_definitions(-DUSE_PTHREADS) add_definitions(-DUSE_PTHREADS)
set(PLATFORM_LIBRARY "${PLATFORM_LIBRARY};pthread") set(OS_LIBRARY "${OS_LIBRARY};pthread")
file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/posix/*.c) file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/posix/*.c)
endif() endif()
@ -58,15 +58,15 @@ endif()
if(BUILD_PERF) if(BUILD_PERF)
set(MAIN_SRC ${CMAKE_SOURCE_DIR}/src/platform/perf-main.c) set(MAIN_SRC ${CMAKE_SOURCE_DIR}/src/platform/perf-main.c)
if(UNIX AND NOT APPLE) if(UNIX AND NOT APPLE)
set(EXTRA_LIB ${EXTRA_LIB} rt) set(PLATFORM_LIB "${PLATFORM_LIB};rt")
endif() endif()
endif() endif()
add_library(${BINARY_NAME} SHARED ${ARM_SRC} ${GBA_SRC} ${DEBUGGER_SRC} ${RENDERER_SRC} ${UTIL_SRC} ${PLATFORM_SRC} ${OS_SRC}) add_library(${BINARY_NAME} SHARED ${ARM_SRC} ${GBA_SRC} ${DEBUGGER_SRC} ${RENDERER_SRC} ${UTIL_SRC} ${OS_SRC})
target_link_libraries(${BINARY_NAME} m ${DEBUGGER_LIB} ${PLATFORM_LIBRARY} ${OPENGL_LIBRARY} ${EXTRA_LIB}) target_link_libraries(${BINARY_NAME} m ${DEBUGGER_LIB} ${OS_LIB})
add_executable(${BINARY_NAME}-bin WIN32 ${MAIN_SRC}) add_executable(${BINARY_NAME}-bin WIN32 ${PLATFORM_SRC} ${MAIN_SRC})
target_link_libraries(${BINARY_NAME}-bin ${BINARY_NAME}) target_link_libraries(${BINARY_NAME}-bin ${BINARY_NAME} ${PLATFORM_LIBRARY} ${OPENGL_LIBRARY})
set_target_properties(${BINARY_NAME}-bin PROPERTIES OUTPUT_NAME ${BINARY_NAME}) set_target_properties(${BINARY_NAME}-bin PROPERTIES OUTPUT_NAME ${BINARY_NAME})
if(BUILD_QT) if(BUILD_QT)