Port some changes from 0.6.0/0.6.1 back to HEAD (.pc files moved to pkg-config/,...
authorRonald S. Bultje <rbultje@ronald.bitfreak.net>
Mon, 7 Apr 2003 21:28:57 +0000 (21:28 +0000)
committerRonald S. Bultje <rbultje@ronald.bitfreak.net>
Mon, 7 Apr 2003 21:28:57 +0000 (21:28 +0000)
Original commit message from CVS:
Port some changes from 0.6.0/0.6.1 back to HEAD (.pc files moved to pkg-config/, .m4 file moved from plugins to core)

Makefile.am
configure.ac
gst-element-check.m4 [new file with mode: 0644]
gst-element-check.m4.in [new file with mode: 0644]
gstreamer-uninstalled.pc.in [deleted file]
gstreamer.spec.in
pkgconfig/Makefile.am [new file with mode: 0644]
pkgconfig/gstreamer-control-uninstalled.pc.in [new file with mode: 0644]
pkgconfig/gstreamer-control.pc.in [new file with mode: 0644]
pkgconfig/gstreamer-uninstalled.pc.in [new file with mode: 0644]
pkgconfig/gstreamer.pc.in [moved from gstreamer.pc.in with 100% similarity]

index 749da22..f15b5e0 100644 (file)
@@ -19,25 +19,27 @@ else
 SUBDIRS_EXAMPLES =
 endif
 
-SUBDIRS = include gst libs tools \
-       $(SUBDIRS_TESTS) $(SUBDIRS_EXAMPLES) $(SUBDIRS_DOCS)
-
-# These are all the possible subdirs
-DIST_SUBDIRS = include libs gst tools tests testsuite examples docs
+all-local: gst-element-check-@GST_MAJORMINOR@.m4
 
-all-local: gstreamer-@GST_MAJORMINOR@.pc gstreamer-@GST_MAJORMINOR@-uninstalled.pc
+gst-element-check-@GST_MAJORMINOR@.m4: gst-element-check.m4
+       cp $(srcdir)/gst-element-check.m4 gst-element-check-@GST_MAJORMINOR@.m4
 
-gstreamer-@GST_MAJORMINOR@.pc: gstreamer.pc gstreamer.pc.in
-       cp gstreamer.pc gstreamer-@GST_MAJORMINOR@.pc
-gstreamer-@GST_MAJORMINOR@-uninstalled.pc: gstreamer-uninstalled.pc gstreamer-uninstalled.pc.in
-       cp gstreamer-uninstalled.pc gstreamer-@GST_MAJORMINOR@-uninstalled.pc
+aclocaldir = $(datadir)/aclocal
+aclocal_DATA = gst-element-check-@GST_MAJORMINOR@.m4
 
-pkgconfigdir = $(libdir)/pkgconfig
-pkgconfig_DATA = gstreamer-@GST_MAJORMINOR@.pc
+SUBDIRS = include gst libs tools \
+       $(SUBDIRS_TESTS) $(SUBDIRS_EXAMPLES) $(SUBDIRS_DOCS) \
+       pkgconfig
 
-EXTRA_DIST = gstreamer.spec.in \
-            gstreamer.pc.in \
-            gstreamer-uninstalled.pc.in \
+# These are all the possible subdirs
+DIST_SUBDIRS = include libs gst \
+       tools \
+       tests testsuite \
+       examples \
+       docs \
+       pkgconfig
+
+EXTRA_DIST = gstreamer.spec.in gst-element-check.m4 \
             configure.ac autogen.sh depcomp \
             REQUIREMENTS ABOUT-NLS RELEASE DOCBUILDING DEVEL \
             idiottest.mak common
index 09f7443..785f920 100644 (file)
@@ -554,9 +554,12 @@ docs/pwg/Makefile
 docs/plugins/Makefile
 docs/plugins/gstreamer-plugins.types
 docs/xsl/Makefile
+pkgconfig/Makefile
 stamp.h
-gstreamer.pc
-gstreamer-uninstalled.pc
+pkgconfig/gstreamer.pc
+pkgconfig/gstreamer-uninstalled.pc
+pkgconfig/gstreamer-control.pc
+pkgconfig/gstreamer-control-uninstalled.pc
 gstreamer.spec,
 echo "$infomessages", infomessages="$infomessages"
 )
