CMake cleanup
Several cleanups to the buildsystem: - Do better factoring of common libs between platforms. - Add support to building on Windows. - Remove Qt4 support. - Re-sort file lists and add missing headers.
This commit is contained in:
parent
523385955c
commit
45976da975
9 changed files with 271 additions and 156 deletions
|
@ -1,6 +1,13 @@
|
|||
set(SRCS citra.cpp
|
||||
emu_window/emu_window_glfw.cpp)
|
||||
set(HEADERS resource.h)
|
||||
set(SRCS
|
||||
emu_window/emu_window_glfw.cpp
|
||||
citra.cpp
|
||||
)
|
||||
set(HEADERS
|
||||
emu_window/emu_window_glfw.h
|
||||
resource.h
|
||||
)
|
||||
|
||||
create_directory_groups(${SRCS} ${HEADERS})
|
||||
|
||||
# NOTE: This is a workaround for CMake bug 0006976 (missing X11_xf86vmode_LIB variable)
|
||||
if (NOT X11_xf86vmode_LIB)
|
||||
|
@ -8,11 +15,16 @@ if (NOT X11_xf86vmode_LIB)
|
|||
endif()
|
||||
|
||||
add_executable(citra ${SRCS} ${HEADERS})
|
||||
target_link_libraries(citra core common video_core)
|
||||
target_link_libraries(citra ${OPENGL_gl_LIBRARY} ${GLFW_LIBRARIES})
|
||||
|
||||
if (APPLE)
|
||||
target_link_libraries(citra core common video_core iconv pthread ${COREFOUNDATION_LIBRARY} ${OPENGL_LIBRARIES} ${GLFW_LIBRARIES})
|
||||
else()
|
||||
target_link_libraries(citra core common video_core pthread X11 Xxf86vm Xi Xcursor ${OPENGL_LIBRARIES} ${GLFW_LIBRARIES} rt ${X11_Xrandr_LIB} ${X11_xv86vmode_LIB} ${PNG_LIBRARIES})
|
||||
target_link_libraries(citra iconv pthread ${COREFOUNDATION_LIBRARY})
|
||||
elseif (WIN32)
|
||||
target_link_libraries(citra winmm)
|
||||
else() # Unix
|
||||
target_link_libraries(citra pthread rt)
|
||||
target_link_libraries(citra ${X11_X11_LIB} ${X11_Xi_LIB} ${X11_Xcursor_LIB} ${X11_Xrandr_LIB} ${X11_xv86vmode_LIB})
|
||||
endif()
|
||||
|
||||
#install(TARGETS citra RUNTIME DESTINATION ${bindir})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue