Inspired by #1108 , fixes compilation error.

This commit is contained in:
Kitling 2015-09-04 20:02:01 -07:00
parent cc19a76656
commit b8e5f21910
2 changed files with 11 additions and 1 deletions

View file

@ -168,6 +168,13 @@ ENDIF (APPLE)
option(ENABLE_QT "Enable the Qt frontend" ON) option(ENABLE_QT "Enable the Qt frontend" ON)
option(CITRA_FORCE_QT4 "Use Qt4 even if Qt5 is available." OFF) option(CITRA_FORCE_QT4 "Use Qt4 even if Qt5 is available." OFF)
if (${CMAKE_SYSTEM_NAME} MATCHES "Linux")
option(LINUX "Private" ON)
else ()
option(LINUX "Private" OFF)
endif ()
if (ENABLE_QT) if (ENABLE_QT)
# Set CMAKE_PREFIX_PATH if QTDIR is defined in the environment This allows CMake to # Set CMAKE_PREFIX_PATH if QTDIR is defined in the environment This allows CMake to
# automatically find the Qt packages on Windows # automatically find the Qt packages on Windows
@ -232,7 +239,7 @@ add_subdirectory(src)
# http://standards.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html # http://standards.freedesktop.org/desktop-entry-spec/desktop-entry-spec-latest.html
# http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html # http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html
# http://standards.freedesktop.org/shared-mime-info-spec/shared-mime-info-spec-latest.html # http://standards.freedesktop.org/shared-mime-info-spec/shared-mime-info-spec-latest.html
if(${CMAKE_SYSTEM_NAME} MATCHES "Linux|FreeBSD|OpenBSD|NetBSD") if(LINUX OR ${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD|OpenBSD|NetBSD")
install(FILES "${CMAKE_SOURCE_DIR}/dist/citra.desktop" install(FILES "${CMAKE_SOURCE_DIR}/dist/citra.desktop"
DESTINATION "${CMAKE_INSTALL_PREFIX}/share/applications") DESTINATION "${CMAKE_INSTALL_PREFIX}/share/applications")
install(FILES "${CMAKE_SOURCE_DIR}/dist/citra.svg" install(FILES "${CMAKE_SOURCE_DIR}/dist/citra.svg"

View file

@ -9,3 +9,6 @@ set(HEADERS
create_directory_groups(${SRCS} ${HEADERS}) create_directory_groups(${SRCS} ${HEADERS})
add_library(glad STATIC ${SRCS} ${HEADERS}) add_library(glad STATIC ${SRCS} ${HEADERS})
target_include_directories(glad PUBLIC "include/") target_include_directories(glad PUBLIC "include/")
if (LINUX)
target_link_libraries(glad PUBLIC dl)
endif()