build-style/cmake: dehardcode gtk2 wxWdigets when cross compiling
This commit is contained in:
parent
737fc18b99
commit
ee4ce35a68
|
@ -15,6 +15,9 @@ do_configure() {
|
|||
mips*) _CMAKE_SYSTEM_PROCESSOR=mips ;;
|
||||
*) _CMAKE_SYSTEM_PROCESSOR=generic ;;
|
||||
esac
|
||||
if [ -x "${XBPS_CROSS_BASE}/usr/bin/wx-config-gtk3" ]; then
|
||||
wx_config=wx-config-gtk3
|
||||
fi
|
||||
cat > cross_${XBPS_CROSS_TRIPLET}.cmake <<_EOF
|
||||
SET(CMAKE_SYSTEM_NAME Linux)
|
||||
SET(CMAKE_SYSTEM_VERSION 1)
|
||||
|
@ -31,7 +34,7 @@ SET(CMAKE_FIND_ROOT_PATH_MODE_PROGRAM NEVER)
|
|||
SET(CMAKE_FIND_ROOT_PATH_MODE_LIBRARY ONLY)
|
||||
SET(CMAKE_FIND_ROOT_PATH_MODE_INCLUDE ONLY)
|
||||
|
||||
SET(wxWidgets_CONFIG_EXECUTABLE ${XBPS_WRAPPERDIR}/wx-config)
|
||||
SET(wxWidgets_CONFIG_EXECUTABLE ${XBPS_WRAPPERDIR}/${wx_config:=wx-config})
|
||||
_EOF
|
||||
cmake_args+=" -DCMAKE_TOOLCHAIN_FILE=cross_${XBPS_CROSS_TRIPLET}.cmake"
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue