summaryrefslogtreecommitdiffstats
path: root/Modules/FindGTK2.cmake
diff options
context:
space:
mode:
authorRolf Eike Beer <eike@sf-mail.de>2012-03-28 22:51:06 (GMT)
committerRolf Eike Beer <eike@sf-mail.de>2012-08-14 19:03:23 (GMT)
commitcfe4ac4b417b80fb657c8de3b43a29e12a558d82 (patch)
tree6ca43a847abcf2e4687f5d00e10673b9e429d5e4 /Modules/FindGTK2.cmake
parentb04650e163320353762b6ec196afa9500345b5cd (diff)
downloadCMake-cfe4ac4b417b80fb657c8de3b43a29e12a558d82.zip
CMake-cfe4ac4b417b80fb657c8de3b43a29e12a558d82.tar.gz
CMake-cfe4ac4b417b80fb657c8de3b43a29e12a558d82.tar.bz2
use PATH_SUFFIXES to simplify find_* calls
Especially remove "lib64" when the given paths are all Unix ones and "lib" is also explicitely given. In that case CMake will search "lib64" anyway for platforms where it is known to make sense.
Diffstat (limited to 'Modules/FindGTK2.cmake')
-rw-r--r--Modules/FindGTK2.cmake26
1 files changed, 9 insertions, 17 deletions
diff --git a/Modules/FindGTK2.cmake b/Modules/FindGTK2.cmake
index d10b419..61fa1f9 100644
--- a/Modules/FindGTK2.cmake
+++ b/Modules/FindGTK2.cmake
@@ -172,7 +172,7 @@ function(_GTK2_FIND_INCLUDE_DIR _var _hdr)
sigc++-2.0
)
- set(_suffixes)
+ set(_suffixes include lib)
foreach(_d ${_relatives})
list(APPEND _suffixes ${_d})
list(APPEND _suffixes ${_d}/include) # for /usr/lib/gtk-2.0/include
@@ -186,23 +186,15 @@ function(_GTK2_FIND_INCLUDE_DIR _var _hdr)
find_path(${_var} ${_hdr}
PATHS
/usr/local/lib64
- /usr/local/lib
/usr/lib64
- /usr/lib
- /opt/gnome/include
- /opt/gnome/lib
- /opt/openwin/include
- /usr/openwin/lib
- /sw/include
- /sw/lib
- /opt/local/include
- /opt/local/lib
- $ENV{GTKMM_BASEPATH}/include
- $ENV{GTKMM_BASEPATH}/lib
- [HKEY_CURRENT_USER\\SOFTWARE\\gtkmm\\2.4;Path]/include
- [HKEY_CURRENT_USER\\SOFTWARE\\gtkmm\\2.4;Path]/lib
- [HKEY_LOCAL_MACHINE\\SOFTWARE\\gtkmm\\2.4;Path]/include
- [HKEY_LOCAL_MACHINE\\SOFTWARE\\gtkmm\\2.4;Path]/lib
+ /opt/gnome
+ /opt/openwin
+ /usr/openwin
+ /sw
+ /opt/local
+ ENV GTKMM_BASEPATH
+ [HKEY_CURRENT_USER\\SOFTWARE\\gtkmm\\2.4;Path]
+ [HKEY_LOCAL_MACHINE\\SOFTWARE\\gtkmm\\2.4;Path]
PATH_SUFFIXES
${_suffixes}
)