diff options
author | Jörg Mayer <jmayer@loplof.de> | 2010-09-28 19:23:15 +0000 |
---|---|---|
committer | Jörg Mayer <jmayer@loplof.de> | 2010-09-28 19:23:15 +0000 |
commit | eb1fdd0f27da1187c13182a7e2f2c40c970de523 (patch) | |
tree | 689ea3436cf43652107cc8368407fb93271db52e | |
parent | 6a13fff801fa357770a5b9f08c7a15da9fb316b3 (diff) | |
download | wireshark-eb1fdd0f27da1187c13182a7e2f2c40c970de523.tar.gz wireshark-eb1fdd0f27da1187c13182a7e2f2c40c970de523.tar.bz2 wireshark-eb1fdd0f27da1187c13182a7e2f2c40c970de523.zip |
- Reset a few more variables used in FindXYZ scripts.
- README.cmake: small update.
- Set a variable before using it for installation.
svn path=/trunk/; revision=34274
-rw-r--r-- | CMakeLists.txt | 11 | ||||
-rw-r--r-- | README.cmake | 2 | ||||
-rw-r--r-- | cmake/modules/CheckCLinkerFlag.cmake | 6 | ||||
-rw-r--r-- | cmake/modules/FindPCAP.cmake | 3 | ||||
-rw-r--r-- | cmake/modules/FindZLIB.cmake | 2 |
5 files changed, 15 insertions, 9 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index db8b5004e6..ace54185ff 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -223,6 +223,9 @@ endif() #The minimum package list set(PACKAGELIST GLIB2 GMODULE2 PCAP M LEX YACC Perl SH PythonInterp HtmlViewer ${PACKAGELIST}) +set(GLIB2_FIND_REQUIRED) +set(GLIB2_MIN_VERSION 2.4.0) + #Build the gui ? if(BUILD_wireshark) set(PACKAGELIST GTK2 ${PACKAGELIST}) @@ -397,6 +400,10 @@ add_subdirectory( tools/lemon ) add_subdirectory( wiretap ) add_subdirectory( wsutil ) +# Basedir where to install guides +set(DOC_DIR "$ENV{docdir}") +message(STATUS "docdir: ${DOC_DIR}") + if(ENABLE_GUIDES) add_subdirectory( docbook ) endif() @@ -427,10 +434,6 @@ endif() configure_file(${CMAKE_SOURCE_DIR}/cmakeconfig.h.in ${CMAKE_BINARY_DIR}/config.h) -# Basedir where to install guides -set(DOC_DIR "$ENV{docdir}") -message(STATUS "docdir: ${DOC_DIR}") - include(FeatureSummary) #SET_FEATURE_INFO(NAME DESCRIPTION [URL [COMMENT] ] PRINT_ENABLED_FEATURES() diff --git a/README.cmake b/README.cmake index 566d8bd311..86874b3ac9 100644 --- a/README.cmake +++ b/README.cmake @@ -82,8 +82,6 @@ What needs to be done? - Add asn1 autogen target (assigned: krj) - Redo glib2 find modules. Add version detection while at it. -- Change default for PCRE to off and use GLIB2 regexes by default. - This requires the redone glib2 detection module. - Add back platform specific objects. - Fix places in the cmake files marked as todo. - Add back (working) install target. diff --git a/cmake/modules/CheckCLinkerFlag.cmake b/cmake/modules/CheckCLinkerFlag.cmake index aa346684f7..abe4a3a283 100644 --- a/cmake/modules/CheckCLinkerFlag.cmake +++ b/cmake/modules/CheckCLinkerFlag.cmake @@ -12,12 +12,12 @@ # # Redistribution and use is allowed according to the terms of the BSD license. -INCLUDE(CheckCSourceCompiles) +INCLUDE(CheckCSourceRuns) MACRO (CHECK_C_LINKER_FLAG _FLAG _RESULT) SET(CMAKE_REQUIRED_FLAGS "${_FLAG}") message(status "check linker flag - test linker flags: ${CMAKE_REQUIRED_FLAGS}") - CHECK_C_SOURCE_COMPILES("int main() { return 0;}" ${_RESULT}) - SET(CMAKE_REQUIRED_FLAGS " ") + CHECK_C_SOURCE_RUNS("int main() { return 0;}" ${_RESULT}) + SET(CMAKE_REQUIRED_FLAGS "") ENDMACRO (CHECK_C_LINKER_FLAG) diff --git a/cmake/modules/FindPCAP.cmake b/cmake/modules/FindPCAP.cmake index 1ec01c95c6..d22f0ba951 100644 --- a/cmake/modules/FindPCAP.cmake +++ b/cmake/modules/FindPCAP.cmake @@ -120,6 +120,9 @@ CHECK_FUNCTION_EXISTS("pcap_set_datalink" HAVE_PCAP_SET_DATALINK) CHECK_FUNCTION_EXISTS("pcap_lib_version" HAVE_PCAP_LIB_VERSION) CHECK_FUNCTION_EXISTS("pcap_get_selectable_fd" HAVE_PCAP_GET_SELECTABLE_FD) CHECK_FUNCTION_EXISTS("pcap_free_datalinks" HAVE_PCAP_FREE_DATALINKS) +# reset vars +SET(CMAKE_REQUIRED_INCLUDES "") +SET(CMAKE_REQUIRED_LIBRARIES "") INCLUDE(FindPackageHandleStandardArgs) FIND_PACKAGE_HANDLE_STANDARD_ARGS(PCAP DEFAULT_MSG PCAP_INCLUDE_DIRS PCAP_LIBRARIES) diff --git a/cmake/modules/FindZLIB.cmake b/cmake/modules/FindZLIB.cmake index 5f8f24b587..316f9e5115 100644 --- a/cmake/modules/FindZLIB.cmake +++ b/cmake/modules/FindZLIB.cmake @@ -38,6 +38,8 @@ SET(ZLIB_LIBRARIES "${ZLIB_LIBRARY}") INCLUDE(CheckFunctionExists) SET(CMAKE_REQUIRED_LIBRARIES ${ZLIB_LIBRARIES}) CHECK_FUNCTION_EXISTS("gzclearerr" HAVE_GZCLEARERR) +# reset +SET(CMAKE_REQUIRED_LIBRARIES "") # handle the QUIETLY and REQUIRED arguments and set ZLIB_FOUND to TRUE if # all listed variables are TRUE |