+# for CMake 2.6
+IF(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4)
+ # technically those packages are not required
+ # since one can still use the Motif/X11 version and not the gtk one:
+ FIND_PACKAGE(PkgConfig)
+ pkg_check_modules (GTK2 gtk+-2.0)
+ #MESSAGE("${GTK2_INCLUDE_DIRS}")
+
+# older CMake
+ELSE(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4)
+
IF (GTK2_LIBRARIES AND GTK2_INCLUDE_DIRS)
# in cache already
SET(GTK2_FOUND TRUE)
ENDIF(UNIX)
ENDIF (GTK2_LIBRARIES AND GTK2_INCLUDE_DIRS)
+ENDIF(${CMAKE_MAJOR_VERSION} EQUAL 2 AND ${CMAKE_MINOR_VERSION} GREATER 4)
# WX
# LG : Do not force but use what is installed !
# SET(wxWidgets_USE_LIBS base core gl)
+ # Can I require all my user to have the gl lib on linux, even if they do not really need it...
+ SET(WXGLCANVASLIBS "gl")
+
FIND_PACKAGE( wxWidgets REQUIRED)
#
IF(wxWidgets_FOUND)