Skip to content

Commit

Permalink
cmake: fix finding 32 bit wxWidgets on gentoo
Browse files Browse the repository at this point in the history
Generalize regex and glob against `wx/config` scripts in
`Toolchain-cross-m32.cmake` to work on gentoo, which can append the
`-gtk3` suffix.

Signed-off-by: Rafael Kitover <rkitover@gmail.com>
  • Loading branch information
rkitover committed Feb 22, 2019
1 parent 0674b41 commit 6e76fce
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cmake/Toolchain-cross-m32.cmake
Expand Up @@ -21,14 +21,14 @@ IF(EXISTS ${LIB32}/wx/config)

SET(MAX_WX_VERSION 0.0)
FOREACH(WX_INSTALL ${WX_INSTALLS})
STRING(REGEX MATCH "[0-9]+(\\.[0-9]+)+\$" WX_VERSION ${WX_INSTALL})
STRING(REGEX MATCH "[0-9]+(\\.[0-9]+)+" WX_VERSION ${WX_INSTALL})

IF(WX_VERSION VERSION_GREATER MAX_WX_VERSION)
SET(MAX_WX_VERSION ${WX_VERSION})
ENDIF()
ENDFOREACH()

FILE(GLOB WX_INSTALL_CONFIGS "${LIB32}/wx/config/*${MAX_WX_VERSION}")
FILE(GLOB WX_INSTALL_CONFIGS "${LIB32}/wx/config/*${MAX_WX_VERSION}*")
LIST(GET WX_INSTALL_CONFIGS 0 WX_INSTALL_CONFIG)

SET(WX_CONFIG_TRANSFORM_SCRIPT_LINES
Expand Down

0 comments on commit 6e76fce

Please sign in to comment.