[Cmake-commits] [cmake-commits] hoffman committed FindKDE3.cmake 1.12 1.13 FindQt3.cmake 1.17 1.18

cmake-commits at cmake.org cmake-commits at cmake.org
Wed Jun 18 08:37:35 EDT 2008


Update of /cvsroot/CMake/CMake/Modules
In directory public:/mounts/ram/cvs-serv28151

Modified Files:
	FindKDE3.cmake FindQt3.cmake 
Log Message:
ENH: try to module run test


Index: FindQt3.cmake
===================================================================
RCS file: /cvsroot/CMake/CMake/Modules/FindQt3.cmake,v
retrieving revision 1.17
retrieving revision 1.18
diff -C 2 -d -r1.17 -r1.18
*** FindQt3.cmake	9 Jun 2008 20:04:06 -0000	1.17
--- FindQt3.cmake	18 Jun 2008 12:37:32 -0000	1.18
***************
*** 187,191 ****
    STRING(REGEX MATCH "^[0-9]+\\.[0-9]+\\.[0-9]+$" req_qt_major_vers "${QT_MIN_VERSION}")
    IF (NOT req_qt_major_vers)
!     MESSAGE( FATAL_ERROR "Invalid Qt version string given: \"${QT_MIN_VERSION}\", expected e.g. \"3.1.5\"")
    ENDIF (NOT req_qt_major_vers)
  
--- 187,191 ----
    STRING(REGEX MATCH "^[0-9]+\\.[0-9]+\\.[0-9]+$" req_qt_major_vers "${QT_MIN_VERSION}")
    IF (NOT req_qt_major_vers)
!     error_message(  "Invalid Qt version string given: \"${QT_MIN_VERSION}\", expected e.g. \"3.1.5\"")
    ENDIF (NOT req_qt_major_vers)
  
***************
*** 195,201 ****
  
    # req = "6.5.4", qt = "3.2.1"
  
    IF (req_qt_major_vers GREATER qt_major_vers)                  # (6 > 3) ?
!     MESSAGE(  FATAL_ERROR "Qt major version not matched (required: ${QT_MIN_VERSION}, found: ${qt_version_str})")            # yes
    ELSE  (req_qt_major_vers GREATER qt_major_vers)               # no
      IF (req_qt_major_vers LESS qt_major_vers)                  # (6 < 3) ?
--- 195,208 ----
  
    # req = "6.5.4", qt = "3.2.1"
+   macro(error_message msg)
+     IF(QT3_REQUIRED)
+       MESSAGE( FATAL_ERROR ${msg})
+     ELSE(QT3_REQUIRED)
+       MESSAGE( STATUS ${msg})
+     ENDIF(QT3_REQUIRED)
+   endmacro(error_message)
  
    IF (req_qt_major_vers GREATER qt_major_vers)                  # (6 > 3) ?
!     error_message(  "Qt major version not matched (required: ${QT_MIN_VERSION}, found: ${qt_version_str})")            # yes
    ELSE  (req_qt_major_vers GREATER qt_major_vers)               # no
      IF (req_qt_major_vers LESS qt_major_vers)                  # (6 < 3) ?
***************
*** 203,207 ****
      ELSE (req_qt_major_vers LESS qt_major_vers)                # ( 6==3) ?
        IF (req_qt_minor_vers GREATER qt_minor_vers)            # (5>2) ?
!         MESSAGE(  FATAL_ERROR "Qt minor version not matched (required: ${QT_MIN_VERSION}, found: ${qt_version_str})")      # yes
        ELSE (req_qt_minor_vers GREATER qt_minor_vers)          # no
          IF (req_qt_minor_vers LESS qt_minor_vers)            # (5<2) ?
--- 210,214 ----
      ELSE (req_qt_major_vers LESS qt_major_vers)                # ( 6==3) ?
        IF (req_qt_minor_vers GREATER qt_minor_vers)            # (5>2) ?
!         error_message(  "Qt minor version not matched (required: ${QT_MIN_VERSION}, found: ${qt_version_str})")      # yes
        ELSE (req_qt_minor_vers GREATER qt_minor_vers)          # no
          IF (req_qt_minor_vers LESS qt_minor_vers)            # (5<2) ?
