diff --git a/INSTALL b/INSTALL index 8b641e3..ddcdb76 120000 --- a/INSTALL +++ b/INSTALL @@ -1 +1 @@ -/usr/share/automake-1.13/INSTALL \ No newline at end of file +/usr/share/automake-1.15/INSTALL \ No newline at end of file diff --git a/ax_check_qt.m4 b/ax_check_qt.m4 index e0eecf2..1781f62 100644 --- a/ax_check_qt.m4 +++ b/ax_check_qt.m4 @@ -119,10 +119,25 @@ AC_DEFUN([AX_CHECK_QT], [ AC_DEFINE([HAVE_$1]) QTDIR=$(${PKG_CONFIG} --variable=prefix Qt5Core) qt_host_bins=$(${PKG_CONFIG} --variable=host_bins Qt5Core) - if test -d "${qt_host_bins}"; then - QT_PLUGIN_PATH=${qt_host_bins}/../plugins + qt_libdir=$(${PKG_CONFIG} --variable=libdir Qt5Core) + if test -d "${qt_libdir}" -a -d "${qt_libdir}/plugins"; then + QT_PLUGIN_PATH="${qt_libdir}/plugins" + elif test -d "${qt_libdir}/qt5" -a -d "${qt_libdir}/qt5/plugins"; then + QT_PLUGIN_PATH="${qt_libdir}/qt5/plugins" + elif test -d "${qt_host_bins}" -a -d "${qt_host_bins}/../plugins"; then + QT_PLUGIN_PATH="${qt_host_bins}/../plugins" + elif test -d "${QTDIR}/plugins; then + QT_PLUGIN_PATH="${QTDIR}/plugins" + elif test -d "${QTDIR}/share/qt5/plugins; then + QT_PLUGIN_PATH="${QTDIR}/share/qt5/plugins" else - QT_PLUGIN_PATH=${QTDIR}/share/qt5/plugins + AC_MSG_ERROR([QT_PLUGIN_PATH not found + - not in: ${qt_libdir}/plugins + - not in: ${qt_libdir}/qt5/plugins + - not in: ${qt_host_bins}/../plugins + - not in: ${QTDIR}/plugins + - not in: ${QTDIR}/share/qt5/plugins +]) fi MOC_FLAGS+=" -DHAVE_$1=1 ${[$1]5_CFLAGS}" [$1]_CPPFLAGS="${[$1]5_CFLAGS}" @@ -166,10 +181,25 @@ AC_DEFUN([AX_CHECK_QT], [ AC_DEFINE([HAVE_$1]) QTDIR=$(${PKG_CONFIG} --variable=prefix QtCore) qt_host_bins=$(${PKG_CONFIG} --variable=host_bins QtCore) - if test -d "${qt_host_bins}"; then - QT_PLUGIN_PATH=${qt_host_bins}/../plugins + qt_libdir=$(${PKG_CONFIG} --variable=libdir QtCore) + if test -d "${qt_libdir}" -a -d "${qt_libdir}/plugins"; then + QT_PLUGIN_PATH="${qt_libdir}/plugins" + elif test -d "${qt_libdir}/qt5" -a -d "${qt_libdir}/qt5/plugins"; then + QT_PLUGIN_PATH="${qt_libdir}/qt5/plugins" + elif test -d "${qt_host_bins}" -a -d "${qt_host_bins}/../plugins"; then + QT_PLUGIN_PATH="${qt_host_bins}/../plugins" + elif test -d "${QTDIR}/plugins; then + QT_PLUGIN_PATH="${QTDIR}/plugins" + elif test -d "${QTDIR}/share/qt5/plugins; then + QT_PLUGIN_PATH="${QTDIR}/share/qt5/plugins" else - QT_PLUGIN_PATH=${QTDIR}/share/qt/plugins + AC_MSG_ERROR([QT_PLUGIN_PATH not found + - not in: ${qt_libdir}/plugins + - not in: ${qt_libdir}/qt5/plugins + - not in: ${qt_host_bins}/../plugins + - not in: ${QTDIR}/plugins + - not in: ${QTDIR}/share/qt5/plugins +]) fi MOC_FLAGS+=" -DHAVE_$1=1 ${$1_CFLAGS}" [$1]_CPPFLAGS="${[$1]_CFLAGS}" @@ -214,9 +244,6 @@ AC_DEFUN([AX_CHECK_QT], [ AX_CHECK_VALID_CXX_FLAG([-Wl,-subsystem,windows], [windows console flag]) fi test "x$prefix" = xNONE && prefix=$ac_default_prefix - if test "${QT_PLUGIN_PATH}" = "${QT_PLUGIN_PATH#${prefix}}"; then - QT_PLUGIN_PATH=${prefix}${QT_PLUGIN_PATH#/usr} - fi AC_ARG_WITH([qt-plugin-path], [AS_HELP_STRING([--with-qt-plugin-path=PATH], [define a different qt plugin path, current @<:@default=check@:>@])], diff --git a/ax_init_standard_project.m4 b/ax_init_standard_project.m4 index b13fb76..b27de97 100644 --- a/ax_init_standard_project.m4 +++ b/ax_init_standard_project.m4 @@ -218,7 +218,7 @@ AC_DEFUN([AX_INIT_STANDARD_PROJECT], [ AX_SUBST(AUTHOR_URL) AX_SUBST(AUTHOR_MAIL) AX_SUBST(PACKAGER) - PROJECT_URL="${PROJECT_URL:-${AUTHOR_URL}/projects/${PACKAGE_NAME}}" + #PROJECT_URL="${PROJECT_URL:-${AUTHOR_URL}}" SOURCE_DOWNLOAD="${SOURCE_DOWNLOAD:-${AUTHOR_URL}/downloads/${PACKAGE_NAME}}" AX_SUBST(PROJECT_URL) AX_SUBST(SOURCE_DOWNLOAD) @@ -365,12 +365,13 @@ AC_DEFUN([AX_USE_CXX], [ #### Begin: Appended by $0 %.app: % -rm -r [\$][@] - \$(MAKE) DESTDIR=[\$][\$](pwd)/[\$][@]/tmp install + \$(MAKE) DESTDIR=[\$][\$](pwd)/tmp install QTDIR="\${QTDIR}" \ QT_PLUGINS="\${QT_PLUGINS}" \ QT_PLUGIN_PATH="\${QT_PLUGIN_PATH}" \ \${top_builddir}/mac-create-app-bundle.sh \ - [\$][@] [\$][<] [\$][\$](pwd)/[\$][@]/tmp\${prefix} + [\$][@] [\$][<] [\$][\$](pwd)/tmp[\$]{prefix} + -rm -rf tmp maintainer-clean-cxx-targets: -rm makefile.in diff --git a/build-in-docker.sh b/build-in-docker.sh index 6541cbf..db6ee0d 100755 --- a/build-in-docker.sh +++ b/build-in-docker.sh @@ -248,18 +248,18 @@ case $mode in docker exec ${DOCKER_ID} update-locale LANG=${LANG} fi OPTIONS='-o Dpkg::Options::=--force-confdef -o Dpkg::Options::=--force-confnew -y --force-yes --no-install-suggests --no-install-recommends' - PREVENT='libpam-systemd- policykit*- colord-' - for f in 'libpam-systemd' 'policykit*' 'colord'; do - docker exec ${DOCKER_ID} bash -c "echo 'Package: $f' >> /etc/apt/preferences" + PREVENT='libpam-systemd policykit.* colord dconf-service' + for f in ${PREVENT}; do + docker exec ${DOCKER_ID} bash -c "echo 'Package: ${f}' >> /etc/apt/preferences" docker exec ${DOCKER_ID} bash -c "echo 'Pin-Priority: -100' >> /etc/apt/preferences" docker exec ${DOCKER_ID} bash -c "echo >> /etc/apt/preferences" done docker exec ${DOCKER_ID} apt-get update ${OPTIONS} - docker exec ${DOCKER_ID} apt-mark hold 'libpam-systemd' 'policykit*' 'colord' + docker exec ${DOCKER_ID} apt-mark hold ${PREVENT} docker exec ${DOCKER_ID} apt-get upgrade ${OPTIONS} - docker exec ${DOCKER_ID} apt-get install ${OPTIONS} ${PREVENT} python-software-properties software-properties-common apt-transport-https dpkg-dev lsb-release wget || \ - docker exec ${DOCKER_ID} apt-get install ${OPTIONS} ${PREVENT} software-properties-common apt-transport-https dpkg-dev lsb-release wget || \ - docker exec ${DOCKER_ID} apt-get install ${OPTIONS} ${PREVENT} python-software-properties apt-transport-https dpkg-dev lsb-release wget; + docker exec ${DOCKER_ID} apt-get install ${OPTIONS} ${PREVENT// /- }- python-software-properties software-properties-common apt-transport-https dpkg-dev lsb-release wget || \ + docker exec ${DOCKER_ID} apt-get install ${OPTIONS} ${PREVENT// /- }- software-properties-common apt-transport-https dpkg-dev lsb-release wget || \ + docker exec ${DOCKER_ID} apt-get install ${OPTIONS} ${PREVENT// /- }- python-software-properties apt-transport-https dpkg-dev lsb-release wget; for key in "${keys[@]}"; do wget -O- "$key" \ | docker exec -i ${DOCKER_ID} apt-key add - @@ -267,6 +267,9 @@ case $mode in for repo in "${repos[@]}"; do ifthenelse "${repo}" "apt-add-repository 'ARG'" done + + + docker exec ${DOCKER_ID} apt-get update ${OPTIONS} for package in "${packages[@]}"; do ifthenelse "${package}" "apt-get install ${OPTIONS} ${PREVENT} ARG" diff --git a/mac-create-app-bundle.sh b/mac-create-app-bundle.sh index 7ff4573..6b76c09 100755 --- a/mac-create-app-bundle.sh +++ b/mac-create-app-bundle.sh @@ -17,14 +17,12 @@ if test "$(uname -s)" != "Darwin"; then exit 1 fi -cd ${0%/*} - project=${2:-$(sed -n 's/ *m4_define *( *x_package_name, *\(.*\) *).*/\1/p' $(pwd)/configure.ac)} apptarget=${1:-${project}.app} -sources=${3:-$(pwd)/usr} +sources=${3:-$(pwd)/tmp} +! test -e "$apptarget" || rm -rf "$apptarget" test -n "$project" test -d "$sources" -! test -e "$apptarget" || rm -rf "$apptarget" target="$(pwd)/${apptarget}/Contents/MacOS" echo "Creating $apptarget for $project from $sources" @@ -32,7 +30,9 @@ echo "Creating $apptarget for $project from $sources" # Step 1: create and fill app directory structure mkdir -p ${apptarget}/Contents/{Resources,MacOS} ! test -d ${sources}/bin || \ - find ${sources}/bin -mindepth 1 -maxdepth 1 -exec cp -a {} ${apptarget}/Contents/MacOS/ \; + find ${sources}/bin -mindepth 1 -maxdepth 1 -exec cp -a {} ${apptarget}/Contents/MacOS/ \; +! test -d ${sources}/scripts || \ + find ${sources}/scripts -mindepth 1 -maxdepth 1 -exec cp -a {} ${apptarget}/Contents/MacOS/ \; executablefile=${apptarget}/Contents/MacOS/${project} test -x $executablefile || executablefile=$(ls -1 ${apptarget}/Contents/MacOS/ | head -1) ! test -d ${sources}/lib || \ @@ -40,9 +40,9 @@ test -x $executablefile || executablefile=$(ls -1 ${apptarget}/Contents/MacOS/ | ! test -d ${sources}/share/${project} || \ find ${sources}/share/${project} -mindepth 1 -maxdepth 1 -exec cp -a {} ${apptarget}/Contents/Resources/ \; ! test -d ${sources}/share || \ - find ${sources}/share -mindepth 1 -maxdepth 1 -exec cp -a {} ${apptarget}/Contents/Resources/ \; + find ${sources}/share -mindepth 1 -maxdepth 1 -name ${project} -prune -o -exec cp -a {} ${apptarget}/Contents/Resources/ \; ! test -d ${sources} || \ - find ${sources} -mindepth 1 -maxdepth 1 -exec cp -a {} ${apptarget}/Contents/Resources/ \; + find ${sources} -mindepth 1 -maxdepth 1 -name share -o -name bin -o -name lib -o -name scripts -prune -o -exec cp -a {} ${apptarget}/Contents/Resources/ \; # Step 2: copy qt plugins, if necessary for f in ${QT_PLUGINS}; do @@ -59,7 +59,7 @@ while [ $found -ne 0 ]; do cd "${target}" for file in $(find . -type f); do for lib in $(otool -L ${file} | tail -n +2 \ - | egrep '/opt/local/|'"${HOME}" \ + | egrep '/usr/local/|/opt/local/|'"${HOME}" \ | grep -v $file | awk '{print $1}'); do found=1 test -f ${lib##*/} \