find all tools in same dir as moc; refs #40

master
Marc Wäckerlin 11 years ago
parent dcab643014
commit d760542ebb
  1. 22
      configure.in

@ -180,21 +180,29 @@ else
AC_ARG_WITH([moc], AC_ARG_WITH([moc],
AC_HELP_STRING([--with-moc=/path/to/moc], AC_HELP_STRING([--with-moc=/path/to/moc],
[to specify the path to qt moc.]), [to specify the path to qt moc.]),
[MOC="$withval"], [MOC="$withval"
[MOC=""]) RCC="$(dirname $withval")/rcc"
AC_CHECK_PROGS([MOC], [$MOC moc moc-qt4 moc-mac]) UIC="$(dirname $withval")/uic"
LRELEASE="$(dirname $withval")/lrelease"
LUPDATE="$(dirname $withval")/lupdate"],
[MOC=""
RCC=""
UIC=""
LRELEASE=""
LUPDATE=""])
AC_CHECK_PROGS([MOC], ["$MOC" moc moc-qt4 moc-mac])
test -n "$MOC" || AC_MSG_ERROR([moc for Qt not found!]) test -n "$MOC" || AC_MSG_ERROR([moc for Qt not found!])
AC_SUBST(MOC) AC_SUBST(MOC)
AC_CHECK_PROGS([RCC], [$(dirname $MOC)/rcc rcc rcc-qt4 rcc-mac]) AC_CHECK_PROGS([RCC], ["$RCC" rcc rcc-qt4 rcc-mac])
test -n "$RCC" || AC_MSG_ERROR([rcc for Qt not found!]) test -n "$RCC" || AC_MSG_ERROR([rcc for Qt not found!])
AC_SUBST(RCC) AC_SUBST(RCC)
AC_CHECK_PROGS([UIC], [$(dirname $MOC)/uic uic uic-qt4 uic-mac]) AC_CHECK_PROGS([UIC], ["$UIC" uic uic-qt4 uic-mac])
test -n "$UIC" || AC_MSG_ERROR([uic for Qt not found!]) test -n "$UIC" || AC_MSG_ERROR([uic for Qt not found!])
AC_SUBST(UIC) AC_SUBST(UIC)
AC_CHECK_PROGS([LRELEASE], [$(dirname $MOC)/lrelease lrelease lrelease-qt4 lrelease-mac]) AC_CHECK_PROGS([LRELEASE], ["$LRELEASE" lrelease lrelease-qt4 lrelease-mac])
test -n "$LRELEASE" || AC_MSG_ERROR([lrelease for Qt not found!]) test -n "$LRELEASE" || AC_MSG_ERROR([lrelease for Qt not found!])
AC_SUBST(LRELEASE) AC_SUBST(LRELEASE)
AC_CHECK_PROGS([LUPDATE], [$(dirname $MOC)/lupdate lupdate lupdate-qt4 lupdate-mac]) AC_CHECK_PROGS([LUPDATE], ["$LUPDATE" lupdate lupdate-qt4 lupdate-mac])
test -n "$LUPDATE" || AC_MSG_ERROR([lupdate for Qt not found!]) test -n "$LUPDATE" || AC_MSG_ERROR([lupdate for Qt not found!])
AC_SUBST(LUPDATE) AC_SUBST(LUPDATE)
AC_ARG_VAR(LUPDATE_ARGS, [arguments for qt lupdate command, e.g. -no-obsolete]) AC_ARG_VAR(LUPDATE_ARGS, [arguments for qt lupdate command, e.g. -no-obsolete])

Loading…
Cancel
Save