1dnl AG_GST_INIT 2dnl sets up use of GStreamer configure.ac macros 3dnl all GStreamer autoconf macros are prefixed 4dnl with AG_GST_ for public macros 5dnl with _AG_GST_ for private macros 6dnl 7dnl We call AC_CANONICAL_TARGET and AC_CANONICAL_HOST so that 8dnl it is valid before AC_ARG_PROGRAM is called 9 10AC_DEFUN([AG_GST_INIT], 11[ 12 m4_pattern_forbid(^_?AG_GST_) 13 AC_REQUIRE([AC_CANONICAL_HOST]) dnl we use host_ variables 14 AC_REQUIRE([AC_CANONICAL_TARGET]) dnl we use target_ variables 15]) 16 17dnl AG_GST_PKG_CONFIG_PATH 18dnl 19dnl sets up a GST_PKG_CONFIG_PATH variable for use in Makefile.am 20dnl which contains the path of the in-tree pkgconfig directory first 21dnl and then any paths specified in PKG_CONFIG_PATH. 22dnl 23dnl We do this mostly so we don't have to use unportable shell constructs 24dnl such as ${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH} in Makefile.am to handle 25dnl the case where the environment variable is not set, but also in order 26dnl to avoid a trailing ':' in the PKG_CONFIG_PATH which apparently causes 27dnl problems with pkg-config on windows with msys/mingw. 28AC_DEFUN([AG_GST_PKG_CONFIG_PATH], 29[ 30 GST_PKG_CONFIG_PATH="\$(top_builddir)/pkgconfig" 31 if test "x$PKG_CONFIG_PATH" != "x"; then 32 GST_PKG_CONFIG_PATH="$GST_PKG_CONFIG_PATH:$PKG_CONFIG_PATH" 33 fi 34 AC_SUBST([GST_PKG_CONFIG_PATH]) 35 AC_MSG_NOTICE([Using GST_PKG_CONFIG_PATH = $GST_PKG_CONFIG_PATH]) 36]) 37