QtNetwork depends on QT >= 5.2

master
Marc Wäckerlin 10 years ago
parent 2d32b17df6
commit 6dd045a8ff
  1. 28
      ax_check_qt.m4
  2. 12
      ax_init_standard_project.m4
  3. 2
      configure.ac

@ -104,24 +104,14 @@ AC_DEFUN([AX_CHECK_QT], [
MOC_FLAGS+=" -DHAVE_$1=1 ${[$1]5_CFLAGS}"
AM_CXXFLAGS+=" ${[$1]5_CFLAGS}"
LIBS+=" ${[$1]5_LIBS}"
modules=${qt_modules//Qt/Qt5}
if test -z "$PKG_REQUIREMENTS"; then
PKG_REQUIREMENTS="${modules// /, }"
else
PKG_REQUIREMENTS="${PKG_REQUIREMENTS}, ${modules// /, }"
fi
PKG_REQUIREMENTS+=" ${qt_modules//Qt/Qt5}"
if test -n "${qt_modules_optional}"; then
PKG_CHECK_MODULES([$1]5_OPTIONAL, [${qt_modules_optional//Qt/Qt5}], [
AM_CPPFLAGS+=" ${[$1]5_OPTIONAL_CFLAGS}"
MOC_FLAGS+=" ${[$1]5_OPTIONAL_CFLAGS}"
AM_CXXFLAGS+=" ${[$1]5_OPTIONAL_CFLAGS}"
LIBS+=" ${[$1]5_OPTIONAL_LIBS}"
modules=${qt_modules_optional//Qt/Qt5}
if test -z "$PKG_REQUIREMENTS"; then
PKG_REQUIREMENTS="${modules// /, }"
else
PKG_REQUIREMENTS="${PKG_REQUIREMENTS}, ${modules// /, }"
fi
PKG_REQUIREMENTS+=" ${qt_modules_optional//Qt/Qt5}"
], [
AC_MSG_NOTICE([Not found: ${qt_modules_optional//Qt/Qt5}])
])
@ -134,24 +124,14 @@ AC_DEFUN([AX_CHECK_QT], [
MOC_FLAGS+=" -DHAVE_$1=1 ${$1_CFLAGS}"
AM_CXXFLAGS+=" ${$1_CFLAGS}"
LIBS+=" ${$1_LIBS}"
modules=${qt_modules}
if test -z "$PKG_REQUIREMENTS"; then
PKG_REQUIREMENTS="${modules// /, }"
else
PKG_REQUIREMENTS="${PKG_REQUIREMENTS}, ${modules// /, }"
fi
PKG_REQUIREMENTS+=" ${qt_modules}"
if test -n "$3"; then
PKG_CHECK_MODULES($1_OPTIONAL, [${qt_modules_optional}], [
AM_CPPFLAGS+=" ${$1_OPTIONAL_CFLAGS}"
MOC_FLAGS+=" ${$1_OPTIONAL_CFLAGS}"
AM_CXXFLAGS+=" ${$1_OPTIONAL_CFLAGS}"
LIBS+=" ${$1_OPTIONAL_LIBS}"
modules=${qt_modules_optional}
if test -z "$PKG_REQUIREMENTS"; then
PKG_REQUIREMENTS="${modules// /, }"
else
PKG_REQUIREMENTS="${PKG_REQUIREMENTS}, ${modules// /, }"
fi
PKG_REQUIREMENTS+=" ${qt_modules_optional}"
], [
AC_MSG_NOTICE([Not found: ${qt_modules_optional}])
])

@ -399,11 +399,7 @@ AC_DEFUN([AX_PKG_REQUIRE], [
AM_CPPFLAGS+=" ${$1_CFLAGS}"
AM_CXXFLAGS+=" ${$1_CFLAGS}"
LIBS+=" ${$1_LIBS}"
if test -z "$PKG_REQUIREMENTS"; then
PKG_REQUIREMENTS="$2"
else
PKG_REQUIREMENTS="${PKG_REQUIREMENTS}, $2"
fi
PKG_REQUIREMENTS+=" $2"
], [
AC_MSG_WARN([Recommended package $2 for feature $1 not installed])
if test -n "$4"; then
@ -435,11 +431,7 @@ AC_DEFUN([AX_PKG_REQUIRE], [
AM_CPPFLAGS+=" ${$1_CFLAGS}"
AM_CXXFLAGS+=" ${$1_CFLAGS}"
LIBS+=" ${$1_LIBS}"
if test -z "$PKG_REQUIREMENTS"; then
PKG_REQUIREMENTS="$pkg"
else
PKG_REQUIREMENTS="${PKG_REQUIREMENTS}, $pkg"
fi
PKG_REQUIREMENTS+=" $pkg"
], [
AC_MSG_WARN([Recommended package $pkg for feature $1 not installed])
])

@ -35,7 +35,7 @@ AC_ARG_ENABLE(pkcs11-download,
# qt features
AX_CHECK_QT([QTGUI], [QtCore QtGui], [QtWidgets])
AX_CHECK_QT([QTNETWORK], [QtNetwork])
AX_CHECK_QT([QTNETWORK], [Qt5Network >= 5.2])
CPPFLAGS="${CPPFLAGS} -DQT_NO_KEYWORDS"
# libraries used

Loading…
Cancel
Save