2 # This file is part of DisOrder.
3 # Copyright (C) 2004, 2005, 2006, 2007 Richard Kettlewell
5 # This program is free software; you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation; either version 2 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful, but
11 # WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 # General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program; if not, write to the Free Software
17 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
21 CONFIGURE=--prefix=/usr --sysconfdir=/etc --localstatedir=/var/lib --mandir=/usr/share/man
27 archpkg([disorder], [ m4_dnl
28 $(MAKE) DESTDIR=`pwd`/debian/disorder installdirs install -C doc
29 $(MAKE) DESTDIR=`pwd`/debian/disorder installdirs install -C clients
30 $(MAKE) DESTDIR=`pwd`/debian/disorder installdirs install -C lib
31 $(MAKE) DESTDIR=`pwd`/debian/disorder installdirs install -C scripts
32 rm -rf debian/disorder/usr/share/man/man8
33 rm -rf debian/disorder/usr/share/disorder/*.html
34 rm -f debian/disorder/usr/bin/disorder-playrtp
35 rm -f debian/disorder/usr/bin/disobedience
36 rm -f debian/disorder/usr/share/man/man1/disorder-playrtp.1
37 rm -f debian/disorder/usr/share/man/man1/disobedience.1
38 $(MKDIR) debian/disorder/etc/disorder
39 dpkg-shlibdeps -Tdebian/substvars.disorder \
40 debian/disorder/usr/bin/*
41 $(INSTALL_DATA) CHANGES README debian/README.Debian \
43 debian/disorder/usr/share/doc/disorder/.
44 bzr log > debian/disorder/usr/share/doc/disorder/changelog
45 gzip -9f debian/disorder/usr/share/doc/disorder/changelog \
46 debian/disorder/usr/share/doc/disorder/CHANGES \
47 debian/disorder/usr/share/doc/disorder/README \
48 debian/disorder/usr/share/doc/disorder/README.* \
49 debian/disorder/usr/share/doc/disorder/BUGS \
50 debian/disorder/usr/share/man/man*/*
53 archpkg([disorder-server], [ m4_dnl
54 $(MAKE) DESTDIR=`pwd`/debian/disorder-server staticdir=/var/www/disorder installdirs install -C images
55 $(MAKE) DESTDIR=`pwd`/debian/disorder-server staticdir=/var/www/disorder installdirs install -C server
56 $(MAKE) DESTDIR=`pwd`/debian/disorder-server staticdir=/var/www/disorder installdirs install -C templates
57 $(MAKE) DESTDIR=`pwd`/debian/disorder-server staticdir=/var/www/disorder installdirs install -C driver
58 $(MAKE) DESTDIR=`pwd`/debian/disorder-server staticdir=/var/www/disorder installdirs install -C plugins
59 $(MAKE) DESTDIR=`pwd`/debian/disorder-server staticdir=/var/www/disorder installdirs install -C sounds
60 $(MAKE) DESTDIR=`pwd`/debian/disorder-server staticdir=/var/www/disorder installdirs install -C doc
61 rm -rf debian/disorder-server/usr/share/man/man1
62 rm -rf debian/disorder-server/usr/share/man/man3
63 rm -rf debian/disorder-server/usr/share/man/man5
64 $(MKDIR) debian/disorder-server/etc/disorder
65 $(MKDIR) debian/disorder-server/etc/init.d
66 $(MKDIR) debian/disorder-server/usr/lib/cgi-bin/disorder
67 $(MKDIR) debian/disorder-server/var/lib/disorder
68 $(INSTALL_SCRIPT) examples/disorder.init \
69 debian/disorder-server/etc/init.d/disorder
70 $(INSTALL_DATA) debian/etc.disorder.config \
71 debian/disorder-server/etc/disorder/config
72 $(INSTALL_DATA) debian/etc.disorder.options \
73 debian/disorder-server/etc/disorder/options
74 $(LIBTOOL) --mode=install $(INSTALL_PROGRAM) server/disorder.cgi \
75 $(shell pwd)/debian/disorder-server/usr/lib/cgi-bin/disorder/disorder
76 dpkg-shlibdeps -Tdebian/substvars.disorder-server \
77 debian/disorder-server/usr/lib/cgi-bin/disorder/* \
78 debian/disorder-server/usr/sbin/* \
79 debian/disorder-server/usr/lib/disorder/*.so*
80 $(INSTALL_DATA) debian/htaccess \
81 debian/disorder-server/usr/lib/cgi-bin/disorder/.htaccess
82 rm -rf debian/disorder-server/usr/share/doc/disorder-server
83 ln -s disorder debian/disorder-server/usr/share/doc/disorder-server
86 archpkg([disorder-playrtp], [ m4_dnl
87 $(MKDIR) debian/disorder-playrtp/usr/bin
88 $(MKDIR) debian/disorder-playrtp/usr/share/man/man1
89 $(INSTALL_PROGRAM) clients/disorder-playrtp \
90 debian/disorder-playrtp/usr/bin/disorder-playrtp
91 $(INSTALL_DATA) doc/disorder-playrtp.1 \
92 debian/disorder-playrtp/usr/share/man/man1/disorder-playrtp.1
93 dpkg-shlibdeps -Tdebian/substvars.disorder-playrtp \
94 debian/disorder-playrtp/usr/bin/*
95 $(INSTALL_DATA) debian/README.RTP \
96 debian/disorder-playrtp/usr/share/doc/disorder-playrtp/README
97 $(INSTALL_DATA) CHANGES debian/disorder-playrtp/usr/share/doc/disorder-playrtp/CHANGES
98 gzip -9f debian/disorder-playrtp/usr/share/doc/disorder-playrtp/CHANGES \
99 debian/disorder-playrtp/usr/share/man/man*/*
102 archpkg([disobedience], [ m4_dnl
103 $(MKDIR) debian/disobedience/usr/bin
104 $(MKDIR) debian/disobedience/usr/share/man/man1
105 $(MKDIR) debian/disobedience/usr/share/pixmaps
106 $(MKDIR) debian/disobedience/usr/share/menu
107 $(MAKE) -C disobedience install DESTDIR=`pwd`/debian/disobedience
108 $(INSTALL_DATA) doc/disobedience.1 \
109 debian/disobedience/usr/share/man/man1/disobedience.1
110 $(INSTALL_DATA) images/disobedience16x16.xpm \
111 images/disobedience32x32.xpm \
112 debian/disobedience/usr/share/pixmaps
113 $(INSTALL_DATA) debian/usr.share.menu.disobedience \
114 debian/disobedience/usr/share/menu/disobedience
115 dpkg-shlibdeps -Tdebian/substvars.disobedience \
116 debian/disobedience/usr/bin/*
117 rm -rf debian/disobedience/usr/share/doc/disobedience
118 ln -s disorder debian/disobedience/usr/share/doc/disobedience
121 DEBVERSION:=$(shell dpkg-parsechangelog|awk '/Version:/ {print $$2}')
122 DSC:=disorder_$(DEBVERSION).dsc
123 DEBSRC:=disorder_$(DEBVERSION).tar.gz
124 VERSION:=$(shell $(MAKE) echo-version)
128 rm -rf disorder-$(VERSION)
129 tar xfz disorder-$(VERSION).tar.gz
130 dpkg-source -b disorder-$(VERSION)
131 rm -rf disorder-$(VERSION) disorder-$(VERSION).tar.gz
134 rm -rf disorder-$(DEBVERSION)
135 dpkg-source -x $(DSC)
136 cd disorder-$(DEBVERSION) && dpkg-buildpackage -r$(FAKEROOT)
138 .PHONY: source source-check