diff options
Diffstat (limited to 'Modules/FindGTK2.cmake')
-rw-r--r-- | Modules/FindGTK2.cmake | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Modules/FindGTK2.cmake b/Modules/FindGTK2.cmake index 5fe5213..f734b3b 100644 --- a/Modules/FindGTK2.cmake +++ b/Modules/FindGTK2.cmake @@ -119,7 +119,7 @@ function(_GTK2_GET_VERSION _OUT_major _OUT_minor _OUT_micro _gtkversion_hdr) string(REGEX REPLACE ".*#define GTK_MAJOR_VERSION[ \t]+\\(([0-9]+)\\).*" "\\1" ${_OUT_major} "${_contents}") string(REGEX REPLACE ".*#define GTK_MINOR_VERSION[ \t]+\\(([0-9]+)\\).*" "\\1" ${_OUT_minor} "${_contents}") string(REGEX REPLACE ".*#define GTK_MICRO_VERSION[ \t]+\\(([0-9]+)\\).*" "\\1" ${_OUT_micro} "${_contents}") - + if(NOT ${_OUT_major} MATCHES "[0-9]+") message(FATAL_ERROR "Version parsing failed for GTK2_MAJOR_VERSION!") endif() @@ -269,7 +269,7 @@ function(_GTK2_FIND_LIBRARY _var _lib _expand_vc _append_version) set(_lib_list ${_library}) set(_libd_list ${_library_d}) endif() - + if(GTK2_DEBUG) message(STATUS "[FindGTK2.cmake:${CMAKE_CURRENT_LIST_LINE}] " "library list = ${_lib_list} and library debug list = ${_libd_list}") @@ -301,7 +301,7 @@ function(_GTK2_FIND_LIBRARY _var _lib _expand_vc _append_version) "While searching for ${_var}, our proposed library list is ${_lib_list}") endif() - find_library(${_var} + find_library(${_var} NAMES ${_lib_list} PATHS /opt/gnome/lib @@ -403,8 +403,8 @@ if(GTK2_FIND_VERSION) else() message(FATAL_ERROR "GTK2 version check failed. Version ${GTK2_VERSION} was found, at least version ${GTK2_FIND_VERSION} is required") endif() - endif() - + endif() + # If the version check fails, exit out of the module here return() endif() @@ -423,7 +423,7 @@ foreach(_GTK2_component ${GTK2_FIND_COMPONENTS}) _GTK2_FIND_INCLUDE_DIR(GTK2_GLIB_INCLUDE_DIR glib.h) _GTK2_FIND_INCLUDE_DIR(GTK2_GLIBCONFIG_INCLUDE_DIR glibconfig.h) _GTK2_FIND_LIBRARY (GTK2_GLIB_LIBRARY glib false true) - + _GTK2_FIND_INCLUDE_DIR(GTK2_GOBJECT_INCLUDE_DIR gobject/gobject.h) _GTK2_FIND_LIBRARY (GTK2_GOBJECT_LIBRARY gobject false true) @@ -490,7 +490,7 @@ foreach(_GTK2_component ${GTK2_FIND_COMPONENTS}) _GTK2_FIND_INCLUDE_DIR(GTK2_GLADE_INCLUDE_DIR glade/glade.h) _GTK2_FIND_LIBRARY (GTK2_GLADE_LIBRARY glade false true) - + elseif(_GTK2_component STREQUAL "glademm") _GTK2_FIND_INCLUDE_DIR(GTK2_GLADEMM_INCLUDE_DIR libglademm.h) |