Merge branch 'cmake-fix' into 'master'

Cmake fix

This branch SHOULD fix issue #14, but I haven't been able to check for myself without any GME stuff to test in-game with.

See merge request !58
This commit is contained in:
Alam Ed Arias 2016-03-10 18:00:51 -05:00
commit ee5190480d
3 changed files with 8 additions and 4 deletions

View file

@ -6,16 +6,16 @@ find_path(GME_INCLUDE_DIR
NAMES gme.h
PATHS
${GME_PKGCONF_INCLUDE_DIRS}
/usr/include/gme
/usr/local/include/gme
"/usr/include/gme"
"/usr/local/include/gme"
)
find_library(GME_LIBRARY
NAMES gme
PATHS
${GME_PKGCONF_LIBRARY_DIRS}
/usr/lib
/usr/local/lib
"/usr/lib"
"/usr/local/lib"
)
set(GME_PROCESS_INCLUDES GME_INCLUDE_DIR)

View file

@ -314,6 +314,7 @@ if(${SRB2_CONFIG_HAVE_GME})
find_package(GME)
if(${GME_FOUND})
set(SRB2_HAVE_GME ON)
add_definitions(-DHAVE_LIBGME)
else()
message(WARNING "You have specified that GME is available but it was not found.")
endif()

View file

@ -122,6 +122,7 @@ if(${SDL2_FOUND})
add_framework(SDL2 SRB2SDL2)
add_framework(SDL2_mixer SRB2SDL2)
target_link_libraries(SRB2SDL2 PRIVATE
${GME_LIBRARIES}
${PNG_LIBRARIES}
${ZLIB_LIBRARIES}
${OPENGL_LIBRARIES}
@ -131,6 +132,7 @@ if(${SDL2_FOUND})
target_link_libraries(SRB2SDL2 PRIVATE
${SDL2_LIBRARIES}
${SDL2_MIXER_LIBRARIES}
${GME_LIBRARIES}
${PNG_LIBRARIES}
${ZLIB_LIBRARIES}
${OPENGL_LIBRARIES}
@ -198,6 +200,7 @@ if(${SDL2_FOUND})
target_include_directories(SRB2SDL2 PRIVATE
${SDL2_INCLUDE_DIRS}
${SDL2_MIXER_INCLUDE_DIRS}
${GME_INCLUDE_DIRS}
${PNG_INCLUDE_DIRS}
${ZLIB_INCLUDE_DIRS}
${OPENGL_INCLUDE_DIRS}