Recognizes if input is ogg or not.
[xiph.git] / vorbis-tools / debian / rules
blob8e92f4213d1c7729fb1af28bc9bb4e2ff3d1c4e0
1 #!/usr/bin/make -f
2 # Sample debian/rules that uses debhelper.
3 # GNU copyright 1997 to 1999 by Joey Hess.
5 # Modified to make a template file for a multi-binary package with separated
6 # build-arch and build-indep targets by Bill Allombert 2001
8 # Uncomment this to turn on verbose mode.
9 #export DH_VERBOSE=1
11 # This is the debhelper compatibility version to use.
12 export DH_COMPAT=4
14 # This has to be exported to make some magic below work.
15 export DH_OPTIONS
17 # These are used for cross-compiling and for saving the configure script
18 # from having to guess our platform (since we know it already)
19 DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
20 DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
22 objdir = $(CURDIR)/obj-$(DEB_BUILD_GNU_TYPE)
24 CFLAGS = -Wall -g
26 ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
27 CFLAGS += -O0
28 else
29 CFLAGS += -O2
30 endif
31 ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
32 INSTALL_PROGRAM += -s
33 endif
35 configure: configure-stamp
36 configure-stamp:
37 dh_testdir
39 # make build directory
40 mkdir $(objdir)
42 # run configure with build tree $(objdir)
43 # change ../configure to ../autogen.sh for Subversion build
44 cd $(objdir) && \
45 ../configure --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE) \
46 --prefix=/usr
48 touch configure-stamp
50 #Architecture
51 build: build-arch build-indep
53 build-arch: build-arch-stamp
54 build-arch-stamp: configure-stamp
56 cd $(objdir) && \
57 $(MAKE)
59 touch build-arch-stamp
61 build-indep: build-indep-stamp
62 build-indep-stamp: configure-stamp
64 # Add here commands to compile the indep part of the package.
65 #$(MAKE) doc
66 touch build-indep-stamp
68 debian-clean:
69 dh_testdir
70 dh_testroot
72 dh_clean
74 clean:
75 dh_testdir
76 dh_testroot
77 rm -f build-arch-stamp build-indep-stamp configure-stamp
79 # Remove build tree
80 rm -rf $(objdir)
82 # if Makefile exists run distclean
83 if test -f Makefile; then \
84 $(MAKE) distclean; \
87 #if test -d CVS; then \
88 $(MAKE) cvs-clean ;\
91 dh_clean
93 install: install-indep install-arch
94 install-indep:
95 dh_testdir
96 dh_testroot
97 # dh_clean -k -i
98 # dh_installdirs -i
100 # dh_install -i --list-missing
102 install-arch:
103 dh_testdir
104 dh_testroot
105 dh_clean -k -s
106 dh_installdirs -s
108 cd $(objdir) && \
109 $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
111 dh_install -s --list-missing
113 # Must not depend on anything. This is to be called by
114 # binary-arch/binary-indep
115 # in another 'make' thread.
116 binary-common:
117 dh_testdir
118 dh_testroot
119 dh_installchangelogs CHANGES
120 dh_installdocs
121 dh_installexamples
122 # dh_installmenu
123 # dh_installdebconf
124 # dh_installlogrotate
125 # dh_installemacsen
126 # dh_installpam
127 dh_installmime
128 # dh_installinit
129 # dh_installcron
130 # dh_installinfo
131 dh_installman
132 dh_link
133 dh_strip
134 dh_compress
135 dh_fixperms
136 # dh_perl
137 # dh_python
138 dh_makeshlibs -V
139 dh_installdeb
140 dh_shlibdeps
141 dh_gencontrol
142 dh_md5sums
143 dh_builddeb
145 # Build architecture independant packages using the common target.
146 binary-indep: build-indep install-indep
147 # $(MAKE) -f debian/rules DH_OPTIONS=-i binary-common
149 # Build architecture dependant packages using the common target.
150 binary-arch: build-arch install-arch
151 $(MAKE) -f debian/rules DH_OPTIONS=-a binary-common
153 binary: binary-arch binary-indep
154 .PHONY: build clean binary-indep binary-arch binary install install-indep install-arch configure