***************
*** 209,213 ****
          ELSE (req_qt_minor_vers LESS qt_minor_vers)          # (5==2)
            IF (req_qt_patch_vers GREATER qt_patch_vers)      # (4>1) ?
!             MESSAGE( FATAL_ERROR "Qt patch level not matched (required: ${QT_MIN_VERSION}, found: ${qt_version_str})")  # yes
            ELSE (req_qt_patch_vers GREATER qt_patch_vers)    # (4>1) ?
              SET( QT_VERSION_BIG_ENOUGH "YES" )             # yes
--- 216,220 ----
          ELSE (req_qt_minor_vers LESS qt_minor_vers)          # (5==2)
            IF (req_qt_patch_vers GREATER qt_patch_vers)      # (4>1) ?
!             error_message(  "Qt patch level not matched (required: ${QT_MIN_VERSION}, found: ${qt_version_str})")  # yes
            ELSE (req_qt_patch_vers GREATER qt_patch_vers)    # (4>1) ?
              SET( QT_VERSION_BIG_ENOUGH "YES" )             # yes

Index: FindKDE3.cmake
===================================================================
RCS file: /cvsroot/CMake/CMake/Modules/FindKDE3.cmake,v
retrieving revision 1.12
retrieving revision 1.13
diff -C 2 -d -r1.12 -r1.13
*** FindKDE3.cmake	16 Jun 2008 19:19:43 -0000	1.12
--- FindKDE3.cmake	18 Jun 2008 12:37:32 -0000	1.13
***************
*** 85,99 ****
  
  #only on linux, but NOT e.g. on FreeBSD:
! IF(CMAKE_SYSTEM_NAME MATCHES "Linux")
     SET (KDE3_DEFINITIONS ${KDE3_DEFINITIONS} -D_XOPEN_SOURCE=500 -D_BSD_SOURCE)
     SET ( CMAKE_C_FLAGS     "${CMAKE_C_FLAGS} -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-common")
     SET ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -fno-exceptions -fno-check-new -fno-common")
! ENDIF(CMAKE_SYSTEM_NAME MATCHES "Linux")
  
  # works on FreeBSD, NOT tested on NetBSD and OpenBSD
! IF (CMAKE_SYSTEM_NAME MATCHES BSD)
     SET ( CMAKE_C_FLAGS     "${CMAKE_C_FLAGS} -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-common")
     SET ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-exceptions -fno-check-new -fno-common")
! ENDIF (CMAKE_SYSTEM_NAME MATCHES BSD)
  
  # if no special buildtype is selected, add -O2 as default optimization
--- 85,99 ----
  
  #only on linux, but NOT e.g. on FreeBSD:
! IF(CMAKE_SYSTEM_NAME MATCHES "Linux" AND CMAKE_COMPILER_IS_GNUCXX)
     SET (KDE3_DEFINITIONS ${KDE3_DEFINITIONS} -D_XOPEN_SOURCE=500 -D_BSD_SOURCE)
     SET ( CMAKE_C_FLAGS     "${CMAKE_C_FLAGS} -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-common")
     SET ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -fno-exceptions -fno-check-new -fno-common")
! ENDIF(CMAKE_SYSTEM_NAME MATCHES "Linux" AND CMAKE_COMPILER_IS_GNUCXX)
  
  # works on FreeBSD, NOT tested on NetBSD and OpenBSD
! IF (CMAKE_SYSTEM_NAME MATCHES BSD AND CMAKE_COMPILER_IS_GNUCXX)
     SET ( CMAKE_C_FLAGS     "${CMAKE_C_FLAGS} -Wno-long-long -ansi -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-common")
     SET ( CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wnon-virtual-dtor -Wno-long-long -Wundef -Wcast-align -Wconversion -Wchar-subscripts -Wall -W -Wpointer-arith -Wwrite-strings -Wformat-security -Wmissing-format-attribute -fno-exceptions -fno-check-new -fno-common")
! ENDIF (CMAKE_SYSTEM_NAME MATCHES BSD AND CMAKE_COMPILER_IS_GNUCXX)
  
  # if no special buildtype is selected, add -O2 as default optimization



More information about the Cmake-commits mailing list