]> git.donarmstrong.com Git - lilypond.git/blob - debian/rules
bc5c534b43fad8afb53299980680a28632d7d127
[lilypond.git] / debian / rules
1 #!/usr/bin/make -f
2 # debian/rules for LilyPond in Debian.
3 #
4 # This is free software; see the GNU General Public Licence
5 # version 2 or later for copying conditions.  There is NO warranty.
6 #
7
8 export MAILADDRESS = lilypond@packages.debian.org
9
10 # fontconfig blows chunks if it can't write to $HOME; and some
11 # buildds set it to a bogus value.
12 export HOME = /tmp
13
14 DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
15 CFLAGS := $(shell dpkg-buildflags --get CFLAGS)
16 CXXFLAGS := $(shell dpkg-buildflags --get CXXFLAGS)
17 ifneq (,$(filter $(DEB_HOST_ARCH), i386 kfreebsd-i386))
18   config_opt = --disable-optimising
19   CFLAGS := $(filter-out -O%, $(CFLAGS))
20   CXXFLAGS := $(filter-out -O%, $(CXXFLAGS))
21 else
22   config_opt = --enable-optimising
23 endif
24
25 %:
26         dh --parallel $@
27
28
29 override_dh_auto_configure: 
30         dh_auto_configure -- --disable-checking --enable-debugging $(config_opt)
31
32 build-indep: 
33         $(MAKE) -j1 doc WEB_TARGETS="offline"
34
35 build-arch:
36         dh_auto_build -a
37
38 ## this rule will update debian/control and the per-language install
39 ## files; all of the files it generates/modifies should be included in
40 ## the Debian package and should not need to be regenerated or
41 ## modified.
42 update-doc-packages:
43         perl debian/update_doc_packages
44
45
46 ## # Build architecture-independent files here.
47 ## binary-indep: DH_OPTIONS=-i
48 ## binary-indep: build-doc install
49 ##      dh_testdir
50 ##      dh_testroot
51 ##      # Install LilyPond web documentation...
52 ##      $(MAKE) install-doc prefix=$(CURDIR)/debian/lilypond-doc/usr/
53 ##      # it installs a random dir-dep file for no reason
54 ##      rm -f $(CURDIR)/debian/lilypond-doc/usr/share/info/*-dir-dep*
55 ## 
56 ##      dh_installinfo
57 ##      dh_installdocs
58 ##      # remove the useless offline-root directory
59 ##      mv $(CURDIR)/debian/lilypond-doc/usr/share/doc/lilypond/html/offline-root/* \
60 ##              $(CURDIR)/debian/lilypond-doc/usr/share/doc/lilypond/html/.;
61 ##      rmdir $(CURDIR)/debian/lilypond-doc/usr/share/doc/lilypond/html/offline-root;
62 ##      find $(CURDIR)/debian/lilypond-doc/usr/share/doc/lilypond/html \
63 ##              -type d -empty -delete
64 ##      dh_installemacsen
65 ## 
66 ##      install -m 644 debian/xiao-haizi-guai-guai.ly debian/sakura-sakura.ly \
67 ##              $(r_data)/$(d)/examples
68 ##      dh_installchangelogs
69 ## 
70 ##      dh_link usr/share/lilypond/$(VERSION)/tex \
71 ##                      usr/share/texmf/tex/lilypond \
72 ##              usr/share/lilypond/$(VERSION)/fonts/source \
73 ##                      usr/share/texmf/fonts/source/public/lilypond \
74 ##              usr/share/lilypond/$(VERSION)/fonts/type1 \
75 ##                      usr/share/texmf/fonts/type1/public/lilypond \
76 ## 
77 ##      dh_pysupport /usr/share/lilypond/${VERSION}/python
78 ## 
79 ##      dh_compress -X$(d)/html/
80 ##      dh_fixperms
81 ##      dh_installdeb
82 ##      dh_gencontrol
83 ##      dh_md5sums
84 ##      dh_builddeb
85 ## 
86 ## binary-arch: DH_OPTIONS=-s
87 ## binary-arch: build install
88 ##      dh_testdir
89 ##      dh_testroot
90 ##      dh_installdocs AUTHORS.txt NEWS.txt README.txt \
91 ##              DEDICATION THANKS 
92 ## 
93 ## 
94 ##      dh_installemacsen
95 ##      dh_installchangelogs Documentation/misc/CHANGES* Documentation/misc/ChangeLog*
96 ## 
97 ##      dh_strip
98 ##      dh_pysupport /usr/share/lilypond/${VERSION}/python
99 ##      dh_compress
100 ##      dh_fixperms
101 ##      dh_installdeb
102 ##      dh_shlibdeps
103 ##      dh_gencontrol
104 ##      dh_md5sums
105 ##      dh_builddeb
106
107 binary: binary-indep binary-arch
108 .PHONY: build clean install binary-indep binary-arch binary