diff --git a/gst-element-check.m4 b/gst-element-check.m4
new file mode 100644 (file)
index 0000000..f900dac
--- /dev/null
@@ -0,0 +1,20 @@
+dnl Perform a check for a GStreamer element using gst-inspect
+dnl Thomas Vander Stichele <thomas at apestaart dot org>
+dnl Last modification: 23/10/2002
+
+dnl AM_GST_ELEMENT_CHECK(ELEMENT-NAME, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
+
+AC_DEFUN(AM_GST_ELEMENT_CHECK,
+[
+  AC_CHECK_PROG(GST_INSPECT, gst-inspect, gst-inspect, [])
+  if test "x$GST_INSPECT" != "x"; then
+    AC_MSG_CHECKING(GStreamer element $1)
+    if [ $GST_INSPECT $1 > /dev/null 2> /dev/null ]; then
+      AC_MSG_RESULT(found.)
+      $2
+    else
+      AC_MSG_RESULT(not found.)
+      $3
+    fi
+  fi
+])
diff --git a/gst-element-check.m4.in b/gst-element-check.m4.in
new file mode 100644 (file)
index 0000000..f900dac
--- /dev/null
@@ -0,0 +1,20 @@
+dnl Perform a check for a GStreamer element using gst-inspect
+dnl Thomas Vander Stichele <thomas at apestaart dot org>
+dnl Last modification: 23/10/2002
+
+dnl AM_GST_ELEMENT_CHECK(ELEMENT-NAME, ACTION-IF-FOUND, ACTION-IF-NOT-FOUND)
+
+AC_DEFUN(AM_GST_ELEMENT_CHECK,
+[
+  AC_CHECK_PROG(GST_INSPECT, gst-inspect, gst-inspect, [])
+  if test "x$GST_INSPECT" != "x"; then
+    AC_MSG_CHECKING(GStreamer element $1)
+    if [ $GST_INSPECT $1 > /dev/null 2> /dev/null ]; then
+      AC_MSG_RESULT(found.)
+      $2
+    else
+      AC_MSG_RESULT(not found.)
+      $3
+    fi
+  fi
+])
diff --git a/gstreamer-uninstalled.pc.in b/gstreamer-uninstalled.pc.in
deleted file mode 100644 (file)
index 484b937..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-# the standard variables don't make sense for an uninstalled copy
-prefix=
-exec_prefix=
-libdir=${pcfiledir}
-includedir=${pcfiledir}
-toolsdir=${pcfiledir}/tools
-gstcontrol_libs=-lgstcontrol-@GST_MAJORMINOR@
-
-Name: GStreamer Uninstalled
-Description: Streaming-media framework, Not Installed
-Version: @VERSION@
-Requires: @GST_PKG_DEPS@@LIBXML_PKG@
-Libs: ${libdir}/gst/libgstreamer-@GST_MAJORMINOR@.la -L${libdir}/libs/gst/control/
-Cflags: -I${includedir} -I${includedir}/libs -I${pc_top_builddir}/${pcfiledir}/@srcdir@ -I${pc_top_builddir}/${pcfiledir}/@srcdir@/libs @GST_PKG_CFLAGS@
index 635c0a3..27424af 100644 (file)
@@ -203,6 +203,7 @@ ln -sf %{_datadir}/gtk-doc/html/gstreamer-libs %{_datadir}/devhelp/books
 # %{_libdir}/libgstreamer.a
 %{_libdir}/libgstreamer-%{majorminor}.so
 %{_libdir}/libgstcontrol-%{majorminor}.so
+%{_datadir}/aclocal/gst-element-check-%{majorminor}.m4
 %{_libdir}/pkgconfig/gstreamer-%{majorminor}.pc
 ## we specify the API docs as regular files since %docs doesn't fail when
 #  files aren't found anymore for RPM >= 4
diff --git a/pkgconfig/Makefile.am b/pkgconfig/Makefile.am
new file mode 100644 (file)
index 0000000..a294dc1
--- /dev/null
@@ -0,0 +1,27 @@
+### all of the standard pc files we need to generate
+pcfiles = \
+       gstreamer-@GST_MAJORMINOR@.pc \
+       gstreamer-control-@GST_MAJORMINOR@.pc
+
+pcfiles_uninstalled = \
+       gstreamer-@GST_MAJORMINOR@-uninstalled.pc \
+       gstreamer-control-@GST_MAJORMINOR@-uninstalled.pc
+
+all-local: $(pcfiles) $(pcfiles_uninstalled)
+
+### how to generate pc files
+$(pcfiles): %-@GST_MAJORMINOR@.pc: %.pc
+       cp $< $@
+$(pcfiles_uninstalled): %-@GST_MAJORMINOR@-uninstalled.pc: %-uninstalled.pc
+       cp $< $@
+
+pkgconfigdir = $(libdir)/pkgconfig
+pkgconfig_DATA = $(pcfiles)
+
+EXTRA_DIST = \
+       gstreamer.pc.in \
+       gstreamer-uninstalled.pc.in \
+       gstreamer-control.pc.in \
+       gstreamer-control-uninstalled.pc.in
+
+CLEANFILES = $(pcfiles) $(pcfiles_uninstalled)
diff --git a/pkgconfig/gstreamer-control-uninstalled.pc.in b/pkgconfig/gstreamer-control-uninstalled.pc.in
new file mode 100644 (file)
index 0000000..a2f0a46
--- /dev/null
@@ -0,0 +1,14 @@
+# the standard variables don't make sense for an uninstalled copy
+prefix=
+exec_prefix=
+libdir=${pcfiledir}/../libs
+includedir=${pcfiledir}/..
+gstcontrol_libs=-lgstcontrol-@GST_MAJORMINOR@
+
+Name: GStreamer control library, uninstalled
+Description: Dynamic parameters for plug-ins
+Requires: gstreamer-@GST_MAJORMINOR@ = @VERSION@
+Version: @VERSION@
+
+Libs: ${libdir}/gst/control/libgstcontrol-@GST_MAJORMINOR@.la
+Cflags: -I${includedir} -I${includedir}/libs @GST_PKG_CFLAGS@
diff --git a/pkgconfig/gstreamer-control.pc.in b/pkgconfig/gstreamer-control.pc.in
new file mode 100644 (file)
index 0000000..563f6c9
--- /dev/null
@@ -0,0 +1,11 @@
+prefix=@prefix@
+exec_prefix=@exec_prefix@
+libdir=@libdir@
+includedir=@includedir@/gstreamer-@GST_MAJORMINOR@
+
+Name: GStreamer control library
+Description: Dynamic parameters for plug-ins
+Requires: gstreamer-@GST_MAJORMINOR@
+Version: @VERSION@
+Libs: -L${libdir} -lgstcontrol-@GST_MAJORMINOR@
+Cflags: -I${includedir} @GST_PKG_CFLAGS@
diff --git a/pkgconfig/gstreamer-uninstalled.pc.in b/pkgconfig/gstreamer-uninstalled.pc.in
new file mode 100644 (file)
index 0000000..6a695b2
--- /dev/null
@@ -0,0 +1,14 @@
+# the standard variables don't make sense for an uninstalled copy
+prefix=
+exec_prefix=
+libdir=${pcfiledir}/..
+includedir=${pcfiledir}/..
+toolsdir=${pcfiledir}/../tools
+gstcontrol_libs=-lgstcontrol-@GST_MAJORMINOR@
+
+Name: GStreamer Uninstalled
+Description: Streaming-media framework, Not Installed
+Version: @VERSION@
+Requires: @GST_PKG_DEPS@@LIBXML_PKG@
+Libs: ${libdir}/gst/libgstreamer-@GST_MAJORMINOR@.la
+Cflags: -I${includedir} -I${includedir}/libs @GST_PKG_CFLAGS@
similarity index 100%
rename from gstreamer.pc.in
rename to pkgconfig/gstreamer.pc.in