Commit 2c21340c authored by Tim-Philipp Müller's avatar Tim-Philipp Müller

examples: get the right Qt moc binary to use via pkg-config

Should make us do the right thing in cases where both Qt3 and Qt4
are installed.

Fixes #620211.
parent c5c1b681
......@@ -291,6 +291,12 @@ PKG_CHECK_MODULES(QT, QtGui >= 4.6, [
HAVE_QT_GV=no
PKG_CHECK_MODULES(QT, QtGui >= 4.0, HAVE_QT=yes, HAVE_QT=no)
])
if test "x$HAVE_QT" = "xyes"; then
AC_MSG_CHECKING([Qt moc])
QT4_MOC=`$PKG_CONFIG --variable=moc_location QtGui`
AC_MSG_RESULT($QT4_MOC)
AC_SUBST(QT4_MOC)
fi
AM_CONDITIONAL(HAVE_QT, test "x$HAVE_QT" = "xyes")
AM_CONDITIONAL(HAVE_QT_GV, test "x$HAVE_QT_GV" = "xyes")
......
......@@ -34,7 +34,7 @@ qtgv_xoverlay_LDADD = $(GST_LIBS) $(X_LIBS) $(LIBM) $(QT_LIBS) \
nodist_qtgv_xoverlay_SOURCES = moc_qtgv-xoverlay.cpp
moc_%.cpp:%.h
$(AM_V_GEN)moc $< -o $@
$(AM_V_GEN)$(QT4_MOC) $< -o $@
EXTRA_DIST = $(nodist_qtgv_xoverlay_SOURCES:moc_%.cpp=%.h)
CLEANFILES = $(nodist_qtgv_xoverlay_SOURCES)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment