2 # debian/rules for LilyPond in Debian.
4 # This is free software; see the GNU General Public Licence
5 # version 2 or later for copying conditions. There is NO warranty.
7 # Currently maintained by Anthony Fok <foka@debian.org>
8 # for Debian GNU/Linux.
14 r_data
= debian
/$(package
)-data
15 r_doc
= debian
/$(package
)-doc
18 d
= usr
/share
/doc
/$(package
)
19 info = /usr
/share
/info/$(package
)
22 VERSION
= $(MAJOR_VERSION
).
$(MINOR_VERSION
).
$(PATCH_LEVEL
)
24 # "main_memory = 263000" in /etc/texmf/texmf.cnf isn't large enough
25 # for latex to process standchen.dvi.latex, so adding extra_mem_* ...
26 # export extra_mem_top = 100000
27 # export extra_mem_bot = 100000
28 # But now, building lilypond.dvi requires increased pool_size (2002-02-18)
29 # export pool_size = 500000
30 # But now, it seems that none of the above is needed in 1.4.11 (2002-02-24)
33 export USER_CFLAGS
= -DDEBIAN
34 export DEB_BUILD
= yes
35 export MAILADDRESS
= lilypond@packages.debian.org
37 # Uncomment this to turn on verbose mode.
40 # This has to be exported to make some magic below work.
47 .
/configure
--disable-checking
--enable-debugging \
48 --prefix=/usr
--enable-optimising \
49 --infodir='$${prefix}/share/info' \
50 --mandir='$${prefix}/share/man'
55 build-doc
: build build-doc-stamp
60 $(MAKE
) -C Documentation
63 $(MAKE
) -C Documentation
/user omf
64 # find . -type d -name 'out-www' | xargs rm -rf
71 rm -f build-stamp build-doc-stamp
72 -$(MAKE
) WWW-clean top-WWW-clean
75 # Still not clean enough? Let's use... BRUTE STRENGTH! :-)
76 find .
-type d
-name
'out' -o
-name
'out-www' | xargs
rm -rf
77 rm -f lib
/lilypond
/python examples.html
78 rm -f debian
/emacsen-startup
79 rm -f debian
/lilypond1.7
*.dirs debian
/lilypond.dirs
80 rm -f debian
/postinst debian
/prerm debian
/postrm
81 rm -f debian
/lilypond-data.doc-base debian
/lilypond.doc-base
92 # Add here commands to install the package into debian/tmp.
93 $(MAKE
) install prefix=$(CURDIR
)/debian
/tmp
/usr
95 dh_install
--sourcedir
=debian
/tmp
--list-missing
97 # # Change from an absolute symlink to a relative symlink (Lintian)
98 # if [ -L $(r)/usr/share/lilypond/cmtfm ]; then \
99 # rm -f $(r)/usr/share/lilypond/cmtfm; \
100 # ln -s ../texmf/fonts/tfm/public/cm $(r)/usr/share/lilypond/cmtfm; \
103 # Build architecture-independent files here.
104 binary-indep
: DH_OPTIONS
=-i
105 binary-indep
: build-doc
install
108 # Install LilyPond web documentation...
109 $(MAKE
) prefix=$(PWD
)/$(r_doc
)/usr webdir
=$(PWD
)/$(r_doc
)/$(d
)/html out
=www web-install
110 # Add symlinks to the PostScript docs and LilyPond logo PNGs for HTML...
112 && cp
-s
`find html/Documentation -name '*.ps.gz'` . \
113 && cp
-s html
/Documentation
/pictures
/out-www
/*.png .
114 # Add symlinks to the documentation PNGs for info...
115 cd
$(r_doc
)/$(info) \
116 && cp
-s ..
/..
/doc
/$(package
)/html
/Documentation
/user
/out-www
/*.png .
117 # # Copy the DVI docs too ...
118 # cp -a `find Documentation -name '*.dvi' ! -name 'lily-[0-9]*.dvi'` \
124 find input \
( -name
'*.*ly' -o
-name
'*.abc' -o
-name
'*.tex' -o
-name
'TODO' \
) ! -regex
'.*/out-www/.*' \
125 -exec cp
-a
--parents
'{}' $(r_data
)/$(d
)/examples
';'
128 mv
$(r_data
)/usr
/share
/lilypond
/$(VERSION
)/fonts
/map
/lilypond.map \
129 $(r_data
)/etc
/texmf
/dvips
/lilypond.map
131 dh_link usr
/share
/lilypond
/$(VERSION
)/tex \
132 usr
/share
/texmf
/tex/lilypond \
133 usr
/share
/lilypond
/$(VERSION
)/fonts
/source \
134 usr
/share
/texmf
/fonts
/source
/public
/lilypond \
135 usr
/share
/lilypond
/$(VERSION
)/fonts
/afm \
136 usr
/share
/texmf
/fonts
/afm
/public
/lilypond \
137 usr
/share
/lilypond
/$(VERSION
)/fonts
/tfm \
138 usr
/share
/texmf
/fonts
/tfm
/public
/lilypond \
139 usr
/share
/lilypond
/$(VERSION
)/fonts
/type1 \
140 usr
/share
/texmf
/fonts
/type1
/public
/lilypond \
141 etc
/texmf
/dvips
/lilypond.map \
142 usr
/share
/lilypond
/$(VERSION
)/dvips
/lilypond.map
144 dh_compress
-X
$(d
)/html
/
151 binary-arch
: DH_OPTIONS
=-s
152 binary-arch
: build
install
155 dh_installdocs AUTHORS.txt NEWS.txt README.txt \
158 # dh_installdocs DEDICATION NEWS ROADMAP *.txt \
159 # Documentation/pictures/out/*.png
160 # Documentation/out/*.txt
161 # $(DVI_FILES) $(PS_FILES)
162 # mkdir $(r)/$(d)/bibliography $(r)/$(d)/misc
163 # cp -a Documentation/bibliography/*.bib $(r)/$(d)/bibliography/
164 # cp -a Documentation/misc/[ACN]* $(r)/$(d)/misc/
166 # dh_installexamples input
168 # for i in `find $(r)/$(d)/examples/ -type d -name out`; do \
169 # mv -fv $$i/* $$i/..; rmdir $$i; done
177 dh_installchangelogs ChangeLog
189 binary
: binary-indep binary-arch
190 .PHONY
: build
clean install binary-indep binary-arch binary