qt5: avoid LDFLAGS leaking into mkspecs
Instead of patching mkspecs files set the desired CFLAGS, CXXFLAGS and LDFLAGS through QMAKE_... variables when configuring. See #3112
This commit is contained in:
parent
e00c13e448
commit
0240d3ccd9
@ -1,7 +1,7 @@
|
|||||||
# Template file for 'qt5'
|
# Template file for 'qt5'
|
||||||
pkgname=qt5
|
pkgname=qt5
|
||||||
version=5.5.1
|
version=5.5.1
|
||||||
revision=2
|
revision=3
|
||||||
wrksrc="qt-everywhere-opensource-src-${version}"
|
wrksrc="qt-everywhere-opensource-src-${version}"
|
||||||
homepage="http://qt.io/"
|
homepage="http://qt.io/"
|
||||||
short_desc="A cross-platform application and UI framework (QT5)"
|
short_desc="A cross-platform application and UI framework (QT5)"
|
||||||
@ -26,9 +26,6 @@ makedepends="
|
|||||||
depends="qtchooser"
|
depends="qtchooser"
|
||||||
|
|
||||||
pre_configure() {
|
pre_configure() {
|
||||||
sed -i "s|-O2|${CXXFLAGS}|" qtbase/mkspecs/common/{g++,gcc}-base.conf
|
|
||||||
sed -i "/^QMAKE_LFLAGS\s/s|+=|+= ${LDFLAGS}|g" qtbase/mkspecs/common/gcc-base.conf
|
|
||||||
|
|
||||||
# Compatibility functions res_ninit() and res_nclose() for musl libc
|
# Compatibility functions res_ninit() and res_nclose() for musl libc
|
||||||
cp ${FILESDIR}/resolv_compat.h ${wrksrc}/qtwebengine/src/3rdparty/chromium/net/dns
|
cp ${FILESDIR}/resolv_compat.h ${wrksrc}/qtwebengine/src/3rdparty/chromium/net/dns
|
||||||
case "$XBPS_TARGET_MACHINE" in
|
case "$XBPS_TARGET_MACHINE" in
|
||||||
@ -71,6 +68,9 @@ do_configure() {
|
|||||||
*) opts+=" -reduce-relocations"
|
*) opts+=" -reduce-relocations"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
QMAKE_CFLAGS="${CFLAGS}" \
|
||||||
|
QMAKE_CXXFLAGS="${CXXFLAGS}" \
|
||||||
|
QMAKE_LFLAGS="${LDFLAGS}" \
|
||||||
./configure ${opts}
|
./configure ${opts}
|
||||||
}
|
}
|
||||||
do_build() {
|
do_build() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user