diff options
author | rikky <rikky@ffa7fe5e-494d-0410-b361-a75ebd5db220> | 2011-01-02 22:59:46 +0000 |
---|---|---|
committer | rikky <rikky@ffa7fe5e-494d-0410-b361-a75ebd5db220> | 2011-01-02 22:59:46 +0000 |
commit | 9fdf5216a5b02cb543501814fa2158f1425b8bd0 (patch) | |
tree | 2d138f5c4130b2f852ca3c5565b2a94e511b8d17 /CMakeLists.txt | |
parent | 1778eb8f0bc75fb81030945a5b6ab4b3daeafa98 (diff) | |
download | navit-9fdf5216a5b02cb543501814fa2158f1425b8bd0.tar.gz |
Fix:Build:Fixed cmake summary. 1. First cmake run showed build reason "user defined" for every entry. 2. Show build reason for every module/plugin
git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit@3849 ffa7fe5e-494d-0410-b361-a75ebd5db220
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r-- | CMakeLists.txt | 64 |
1 files changed, 42 insertions, 22 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index b209b9f0f..1364e286b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,6 +16,26 @@ IF(NOT CMAKE_BUILD_TYPE) ENDIF(NOT CMAKE_BUILD_TYPE) ### Detect environment + +add_plugin(support/glib "native Glib found" FALSE) +add_plugin(support/zlib "native zlib found" FALSE) +add_plugin(support/libpng "native libpng found" FALSE) +add_plugin(support/wordexp "native wordexp found" FALSE) +add_module(graphics/android "FreeType library not found" FALSE) +add_module(graphics/gd "FreeType library not found" FALSE) +add_module(graphics/gtk_drawing_area "FreeType library not found" FALSE) +add_module(graphics/opengl "FreeType library not found" FALSE) +add_module(graphics/sdl "FreeType library not found" FALSE) +add_module(graphics/qt_qpainter "Qt libraries not found" FALSE) +add_module(gui/qml "Qt Declarative not found" FALSE) +add_module(gui/gtk "GTK libs not found" FALSE) +add_module(vehicle/gpsd "gpsd lib not found" FALSE) +add_module(vehicle/gypsy "gypsy lib not found" FALSE) +add_module(binding/dbus "dbus-glib-1 not found" FALSE) +add_module(speech/dbus "dbus-glib-1 not found" FALSE) +add_module(vehicle/gpsd_dbus "dbus-glib-1 not found" FALSE) +add_module(speech/speech_dispatcher "speech_dispatcher lib not found" FALSE) + INCLUDE (CPack) INCLUDE (CheckIncludeFiles) INCLUDE (CheckLibraryExists) @@ -55,7 +75,7 @@ if (Glib_FOUND) include_directories(${Glib_INCLUDE_DIRS}) list(APPEND NAVIT_LIBS ${Glib_LIBRARIES}) else(Glib_FOUND) - add_plugin(support/glib "Glib not found" TRUE) + set_with_reason(support/glib "Glib not found" TRUE) endif(Glib_FOUND) if(ZLIB_FOUND) set(HAVE_ZLIB 1) @@ -63,7 +83,7 @@ if(ZLIB_FOUND) list(APPEND NAVIT_LIBS ${ZLIB_LIBRARIES}) else(ZLIB_FOUND) message(STATUS "using internal zlib") - add_plugin(support/zlib "native zlib missing" TRUE) + set_with_reason(support/zlib "native zlib missing" TRUE) endif(ZLIB_FOUND) if(PNG_FOUND) set(HAVE_PNG 1) @@ -71,11 +91,11 @@ if(PNG_FOUND) list(APPEND NAVIT_LIBS ${PNG_LIBRARY}) else(PNG_FOUND) message(STATUS "using internal libpng") - add_plugin(support/libpng "native libpng missing" TRUE) + set_with_reason(support/libpng "native libpng missing" TRUE) endif(PNG_FOUND) if (NOT HAVE_WORDEXP) message(STATUS "wordexp.h not found. use internal wordexp") - add_plugin(support/wordexp "native wordexp missing" TRUE) + set_with_reason(support/wordexp "native wordexp missing" TRUE) endif() if(FREETYPE_FOUND) @@ -84,19 +104,19 @@ if(FREETYPE_FOUND) #add_module(font/freetype "freetype found" TRUE) else(FREETYPE_FOUND) MESSAGE("No freetype library found, graphics modules may not be available") - add_module(graphics/android "FreeType library not found" FALSE) - add_module(graphics/gd "FreeType library not found" FALSE) - add_module(graphics/gtk_drawing_area "FreeType library not found" FALSE) - add_module(graphics/opengl "FreeType library not found" FALSE) - add_module(graphics/sdl "FreeType library not found" FALSE) + set_with_reason(graphics/android "FreeType library not found" FALSE) + set_with_reason(graphics/gd "FreeType library not found" FALSE) + set_with_reason(graphics/gtk_drawing_area "FreeType library not found" FALSE) + set_with_reason(graphics/opengl "FreeType library not found" FALSE) + set_with_reason(graphics/sdl "FreeType library not found" FALSE) endif(FREETYPE_FOUND) if (QT_FOUND) if (QT_QTCORE_FOUND AND QT_QTGUI_FOUND AND FREETYPE_FOUND) - add_module(graphics/qt_qpainter "Qt libraries found" TRUE) + set_with_reason(graphics/qt_qpainter "Qt libraries found" TRUE) if (QT_QTDECLARATIVE_FOUND AND QT_QTXML_FOUND) - add_module(gui/qml "Qt Declarative found" TRUE) + set_with_reason(gui/qml "Qt Declarative found" TRUE) endif() if (QT_QTSVG_FOUND) @@ -114,9 +134,9 @@ if(GTK2_FOUND) include_directories(${GTK2_INCLUDE_DIRS}) list(APPEND NAVIT_LIBS ${GTK2_LIBRARIES}) set(HAVE_GTK2 1) - add_module(gui/gtk "GTK libs found" TRUE) + set_with_reason(gui/gtk "GTK libs found" TRUE) if(FREETYPE_FOUND) - add_module(graphics/gtk_drawing_area "GTK libs found" TRUE) + set_with_reason(graphics/gtk_drawing_area "GTK libs found" TRUE) endif(FREETYPE_FOUND) endif(GTK2_FOUND) @@ -124,7 +144,7 @@ if (QUESOGLC_FOUND AND FREETYPE_FOUND) if (OPENGL_FOUND AND OPENGL_GLU_FOUND AND OPENGL_INCLUDE_DIR) message (STATUS "opengl found: ${OPENGL_gl_LIBRARY}") include_directories(${OPENGL_INCLUDE_DIR}) - add_module(graphics/opengl "Found OpenGL and Quesoglc" TRUE) + set_with_reason(graphics/opengl "Found OpenGL and Quesoglc" TRUE) else() message (STATUS "opengl not found") endif() @@ -133,7 +153,7 @@ else() endif(QUESOGLC_FOUND AND FREETYPE_FOUND) if(SDL_FOUND AND SDLIMAGE_FOUND AND FREE_TYPE_FOUND) - add_module(graphics/sdl "SDL/SDL_image libs found" TRUE) + set_with_reason(graphics/sdl "SDL/SDL_image libs found" TRUE) list(APPEND NAVIT_LIBS ${SDL_LIBRARY} ${SDLIMAGE_LIBRARY}) set(SDL_IMAGE 1) if(SDLTTF_FOUND) @@ -143,23 +163,23 @@ if(SDL_FOUND AND SDLIMAGE_FOUND AND FREE_TYPE_FOUND) endif(SDL_FOUND AND SDLIMAGE_FOUND AND FREE_TYPE_FOUND) if (HAVE_LIBGPS) - add_module(vehicle/gpsd "gpsd lib found" TRUE) + set_with_reason(vehicle/gpsd "gpsd lib found" TRUE) endif(HAVE_LIBGPS) if (GYPSY_FOUND) - add_module(vehicle/gypsy "gypsy lib found" TRUE) + set_with_reason(vehicle/gypsy "gypsy lib found" TRUE) endif(GYPSY_FOUND) if(DBusGLib_FOUND) include_directories(${DBusGLib_INCLUDE_DIRS}) list(APPEND NAVIT_LIBS ${DBusGLib_LIBRARIES}) - add_module(binding/dbus "dbus-glib-1 found" TRUE) - add_module(speech/dbus "dbus-glib-1 found" TRUE) - add_module(vehicle/gpsd_dbus "dbus-glib-1 found" TRUE) + set_with_reason(binding/dbus "dbus-glib-1 found" TRUE) + set_with_reason(speech/dbus "dbus-glib-1 found" TRUE) + set_with_reason(vehicle/gpsd_dbus "dbus-glib-1 found" TRUE) endif() if (HAVE_LIBSPEECHD) - add_module(speech/speech_dispatcher "speech_dispatcher lib found" TRUE) + set_with_reason(speech/speech_dispatcher "speech_dispatcher lib found" TRUE) endif(HAVE_LIBSPEECHD) #Independent modules @@ -270,7 +290,7 @@ set(LOCALEDIR "${LOCALE_DIR}/locale") foreach(PLUMO ${ALL_PLUGINS} ${ALL_MODULES} USE_PLUGINS USE_ROUTING BUILD_MAPTOOL USE_SVG SVG2PNG DBUS_USE_SYSTEM_BUS) set(OLDVALUE ${${PLUMO}}) OPTION(${PLUMO} "Enable/Disable module/plugin/support" ${${PLUMO}}) - if ( NOT ${OLDVALUE} STREQUAL ${${PLUMO}} ) + if ( (OLDVALUE AND NOT ${PLUMO}) OR (${PLUMO} AND NOT OLDVALUE)) set(${PLUMO}_REASON "User defined") endif() endforeach() |