aboutsummaryrefslogtreecommitdiffstats
path: root/acinclude.m4
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2015-07-09 21:09:48 -0700
committerGuy Harris <guy@alum.mit.edu>2015-07-10 21:30:33 +0000
commita1a2d50716ae3c1fb882726c82e98815faca2b27 (patch)
treeed0414e97c48012607c1725016f18cbe8d460cc1 /acinclude.m4
parenta63f841fec2a7c0dd3d42f24a85fde0b447ee790 (diff)
Make .o files, not .cpp and .h files, depend on the ui_*.h files.
That's one of the mechanisms the autotools documentation suggests using to handle generated header files. Using it means that "make dist" will no longer try to build those files (they're not part of the distribution - and they can't be, as the files would be different for Qt 4 and Qt 5, and need to be generated by the uic from the same version of Qt as the one against which Wireshark is being built). This means we don't need to try to find uic, moc, or rcc if we're not building with Qt, so don't do so. Change-Id: Id2aadb8289598b82e14e4ed402ff8cdc15fdef74 Reviewed-on: https://code.wireshark.org/review/9583 Petri-Dish: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'acinclude.m4')
-rw-r--r--acinclude.m4116
1 files changed, 39 insertions, 77 deletions
diff --git a/acinclude.m4 b/acinclude.m4
index 7c5aa1e7ab..b92e455d5f 100644
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -2133,99 +2133,61 @@ AC_DEFUN([AC_WIRESHARK_QT_CHECK],
])
dnl AC_WIRESHARK_QT_TOOL_CHECK([TOOLPATHVAR, TOOL, REQUESTED-MAJOR_VERSION])
-dnl Test for a particular Qt tool, either for any version of Qt or for
-dnl some specific version of Qt
+dnl Test for a particular Qt tool for some specific version of Qt
dnl
AC_DEFUN([AC_WIRESHARK_QT_TOOL_CHECK],
[
- if test ! -z "$3"; then
- #
- # We're building with Qt, so we're looking for a particular
- # major version of Qt's flavor of that tool.
- #
- # If we don't find the tool, we can't build, so we fail.
- #
- # At least in some versions of Debian/Ubuntu, and perhaps
- # other OSes, the Qt build tools are just links to a
- # program called "qtchooser", and even if you want to
- # build with Qt 5, running the tool might give you the
- # Qt 4 version of the tool unless you run the tool with
- # a -qt=5 argument.
+ #
+ # At least in some versions of Debian/Ubuntu, and perhaps
+ # other OSes, the Qt build tools are just links to a
+ # program called "qtchooser", and even if you want to
+ # build with Qt 5, running the tool might give you the
+ # Qt 4 version of the tool unless you run the tool with
+ # a -qt=5 argument.
+ #
+ # So we look for qtchooser and, if we find it, use the
+ # -qt={version} argument, otherwise we look for particular
+ # tool versions using tool name suffixes.
+ #
+ AC_PATH_PROG(QTCHOOSER, qtchooser)
+ if test ! -z "$QTCHOOSER"; then
#
- # So we look for qtchooser and, if we find it, use the
- # -qt={version} argument, otherwise we look for particular
- # tool versions using tool name suffixes.
+ # We found qtchooser; we assume that means that
+ # the tool is linked to qtchooser, so that we
+ # can run it with the -qt={version} flag to get
+ # the appropriate version of the tool.
#
- AC_PATH_PROG(QTCHOOSER, qtchooser)
- if test ! -z "$QTCHOOSER"; then
- #
- # We found qtchooser; we assume that means that
- # the tool is linked to qtchooser, so that we
- # can run it with the -qt={version} flag to get
- # the appropriate version of the tool.
- #
- AC_PATH_PROG($1, $2)
- if test "x$$1" = x; then
- #
- # We can't build Qt Wireshark without that
- # tool..
- #
- AC_MSG_ERROR(I couldn't find $2; make sure it's installed and in your path)
- fi
-
- #
- # Add the -qt={version} argument to it.
- #
- $1="$$1 -qt=$qt_version"
- else
- #
- # Annoyingly, on some Linux distros (e.g. Debian)
- # the Qt 5 tools have no suffix and the Qt 4 tools
- # have suffix -qt4. On other distros (e.g. openSUSE)
- # the Qt 5 tools have suffix -qt5 and the Qt 4 tools
- # have no suffix.
+ AC_PATH_PROG($1, $2)
+ if test "x$$1" = x; then
#
- # So we check for the tool first with the -qtN suffix
- # and then with no suffix.
+ # We can't build Qt Wireshark without that
+ # tool..
#
- AC_PATH_PROGS($1, [$2-qt$qt_version $2])
- if test "x$$1" = x; then
- #
- # We can't build Qt Wireshark without that
- # tool..
- #
- AC_MSG_ERROR(I couldn't find $2-qt$qt_version or $2; make sure it's installed and in your path)
- fi
+ AC_MSG_ERROR(I couldn't find $2; make sure it's installed and in your path)
fi
- else
+
#
- # We're not building with Qt, so we just want some version
- # of the tool.
+ # Add the -qt={version} argument to it.
#
- # If we don't find the tool, we shouldn't fail, as the
- # user's not building with Qt, and we shouldn't force them
- # to have Qt installed if they're not doing so.
+ $1="$$1 -qt=$qt_version"
+ else
#
- # "make dist" will fail if they do that, but
- # we don't know whether they'll be doing that,
- # so this is the best we can do.
+ # Annoyingly, on some Linux distros (e.g. Debian)
+ # the Qt 5 tools have no suffix and the Qt 4 tools
+ # have suffix -qt4. On other distros (e.g. openSUSE)
+ # the Qt 5 tools have suffix -qt5 and the Qt 4 tools
+ # have no suffix.
#
- # For the annoying suffix reasons listed above, we check
- # for the tool first with the -qt5 suffix, then with no
- # suffix, then with the -qt4 suffix.
+ # So we check for the tool first with the -qtN suffix
+ # and then with no suffix.
#
- AC_PATH_PROGS($1, [$2-qt5 $2 $2-qt4])
+ AC_PATH_PROGS($1, [$2-qt$qt_version $2])
if test "x$$1" = x; then
#
- # We shouldn't fail here, as the user's not
- # building with Qt, and we shouldn't force them
- # to have Qt installed if they're not doing so.
- #
- # "make dist" will fail if they do that, but
- # we don't know whether they'll be doing that,
- # so this is the best we can do.
+ # We can't build Qt Wireshark without that
+ # tool..
#
- $1=$$2
+ AC_MSG_ERROR(I couldn't find $2-qt$qt_version or $2; make sure it's installed and in your path)
fi
fi
])