build: Fix up the test rules for private deps

Thanks to diegoe for the help with testing.
This commit is contained in:
Emmanuele Bassi 2012-01-17 22:54:44 +00:00
parent f6ae8cf621
commit 7e4260ee8a

View File

@ -937,21 +937,23 @@ dnl === Dependencies, compiler flags and linker libraries =====================
# strip leading space # strip leading space
BACKEND_PC_FILES=${BACKEND_PC_FILES#* } BACKEND_PC_FILES=${BACKEND_PC_FILES#* }
# public dependencies, will fill the Requires: field of clutter.pc
CLUTTER_REQUIRES="$CLUTTER_BASE_PC_FILES $BACKEND_PC_FILES" CLUTTER_REQUIRES="$CLUTTER_BASE_PC_FILES $BACKEND_PC_FILES"
PKG_CHECK_MODULES(CLUTTER_DEPS, [$CLUTTER_REQUIRES]) PKG_CHECK_MODULES(CLUTTER_DEPS, [$CLUTTER_REQUIRES])
AC_SUBST(CLUTTER_REQUIRES)
AS_IF([test "x$CLUTTER_BASE_PC_FILES_PRIVATE" != "x" -o test "x$BACKEND_PC_FILES_PRIVATE" != "x"], # private dependencies, will fill the Requires.private: field of clutter.pc
[ AS_IF([test "x$CLUTTER_BASE_PC_FILES_PRIVATE" = "x" && test "x$BACKEND_PC_FILES_PRIVATE" = "x"],
CLUTTER_REQUIRES_PRIVATE="$CLUTTER_BASE_PC_FILES_PRIVATE $BACKEND_PC_FILES_PRIVATE"
PKG_CHECK_MODULES(CLUTTER_DEPS_PRIVATE, [$CLUTTER_REQUIRES_PRIVATE])
],
[ [
CLUTTER_REQUIRES_PRIVATE="" CLUTTER_REQUIRES_PRIVATE=""
CLUTTER_DEPS_PRIVATE_CFLAGS="" CLUTTER_DEPS_PRIVATE_CFLAGS=""
CLUTTER_DEPS_PRIVATE_LIBS="" CLUTTER_DEPS_PRIVATE_LIBS=""
],
[
CLUTTER_REQUIRES_PRIVATE="$CLUTTER_BASE_PC_FILES_PRIVATE $BACKEND_PC_FILES_PRIVATE"
PKG_CHECK_MODULES(CLUTTER_DEPS_PRIVATE, [$CLUTTER_REQUIRES_PRIVATE])
]) ])
AC_SUBST(CLUTTER_REQUIRES)
AC_SUBST(CLUTTER_REQUIRES_PRIVATE) AC_SUBST(CLUTTER_REQUIRES_PRIVATE)
CLUTTER_CFLAGS="$FLAVOUR_CFLAGS $CLUTTER_DEPS_CFLAGS $CLUTTER_DEPS_PRIVATE_CFLAGS $CLUTTER_PROFILE_CFLAGS $GLIB_CFLAGS" CLUTTER_CFLAGS="$FLAVOUR_CFLAGS $CLUTTER_DEPS_CFLAGS $CLUTTER_DEPS_PRIVATE_CFLAGS $CLUTTER_PROFILE_CFLAGS $GLIB_CFLAGS"