]> git.donarmstrong.com Git - lilypond.git/blob - GNUmakefile.in
* scripts/lilypond-book.py (option_definitions): typo
[lilypond.git] / GNUmakefile.in
1 # -*-Makefile-*-
2 # title    specific top level makefile for LilyPond  
3
4 # subdir level:
5 #
6 depth = .
7 #
8
9 # descent order into subdirectories
10
11 SUBDIRS = buildscripts python scripts \
12         flower lily \
13         mf ly tex ps scm \
14         po make \
15         cygwin debian $(builddir)/stepmake \
16         Documentation input
17 #
18
19 SCRIPTS = configure aclocal.m4 autogen.sh
20 README_FILES =  ChangeLog  COPYING DEDICATION NEWS README.mandrake ROADMAP THANKS
21 README_TXT_FILES = AUTHORS.txt README.txt INSTALL.txt
22 IN_FILES := $(wildcard *.in)
23 EXTRA_DIST_FILES = $(wildcard *.el) vimrc VERSION $(README_FILES)  $(SCRIPTS) $(IN_FILES)  emacsclient.patch lexer-gcc-3.0.patch server.el.patch darwin.patch .cvsignore  lexer-gcc-3.1.sh  lilypond.words
24 NON_ESSENTIAL_DIST_FILES = $(README_TXT_FILES)
25 INSTALLATION_DIR=$(local_lilypond_datadir)
26 INSTALLATION_FILES=$(configuration) VERSION
27
28 # bootstrap stepmake:
29 #
30 STEPMAKE_TEMPLATES=toplevel po install
31 include $(depth)/make/stepmake.make 
32
33 doc: 
34         $(MAKE) -C Documentation
35
36 pfa-fonts:
37         $(MAKE) MAKE_PFA_FILES=1 -C mf
38         (cd $(builddir)/share/lilypond/fonts && \
39                 tar czvf ../../../$(outbase)/type1.tar.gz type1/*.pfa type1/fonts.* type1/lilypond.* )
40
41 install-html-doc: top-web
42         $(INSTALL) -m 755 -d $(local_package_docdir) 
43         tar -C $(local_package_docdir)/ -xzf $(outdir)/web.tar.gz
44
45 local-install:
46         $(INSTALL) -d $(local_lilypond_datadir)
47
48 final-install:
49         @echo
50         @echo " *** Before running, buildscripts/out/lilypond-{profile,login}"
51         @echo " *** must be run. You're advised to source these scripts from your "
52         @echo " *** login scripts. For more information, see Invoking LilyPond in the manual."
53         @echo 
54
55 web-ext = gz html midi pdf png txt ly
56
57 local-WWW-post: 
58         $(footify) --index=./ `$(FIND) . -maxdepth 1 -name '*.html' -print`
59         $(footify-all-command)
60         cd $(builddir) && rm -f `find . -name \*.html~ -print`
61         cd $(builddir) && find Documentation input \
62                 $(web-ext:%=-path '*/out-www/*.%' -or) -false \
63                 > $(outdir)/weblist
64         echo '<META HTTP-EQUIV="refresh" content="2;URL=Documentation/out-www/">' > $(builddir)/index.html
65         cd $(builddir) && ls *.html >> $(outdir)/weblist
66         cat $(outdir)/weblist | (cd $(builddir); GZIP=-9v tar -czf $(outdir)/web.tar.gz  -T -)
67
68 src-ext = c cc yy ll hh icc py scm tex ps texi itexi tely itely sh
69
70 ALL-TAGS:
71         etags $(shell find . $(src-ext:%=-name '*.%' -or) -false | grep -v '/out')
72
73 web-clean:
74         $(SHELL) $(buildscript-dir)/clean-fonts.sh
75         $(MAKE) out=www clean
76
77
78
79 default: $(config_h) builddir-setup
80
81 builddir-setup: $(builddir)/share/lilypond-force
82
83 PO_FILES = $(wildcard $(srcdir)/po/*.po)
84 HELP_CATALOGS = $(PO_FILES:$(srcdir)/po/%.po=%)
85 CATALOGS = $(HELP_CATALOGS:lilypond=) 
86
87 $(builddir)/share/lilypond-force:
88 # Preparing LilyPond tree for builddir exec
89         cd $(builddir) && rm -rf lib share
90         mkdir -p $(builddir)/lib/lilypond
91         mkdir -p $(builddir)/share/lilypond
92         mkdir -p $(builddir)/share/lilypond/fonts
93         mkdir -p $(builddir)/share/lilypond/tex
94         cd $(builddir)/lib/lilypond && \
95                 ln -s  ../../python/$(outconfbase) python
96         cd $(builddir)/share/lilypond && \
97                 ln -s $(abs-srcdir)/ly ly && \
98                 ln -s ../../mf/$(outconfbase) dvips && \
99                 ln -s ../../mf/$(outconfbase) afm && \
100                 ln -s ../../mf/$(outconfbase) tfm && \
101                 ln -s $(abs-srcdir)/mf && \
102                 ln -s $(abs-srcdir)/ps && \
103                 ln -s ../../python/$(outconfbase) python && \
104                 ln -s $(abs-srcdir)/scm
105         cd $(builddir)/share/lilypond/tex && \
106                 ln -s $(abs-srcdir)/tex source && \
107                 ln -s ../../../mf/$(outconfbase) generate
108         cd $(builddir)/share/lilypond/fonts && \
109                 ln -s $(abs-srcdir)/mf source && \
110                 ln -s ../../../mf/$(outconfbase) afm && \
111                 ln -s ../../../mf/$(outconfbase) tfm && \
112                 ln -s ../../../mf/$(outconfbase) type1
113         $(foreach i,$(CATALOGS), \
114                 mkdir -p $(builddir)/share/locale/$i/LC_MESSAGES && \
115                 cd $(builddir)/share/locale/$i/LC_MESSAGES && \
116                 ln -fs ../../../../po/$(outconfbase)/$i.mo lilypond.mo &&) true
117         touch $@
118
119 local-clean: builddir-setup-clean
120 builddir-setup-clean:
121         cd $(builddir) && rm -rf share
122
123 $(config_h): configure.in aclocal.m4
124 #
125 # this is to prevent people from getting
126 # undefined symbols  when we add them to config.h.in,
127 # and they blindly run "cvs update; make".
128 #
129         @echo
130         @echo ' *** $(config_h) is out of date'
131         @echo ' *** Remove it and rerun autogen:'
132         @echo '         rm $(config_h); ./autogen.sh'
133         @echo
134         @false