David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 1 | #!/usr/bin/make -f |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 2 | |
David I. Lehn | 494e1cb | 2002-10-03 03:02:08 +0000 | [diff] [blame] | 3 | version=0.4.1 |
David Schleef | b67feeb | 2002-09-20 03:35:46 +0000 | [diff] [blame] | 4 | |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 5 | #export DH_VERBOSE=1 |
David I. Lehn | d611faa | 2001-03-22 16:05:17 +0000 | [diff] [blame] | 6 | export DH_COMPAT=3 |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 7 | export DH_OPTIONS |
| 8 | |
David I. Lehn | 1d43fd3 | 2001-12-12 03:18:08 +0000 | [diff] [blame] | 9 | export DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE) |
| 10 | export DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE) |
| 11 | |
David I. Lehn | 6e51345 | 2002-03-21 08:21:40 +0000 | [diff] [blame] | 12 | ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE)) |
| 13 | confflags += --build $(DEB_HOST_GNU_TYPE) |
| 14 | else |
| 15 | confflags += --build $(DEB_BUILD_GNU_TYPE) --host $(DEB_HOST_GNU_TYPE) |
| 16 | endif |
| 17 | |
David I. Lehn | 494e1cb | 2002-10-03 03:02:08 +0000 | [diff] [blame] | 18 | debian/control: debian/rules debian/control.in |
David Schleef | b67feeb | 2002-09-20 03:35:46 +0000 | [diff] [blame] | 19 | sed 's/@VERSION@/$(version)/g' debian/control.in >debian/control |
David I. Lehn | 494e1cb | 2002-10-03 03:02:08 +0000 | [diff] [blame] | 20 | |
| 21 | debian/libgstreamer$(version).files: debian/control.in debian/libgstreamerVERSION.files |
| 22 | cp -f debian/libgstreamerVERSION.files debian/libgstreamer$(version).files |
| 23 | |
| 24 | maint: debian/control debian/libgstreamer$(version).files |
David Schleef | b67feeb | 2002-09-20 03:35:46 +0000 | [diff] [blame] | 25 | |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 26 | configure: configure-stamp |
| 27 | configure-stamp: |
| 28 | dh_testdir |
David I. Lehn | c0be5ce | 2002-01-12 01:31:57 +0000 | [diff] [blame] | 29 | |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 30 | # Add here commands to configure the package. |
David I. Lehn | c87e1f9 | 2001-02-24 21:07:23 +0000 | [diff] [blame] | 31 | ./configure \ |
David I. Lehn | 6e51345 | 2002-03-21 08:21:40 +0000 | [diff] [blame] | 32 | $(confflags) \ |
David I. Lehn | c87e1f9 | 2001-02-24 21:07:23 +0000 | [diff] [blame] | 33 | --prefix=/usr \ |
| 34 | --mandir=\$${prefix}/share/man \ |
| 35 | --infodir=\$${prefix}/share/info \ |
David I. Lehn | c0be5ce | 2002-01-12 01:31:57 +0000 | [diff] [blame] | 36 | --with-html-dir=\$${prefix}/share/doc/gstreamer-doc \ |
David I. Lehn | f57bdad | 2001-07-20 06:52:18 +0000 | [diff] [blame] | 37 | --sysconfdir=/etc \ |
David I. Lehn | c87e1f9 | 2001-02-24 21:07:23 +0000 | [diff] [blame] | 38 | --with-configdir=/etc/gstreamer \ |
Christian Schaller | 2d9c2e4 | 2002-11-28 13:29:52 +0000 | [diff] [blame] | 39 | --localstatedir=/var \ |
| 40 | --with-cachedir=/var/cache/gstreamer \ |
David I. Lehn | f57bdad | 2001-07-20 06:52:18 +0000 | [diff] [blame] | 41 | --disable-plugin-builddir \ |
David I. Lehn | 422da20 | 2001-06-06 19:23:21 +0000 | [diff] [blame] | 42 | --disable-tests \ |
| 43 | --disable-examples \ |
David I. Lehn | c0be5ce | 2002-01-12 01:31:57 +0000 | [diff] [blame] | 44 | --enable-docs-build \ |
David I. Lehn | 411b41d | 2001-09-01 01:13:41 +0000 | [diff] [blame] | 45 | --enable-DEBUG \ |
| 46 | --enable-debug |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 47 | |
| 48 | touch configure-stamp |
| 49 | |
| 50 | build: configure-stamp build-stamp |
| 51 | build-stamp: |
| 52 | dh_testdir |
| 53 | |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 54 | $(MAKE) |
| 55 | |
| 56 | touch build-stamp |
| 57 | |
| 58 | clean: |
| 59 | dh_testdir |
| 60 | dh_testroot |
| 61 | rm -f build-stamp configure-stamp |
| 62 | |
David I. Lehn | 411b41d | 2001-09-01 01:13:41 +0000 | [diff] [blame] | 63 | # why does distclean not get the docs? who knows? |
| 64 | -(cd docs; $(MAKE) clean) |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 65 | -$(MAKE) distclean |
| 66 | |
| 67 | dh_clean |
| 68 | |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 69 | install: DH_OPTIONS= |
| 70 | install: build |
| 71 | dh_testdir |
| 72 | dh_testroot |
| 73 | dh_clean -k |
| 74 | dh_installdirs |
| 75 | |
| 76 | # Add here commands to install the package into debian/gstreamer. |
David I. Lehn | 57bbd90 | 2002-01-07 22:05:17 +0000 | [diff] [blame] | 77 | $(MAKE) prefix=$(CURDIR)/debian/gstreamer/usr install |
| 78 | |
| 79 | # move around the doc dirs |
David I. Lehn | c0be5ce | 2002-01-12 01:31:57 +0000 | [diff] [blame] | 80 | mkdir -p debian/gstreamer/usr/share/doc/gstreamer-doc |
David I. Lehn | 494e1cb | 2002-10-03 03:02:08 +0000 | [diff] [blame] | 81 | -cp -r docs/fwg/gst-plugin-writers-guide \ |
David I. Lehn | c0be5ce | 2002-01-12 01:31:57 +0000 | [diff] [blame] | 82 | docs/manual/gstreamer-manual \ |
| 83 | debian/gstreamer/usr/share/doc/gstreamer-doc |
David I. Lehn | 1fa7ea2 | 2002-08-09 09:20:58 +0000 | [diff] [blame] | 84 | |
| 85 | # devhelp files not installed by default |
| 86 | mkdir -p debian/gstreamer/usr/share/devhelp/specs |
| 87 | -cp docs/devhelp/*.devhelp debian/gstreamer/usr/share/devhelp/specs |
| 88 | |
David I. Lehn | 2eac368 | 2002-04-15 09:32:43 +0000 | [diff] [blame] | 89 | # -doc lintian overrides |
| 90 | mkdir -p debian/gstreamer-doc/usr/share/lintian/overrides/ |
| 91 | cp -a debian/gstreamer-doc.lintian debian/gstreamer-doc/usr/share/lintian/overrides/gstreamer-doc |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 92 | |
| 93 | dh_movefiles --sourcedir=debian/gstreamer |
| 94 | |
| 95 | # Build architecture-independent files here. |
| 96 | # Pass -i to all debhelper commands in this target to reduce clutter. |
| 97 | binary-indep: DH_OPTIONS=-i |
| 98 | binary-indep: build install |
| 99 | # Need this version of debhelper for DH_OPTIONS to work. |
| 100 | dh_testdir |
| 101 | dh_testroot |
David I. Lehn | 57bbd90 | 2002-01-07 22:05:17 +0000 | [diff] [blame] | 102 | dh_installdocs -A debian/README.Debian |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 103 | dh_installexamples |
| 104 | dh_installmenu |
David I. Lehn | d611faa | 2001-03-22 16:05:17 +0000 | [diff] [blame] | 105 | dh_installman |
David I. Lehn | 57bbd90 | 2002-01-07 22:05:17 +0000 | [diff] [blame] | 106 | dh_installchangelogs |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 107 | dh_strip |
David I. Lehn | 1fa7ea2 | 2002-08-09 09:20:58 +0000 | [diff] [blame] | 108 | dh_link |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 109 | dh_compress |
| 110 | dh_fixperms |
David I. Lehn | f57bdad | 2001-07-20 06:52:18 +0000 | [diff] [blame] | 111 | dh_installdeb |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 112 | dh_gencontrol |
| 113 | dh_md5sums |
| 114 | dh_builddeb |
| 115 | |
| 116 | # Build architecture-dependent files here. |
| 117 | # Pass -a to all debhelper commands in this target to reduce clutter. |
| 118 | binary-arch: DH_OPTIONS=-a |
David I. Lehn | b93c77f | 2002-01-07 23:34:32 +0000 | [diff] [blame] | 119 | binary-arch: build install |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 120 | # Need this version of debhelper for DH_OPTIONS to work. |
| 121 | dh_testdir |
| 122 | dh_testroot |
David I. Lehn | 57bbd90 | 2002-01-07 22:05:17 +0000 | [diff] [blame] | 123 | dh_installdocs -A debian/README.Debian |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 124 | dh_installexamples |
| 125 | dh_installmenu |
David I. Lehn | d611faa | 2001-03-22 16:05:17 +0000 | [diff] [blame] | 126 | dh_installman |
David I. Lehn | 57bbd90 | 2002-01-07 22:05:17 +0000 | [diff] [blame] | 127 | dh_installchangelogs |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 128 | dh_strip |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 129 | dh_compress |
| 130 | dh_fixperms |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 131 | dh_makeshlibs |
David I. Lehn | f57bdad | 2001-07-20 06:52:18 +0000 | [diff] [blame] | 132 | dh_installdeb |
David I. Lehn | 494e1cb | 2002-10-03 03:02:08 +0000 | [diff] [blame] | 133 | dh_shlibdeps -l`pwd`/debian/libgstreamer$(version)/usr/lib:`pwd`/debian/gstreamer-core-libs/usr/lib |
David I. Lehn | d85de35 | 2001-02-21 22:32:57 +0000 | [diff] [blame] | 134 | dh_gencontrol |
| 135 | dh_md5sums |
| 136 | dh_builddeb |
| 137 | |
| 138 | binary: binary-indep binary-arch |
| 139 | .PHONY: build clean binary-indep binary-arch binary install configure |