Skip to content

Commit

Permalink
fix #2720
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@13488 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed May 15, 2010
1 parent 612b76e commit dfe8119
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
12 changes: 3 additions & 9 deletions cmake/FindPyQt4.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
#
# PYQT4_SIP_FLAGS - The SIP flags used to build PyQt.

IF(EXISTS PYQT4_VERSION_STR)
IF(EXISTS PYQT4_VERSION)
# Already in cache, be silent
SET(PYQT4_FOUND TRUE)
ELSE(EXISTS PYQT4_VERSION_STR)
ELSE(EXISTS PYQT4_VERSION)

FIND_FILE(_find_pyqt_py FindPyQt.py PATHS ${CMAKE_MODULE_PATH})

Expand All @@ -50,10 +50,4 @@ ELSE(EXISTS PYQT4_VERSION_STR)
ENDIF(PYQT4_FIND_REQUIRED)
ENDIF(PYQT4_FOUND)

ENDIF(EXISTS PYQT4_VERSION_STR)

STRING(REGEX REPLACE "^([0-9]*)\\.[0-9]*\\.[0-9]*$" "\\1" PYQT4_MAJOR_VERSION ${PYQT4_VERSION_STR})
STRING(REGEX REPLACE "^[0-9]*\\.([0-9]*)\\.[0-9]*$" "\\1" PYQT4_MINOR_VERSION ${PYQT4_VERSION_STR})
STRING(REGEX REPLACE "^[0-9]*\\.[0-9]*\\.([0-9]*)$" "\\1" PYQT4_PATCH_VERSION ${PYQT4_VERSION_STR})
MATH( EXPR PYQT4_NUM_VERSION "${PYQT4_MAJOR_VERSION}*10000 + ${PYQT4_MINOR_VERSION}*100 + ${PYQT4_PATCH_VERSION}")

ENDIF(EXISTS PYQT4_VERSION)
4 changes: 2 additions & 2 deletions python/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,9 @@ IF(MSVC)
ADD_DEFINITIONS(-DNOMINMAX)
ENDIF(MSVC)

IF(${PYQT4_NUM_VERSION} LESS 40600)
IF(PYQT4_VERSION_TAG LESS 263680) # 0x040600
SET(SIP_DISABLE_FEATURES ${SIP_DISABLE_FEATURES} PROXY_FACTORY)
ENDIF(${PYQT4_NUM_VERSION} LESS 40600)
ENDIF(PYQT4_VERSION_TAG LESS 263680)

# core module
FILE(GLOB sip_files_core core/*.sip)
Expand Down

0 comments on commit dfe8119

Please sign in to comment.