Abstract the plugin-srcdir installation idiottest into a separate file, and include...
authorRichard Boulton <richard@tartarus.org>
Thu, 31 May 2001 18:35:11 +0000 (18:35 +0000)
committerRichard Boulton <richard@tartarus.org>
Thu, 31 May 2001 18:35:11 +0000 (18:35 +0000)
Original commit message from CVS:
Abstract the plugin-srcdir installation idiottest into a separate file,
and include it from the include Makefile.am, to ensure that it gets
called at the start of a make install process, not after the whole thing
has happened.

Makefile.am
idiottest.mak [new file with mode: 0644]
include/Makefile.am

index 2b14530..e81b6ee 100644 (file)
@@ -34,7 +34,8 @@ man_MANS = gstreamer-config.1
 EXTRA_DIST = gstreamer.spec.in gstreamer-config.in gstreamer.m4 \
             gstreamer.pc.in gstreamer-uninstalled.pc.in \
             configure.base autogen.sh \
-            LICENSE REQUIREMENTS ABOUT-NLS $(man_MANS)
+            LICENSE REQUIREMENTS ABOUT-NLS $(man_MANS) \
+            idiottest.mak
 
 dist-hook:
        cp gstreamer.spec $(distdir)
@@ -42,20 +43,7 @@ dist-hook:
 rpm: dist
        rpm -ta $(distdir).tar.gz
 
-# Idiot test to stop the installing of versions with plugin srcdir enabled
-install-exec-hook:
-if PLUGINS_USE_SRCDIR
-       @echo "*** ERROR: Cannot install:" 2>&1
-       @echo "GStreamer was configured using the --enable-plugin-srcdir option." 2>&1
-       @echo
-       @echo "This option is for development purposes only: binaries built with" 2>&1
-       @echo "it should be used with code in the build tree only.  To build an"
-       @echo "installable version, use ./configure without the --enable-plugin-srcdir"
-       @echo "option.  Note that the autogen.sh script supplies the plugin srcdir"
-       @echo "option automatically - it cannot be used to configure installable builds"
-       @echo
-       @/bin/false
-endif
+include $(top_srcdir)/idiottest.mak
 
 # Rules to generate autoconf scripts if configure.base is updated
 $(top_srcdir)/configure.in: $(top_srcdir)/configure.base
diff --git a/idiottest.mak b/idiottest.mak
new file mode 100644 (file)
index 0000000..444a5f3
--- /dev/null
@@ -0,0 +1,15 @@
+# Idiot test to stop the installing of versions with plugin srcdir enabled
+install-exec-local:
+if PLUGINS_USE_SRCDIR
+       @echo "*** ERROR: Cannot install:" 2>&1
+       @echo "GStreamer was configured using the --enable-plugin-srcdir option." 2>&1
+       @echo
+       @echo "This option is for development purposes only: binaries built with" 2>&1
+       @echo "it should be used with code in the build tree only.  To build an"
+       @echo "installable version, use ./configure without the --enable-plugin-srcdir"
+       @echo "option.  Note that the autogen.sh script supplies the plugin srcdir"
+       @echo "option automatically - it cannot be used to configure installable builds"
+       @echo
+       @/bin/false
+endif
+
index 406b0b3..3aac1d1 100644 (file)
@@ -4,3 +4,7 @@ noinst_HEADERS = \
        mmx.h \
        sse.h \
        gstaudio.h
+
+# This test needs to go here because this is the first makefile which the
+# install target gets run in.
+include $(top_srcdir)/idiottest.mak