]> git.donarmstrong.com Git - lilypond.git/blob - debian/rules
release: 1.1.31
[lilypond.git] / debian / rules
1 #!/usr/bin/make -f
2 # Made with the aid of debhelper by by Joey Hess,
3 # based on the sample debian/rules file for GNU hello by Ian Jackson.
4 #
5 # This is free software; see the GNU General Public Licence
6 # version 2 or later for copying conditions.  There is NO warranty.
7 #
8 # Currently maintained by Anthony Fok <foka@debian.org>
9 # for Debian GNU/Linux.
10
11 package = lilypond
12 SHELL = /bin/sh
13 r = debian/tmp
14 d = usr/doc/$(package)
15
16 # Uncomment this to turn on verbose mode.
17 #export DH_VERBOSE=1
18
19 build: build-stamp
20 build-stamp:
21         dh_testdir
22
23         # CC=egcc LIBS=-lqthreads
24         CC=egcc ./configure --disable-checking --disable-debugging \
25                 --enable-printing --prefix=/usr --disable-optimise \
26                 --enable-shared
27         $(MAKE) all
28         # $(MAKE) htmldoc
29
30         touch build-stamp
31
32 clean:
33         dh_testdir
34         dh_testroot
35         rm -f build-stamp install-stamp
36         -$(MAKE) distclean
37
38         # Correct the owner of the out/dummy.dep files when built with sudo.
39         if [ -n "$$SUDO_USER" -a -n "$$SUDO_GID" ]; then \
40                 find . -user root | xargs -r chown --dereference $$SUDO_USER.$$SUDO_GID; \
41         else \
42                 find . -user root | xargs -r chown --dereference $$LOGNAME; \
43         fi
44
45         # Remove the following line once the *.make files are fixed
46         rm -f stepmake/bin/*.pyc
47         rm -f stepmake/stepmake/stepmake
48         rm -f stepmake/stepmake/bin
49         rm -f GNUmakefile stepmake/GNUmakefile
50         rm -f config.h
51         rm -f wwwlist
52
53         dh_clean
54
55 install: install-stamp
56 install-stamp: build-stamp
57         dh_testdir
58         dh_testroot
59         dh_clean -k
60         dh_installdirs usr/lib/texmf/doc \
61                 usr/lib/emacs/site-lisp \
62                 usr/doc/$(package)/examples
63         ln -fs ../../../doc/lilypond $(r)/usr/lib/texmf/doc/lilypond
64
65         $(MAKE) prefix=`pwd`/$(r)/usr install
66
67         touch install-stamp
68
69 # Build architecture-independent files here.
70 binary-indep: build install
71 # We have nothing to do by default.
72
73 binary-arch: build install
74         dh_testdir
75         dh_testroot
76         cp -av mudela-mode.el $(r)/usr/lib/emacs/site-lisp
77         dh_installdocs ANNOUNCEMENT ANNOUNCE-0.1 NEWS-* DEDICATION \
78                 BUGS TODO *.txt \
79                 Documentation/pictures/*.xpm \
80                 Documentation/out/*.txt \
81                 Documentation/tex/*.doc \
82                 Documentation/tex/*.bib
83 #       dh_installexamples input
84         cp -aP `find input mutopia \( -name '*.ly' -o -name '*.tex' -o -name 'TODO' \)` \
85                 $(r)/$(d)/examples
86         for i in `find $(r)/$(d)/examples/ -type d -name out`; do \
87                 mv -fv $$i/* $$i/..; rmdir $$i; done
88 #       dh_installmenu
89 #       dh_installemacsen
90 #       dh_installcron
91 #       dh_installmanpages
92 #       dh_undocumented
93         dh_installchangelogs -k NEWS
94 #       dh_strip
95         dh_compress
96         dh_fixperms
97         dh_suidregister
98         dh_installdeb
99         dh_shlibdeps
100         dh_gencontrol
101 #       dh_makeshlibs
102         dh_md5sums
103         dh_builddeb
104
105 source diff:
106         @echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
107
108 binary: binary-indep binary-arch
109 .PHONY: build clean install binary-indep binary-arch binary