Browse Source

Merge pull request #5026

dd367ff build: macdeploy: filter out irrelevant qt5 frameworks and dylibs (Cory Fields)
9fedafb build: Fix OSX build when using Homebrew and qt5 (Cory Fields)

Signed-off-by: Gavin Andresen <gavinandresen@gmail.com>
0.10
Gavin Andresen 10 years ago
parent
commit
4b73b758a3
No known key found for this signature in database
GPG Key ID: 7588242FBE38D3A8
  1. 7
      build-aux/m4/bitcoin_qt.m4
  2. 25
      configure.ac
  3. 26
      contrib/macdeploy/macdeployqtplus

7
build-aux/m4/bitcoin_qt.m4

@ -152,6 +152,13 @@ AC_DEFUN([BITCOIN_QT_CONFIGURE],[
fi fi
CPPFLAGS=$TEMP_CPPFLAGS CPPFLAGS=$TEMP_CPPFLAGS
]) ])
if test x$use_pkgconfig$qt_bin_path = xyes; then
if test x$bitcoin_qt_got_major_vers = x5; then
qt_bin_path="`$PKG_CONFIG --variable=host_bins Qt5Core 2>/dev/null`"
fi
fi
BITCOIN_QT_PATH_PROGS([MOC], [moc-qt${bitcoin_qt_got_major_vers} moc${bitcoin_qt_got_major_vers} moc], $qt_bin_path) BITCOIN_QT_PATH_PROGS([MOC], [moc-qt${bitcoin_qt_got_major_vers} moc${bitcoin_qt_got_major_vers} moc], $qt_bin_path)
BITCOIN_QT_PATH_PROGS([UIC], [uic-qt${bitcoin_qt_got_major_vers} uic${bitcoin_qt_got_major_vers} uic], $qt_bin_path) BITCOIN_QT_PATH_PROGS([UIC], [uic-qt${bitcoin_qt_got_major_vers} uic${bitcoin_qt_got_major_vers} uic], $qt_bin_path)
BITCOIN_QT_PATH_PROGS([RCC], [rcc-qt${bitcoin_qt_got_major_vers} rcc${bitcoin_qt_got_major_vers} rcc], $qt_bin_path) BITCOIN_QT_PATH_PROGS([RCC], [rcc-qt${bitcoin_qt_got_major_vers} rcc${bitcoin_qt_got_major_vers} rcc], $qt_bin_path)

25
configure.ac

@ -240,12 +240,25 @@ case $host in
AC_CHECK_PROG([BREW],brew, brew) AC_CHECK_PROG([BREW],brew, brew)
if test x$BREW = xbrew; then if test x$BREW = xbrew; then
dnl add default homebrew paths dnl These Homebrew packages may be bottled, meaning that they won't be found
openssl_prefix=`$BREW --prefix openssl` dnl in expected paths because they may conflict with system files. Ask
bdb_prefix=`$BREW --prefix berkeley-db4` dnl Homebrew where each one is located, then adjust paths accordingly.
export PKG_CONFIG_PATH="$openssl_prefix/lib/pkgconfig:$PKG_CONFIG_PATH" dnl It's safe to add these paths even if the functionality is disabled by
CPPFLAGS="$CPPFLAGS -I$bdb_prefix/include" dnl the user (--without-wallet or --without-gui for example).
LIBS="$LIBS -L$bdb_prefix/lib"
openssl_prefix=`$BREW --prefix openssl 2>/dev/null`
bdb_prefix=`$BREW --prefix berkeley-db4 2>/dev/null`
qt5_prefix=`$BREW --prefix qt5 2>/dev/null`
if test x$openssl_prefix != x; then
export PKG_CONFIG_PATH="$openssl_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
fi
if test x$bdb_prefix != x; then
CPPFLAGS="$CPPFLAGS -I$bdb_prefix/include"
LIBS="$LIBS -L$bdb_prefix/lib"
fi
if test x$qt5_prefix != x; then
export PKG_CONFIG_PATH="$qt5_prefix/lib/pkgconfig:$PKG_CONFIG_PATH"
fi
fi fi
else else
case $build_os in case $build_os in

26
contrib/macdeploy/macdeployqtplus

@ -393,7 +393,7 @@ def deployPlugins(appBundleInfo, deploymentInfo, strip, verbose):
# Deploy the script plugins only if QtScript is in use # Deploy the script plugins only if QtScript is in use
if not deploymentInfo.usesFramework("QtScript"): if not deploymentInfo.usesFramework("QtScript"):
continue continue
elif pluginDirectory == "qmltooling": elif pluginDirectory == "qmltooling" or pluginDirectory == "qml1tooling":
# Deploy the qml plugins only if QtDeclarative is in use # Deploy the qml plugins only if QtDeclarative is in use
if not deploymentInfo.usesFramework("QtDeclarative"): if not deploymentInfo.usesFramework("QtDeclarative"):
continue continue
@ -401,7 +401,23 @@ def deployPlugins(appBundleInfo, deploymentInfo, strip, verbose):
# Deploy the bearer plugins only if QtNetwork is in use # Deploy the bearer plugins only if QtNetwork is in use
if not deploymentInfo.usesFramework("QtNetwork"): if not deploymentInfo.usesFramework("QtNetwork"):
continue continue
elif pluginDirectory == "position":
# Deploy the position plugins only if QtPositioning is in use
if not deploymentInfo.usesFramework("QtPositioning"):
continue
elif pluginDirectory == "sensors" or pluginDirectory == "sensorgestures":
# Deploy the sensor plugins only if QtSensors is in use
if not deploymentInfo.usesFramework("QtSensors"):
continue
elif pluginDirectory == "audio" or pluginDirectory == "playlistformats":
# Deploy the audio plugins only if QtMultimedia is in use
if not deploymentInfo.usesFramework("QtMultimedia"):
continue
elif pluginDirectory == "mediaservice":
# Deploy the mediaservice plugins only if QtMultimediaWidgets is in use
if not deploymentInfo.usesFramework("QtMultimediaWidgets"):
continue
for pluginName in filenames: for pluginName in filenames:
pluginPath = os.path.join(pluginDirectory, pluginName) pluginPath = os.path.join(pluginDirectory, pluginName)
if pluginName.endswith("_debug.dylib"): if pluginName.endswith("_debug.dylib"):
@ -419,7 +435,11 @@ def deployPlugins(appBundleInfo, deploymentInfo, strip, verbose):
# Deploy the opengl graphicssystem plugin only if QtOpenGL is in use # Deploy the opengl graphicssystem plugin only if QtOpenGL is in use
if not deploymentInfo.usesFramework("QtOpenGL"): if not deploymentInfo.usesFramework("QtOpenGL"):
continue continue
elif pluginPath == "accessible/libqtaccessiblequick.dylib":
# Deploy the accessible qtquick plugin only if QtQuick is in use
if not deploymentInfo.usesFramework("QtQuick"):
continue
plugins.append((pluginDirectory, pluginName)) plugins.append((pluginDirectory, pluginName))
for pluginDirectory, pluginName in plugins: for pluginDirectory, pluginName in plugins:

Loading…
Cancel
Save