From 7eff34a95bf51c057db47966cc860daaf3f56646 Mon Sep 17 00:00:00 2001 From: "Yann E. MORIN\"" Date: Thu, 22 Mar 2012 12:03:51 +0100 Subject: [PATCH] configure: detect moc properly The moc executable used for Qt may be installed under different names in different places. Try to identify one that matches the version of Qt that is being used. Signed-off-by: Peter Kjellerstedt [yann.morin.1998@free.fr: fix MOC under-quotation, fix code layout] Signed-off-by: "Yann E. MORIN" --- configure.ac | 8 +++++++- frontends/qconf/Makefile.am | 2 +- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index ab2f572..e605e86 100644 --- a/configure.ac +++ b/configure.ac @@ -285,7 +285,13 @@ AS_IF( AS_IF( [test "$has_qt" = "no" ], - [enable_qconf=no]) + [enable_qconf=no], + [QT4_BINDIR=`$PKG_CONFIG Qt --variable bindir` + AC_PATH_PROGS( + [MOC], + [moc-qt4 moc], + [moc], + [$QT4_BINDIR:$PATH])]) #---------------------------------------- # Per-frontends extra libraries diff --git a/frontends/qconf/Makefile.am b/frontends/qconf/Makefile.am index 9946857..5815271 100644 --- a/frontends/qconf/Makefile.am +++ b/frontends/qconf/Makefile.am @@ -12,4 +12,4 @@ qconf_LDADD = $(top_builddir)/libs/parser/libkconfigparser.la \ $(qt4_LIBS) $(qconf_EXTRA_LIBS) .h.moc: - moc -i $< -o $@ + $(MOC) -i $< -o $@ -- 2.39.5