]> asedeno.scripts.mit.edu Git - 1ts-debian.git/blob - debian/rules
2d2fa530b58ee7e5127069d893439134b95ea7e4
[1ts-debian.git] / debian / rules
1 #!/usr/bin/make -f
2 # Sample debian/rules that uses debhelper. 
3 # GNU copyright 1997 by Joey Hess.
4 #
5 # This version is for a hypothetical package that builds an
6 # architecture-dependant package, as well as an architecture-independent
7 # package.
8
9 # Uncomment this to turn on verbose mode. 
10 #export DH_VERBOSE=1
11
12 # This is the debhelper compatability version to use.
13 export DH_COMPAT=2
14
15 # This has to be exported to make some magic below work.
16 export DH_OPTIONS
17 SONAME=3
18 configure: configure-stamp
19 configure-stamp:
20         dh_testdir
21         # Add here commands to configure the package.
22         ./configure --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info --sysconfdir=/etc --datadir=/etc --with-krb4=/usr --with-ares=/usr
23
24         touch configure-stamp
25
26 build: configure-stamp build-stamp
27 build-stamp:
28         dh_testdir
29
30         # Add here commands to compile the package.
31         -rm -f lib/zephyr/*.o
32         $(MAKE) -C lib                  \
33          FPIC=                                  \
34          LIBEXT=a
35         rm -f lib/zephyr/*.o
36         $(MAKE) LIBEXT=so \
37                 FPIC=-fpic SONAME=$(SONAME)
38
39         touch build-stamp
40
41 clean:
42         dh_testdir
43         dh_testroot
44         rm -f build-stamp configure-stamp
45
46         # Add here commands to clean up after the build process.
47         -$(MAKE) clean
48         rm -f config.cache config.log config.status h/config.h \
49         Makefile clients/Makefile clients/xzwrite/Makefile \
50         clients/zaway/Makefile clients/zctl/Makefile \
51         clients/zleave/Makefile clients/zlocate/Makefile \
52         clients/zmailnotify/Makefile clients/znol/Makefile \
53         clients/zpopnotify/Makefile clients/zshutdown_notify/Makefile \
54         clients/zstat/Makefile clients/zwrite/Makefile lib/Makefile \
55         libdyn/Makefile server/Makefile zhm/Makefile zwgc/Makefile \
56         server/version.h
57
58         dh_clean
59
60 install: DH_OPTIONS=
61 install: build
62         dh_testdir
63         dh_testroot
64         dh_clean -k
65         dh_installdirs
66
67         # Add here commands to install the package into debian/tmp.
68         $(MAKE) install DESTDIR=`pwd`/debian/tmp
69         mv debian/tmp/usr/lib/libzephyr.so debian/tmp/usr/lib/libzephyr.so.$(SONAME)
70         ln -s libzephyr.so.$(SONAME) debian/tmp/usr/lib/libzephyr.so
71         mkdir -p debian/tmp/etc/zephyr/acl
72         set -x; for i in debian/acl/*; do install -c -m 544 -o root $$i debian/tmp/etc/zephyr/acl; done; set +x
73         install -c -m 544 debian/zephyr.vars debian/tmp/etc/zephyr
74
75 # Build architecture-independent files here.
76 # Pass -i to all debhelper commands in this target to reduce clutter.
77 binary-indep: build install
78
79 # Build architecture-dependent files here.
80 # Pass -a to all debhelper commands in this target to reduce clutter.
81 binary-arch: build install
82         dh_testdir
83         dh_testroot
84         dh_movefiles 
85         dh_installdebconf 
86         dh_installdocs
87 #       dh_installexamples
88 #       dh_installmenu
89 #       dh_installemacsen
90 #       dh_installpam
91         dh_installinit
92 #       dh_installcron
93 #       dh_installmanpages
94 #       dh_installinfo
95 #       dh_undocumented
96         dh_installchangelogs 
97         dh_strip
98 #       dh_link
99         dh_compress
100         dh_fixperms
101         # You may want to make some executables suid here.
102         dh_suidregister
103         dh_installdeb
104 #       dh_makeshlibs
105 #       dh_perl
106         dh_shlibdeps
107         dh_gencontrol
108         dh_md5sums
109         dh_builddeb
110
111 binary: binary-indep binary-arch
112
113 .PHONY: build clean binary-indep binary-arch binary install configure
114
115