mirror of https://github.com/mgba-emu/mgba.git
Move SDL/OpenGL dependencies into the SDL port
This commit is contained in:
parent
8e3d104625
commit
4dae440670
|
@ -20,7 +20,7 @@ if(WIN32)
|
|||
file(GLOB OS_SRC ${CMAKE_SOURCE_DIR}/src/platform/windows/*.c)
|
||||
else()
|
||||
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)
|
||||
endif()
|
||||
|
||||
|
@ -58,15 +58,15 @@ endif()
|
|||
if(BUILD_PERF)
|
||||
set(MAIN_SRC ${CMAKE_SOURCE_DIR}/src/platform/perf-main.c)
|
||||
if(UNIX AND NOT APPLE)
|
||||
set(EXTRA_LIB ${EXTRA_LIB} rt)
|
||||
set(PLATFORM_LIB "${PLATFORM_LIB};rt")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
add_library(${BINARY_NAME} SHARED ${ARM_SRC} ${GBA_SRC} ${DEBUGGER_SRC} ${RENDERER_SRC} ${UTIL_SRC} ${PLATFORM_SRC} ${OS_SRC})
|
||||
target_link_libraries(${BINARY_NAME} m ${DEBUGGER_LIB} ${PLATFORM_LIBRARY} ${OPENGL_LIBRARY} ${EXTRA_LIB})
|
||||
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} ${OS_LIB})
|
||||
|
||||
add_executable(${BINARY_NAME}-bin WIN32 ${MAIN_SRC})
|
||||
target_link_libraries(${BINARY_NAME}-bin ${BINARY_NAME})
|
||||
add_executable(${BINARY_NAME}-bin WIN32 ${PLATFORM_SRC} ${MAIN_SRC})
|
||||
target_link_libraries(${BINARY_NAME}-bin ${BINARY_NAME} ${PLATFORM_LIBRARY} ${OPENGL_LIBRARY})
|
||||
set_target_properties(${BINARY_NAME}-bin PROPERTIES OUTPUT_NAME ${BINARY_NAME})
|
||||
|
||||
if(BUILD_QT)
|
||||
|
|
Loading…
Reference in New Issue