]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/windows/GNUmakefile
5806e4d9227dedb17c56e058c5ab4b0f4dcbbc1a
[lilypond.git] / Documentation / windows / GNUmakefile
1
2 depth=../..
3
4 EXTRA_DIST_FILES = LilyPond.ico $(wildcard *.sh *.patch)
5
6 STEPMAKE_TEMPLATES=documentation texinfo install install-out
7
8 include $(depth)/make/stepmake.make 
9
10 default: local-doc
11
12 local-WWW:
13
14 # For cygwin builds only
15 target=$(shell gcc -dumpmachine)
16 ifeq ($(target),i686-pc-cygwin)
17
18 POST_INSTALLS=$(wildcard post-*.sh)
19 OUT_POST_INSTALLS=$(POST_INSTALLS:%=$(outdir)/%)
20
21 # lily-*: rename to '-profile' or so
22 PROFILES=$(wildcard *lily-*.sh) lilypond-profile.sh
23 OUT_PROFILES=$(PROFILES:%=$(outdir)/%)
24
25 ##as2text.scm
26 PYTHON_WRAPPERS=\
27  abc2ly\
28  convert-ly\
29  etf2ly\
30  lilypond-book\
31  ly2dvi\
32  mup2ly\
33  musedata2ly\
34  pmx2ly\
35  update-lily\
36 #
37
38 OUT_PYTHON_WRAPPERS=$(PYTHON_WRAPPERS:%=$(outdir)/%)
39
40 TEX_WRAPPERS=dvips latex mktextfm tex yap
41 OUT_TEX_WRAPPERS=$(TEX_WRAPPERS:%=$(outdir)/%)
42
43 # profiles
44 $(outdir)/%.sh: %.sh
45         cat $< | sed $(sed-atvariables) > $@
46         chmod 755 $@
47
48 # Urg
49 $(outdir)/lilypond-profile.sh: $(outdir)/../$(depth)/buildscripts/out/lilypond-profile
50         cp $< $@
51         chmod 755 $@
52
53 # python wrappers
54 $(outdir)/%: python-wrapper.sh
55         cat $< | sed $(sed-atvariables) -e "s!@name@!$(*F)!g" > $@
56         chmod 755 $@
57
58 ATVARIABLES += OPTIONS
59
60 # tex wrappers
61 #$(outdir)/%: %-wrapper.sh
62 #       cat $< | sed $(sed-atvariables) -e "s!@name@!$(*F)!g" > $@
63 #       chmod 755 $@
64
65 $(outdir)/latex: tex-wrapper.sh
66         cat $< | sed $(sed-atvariables) -e "s!@name@!latex!g" > $@
67         chmod 755 $@
68
69 $(outdir)/dvips: tex-wrapper.sh
70         cat $< | sed $(sed-atvariables) -e "s!@name@!dvips!g" > $@
71         chmod 755 $@
72
73 MKTEXFTM_OPTIONS=--dest-dir \"$$(cygpath -w \"\"/usr/lilypond/share/lilypond/tfm\"\")\"
74 $(outdir)/mktextfm: tex-wrapper.sh
75         cat $< | sed -e 's!@OPTIONS@!$(MKTEXFTM_OPTIONS)!' $(sed-atvariables) -e "s!@name@!maketfm!g" > $@
76         chmod 755 $@
77
78 $(outdir)/tex: tex-wrapper.sh
79         cat $< | sed $(sed-atvariables) -e "s!@name@!tex!g" > $@
80         chmod 755 $@
81
82 $(outdir)/yap: tex-wrapper.sh
83         cat $< | sed $(sed-atvariables) -e "s!@name@!yap!g" > $@
84         chmod 755 $@
85
86 default: $(OUT_PYTHON_WRAPPERS) $(OUT_TEX_WRAPPERS) $(OUT_POST_INSTALLS) $(OUT_PROFILES)
87
88 # urg: change suffixes before overwriting python scripts
89
90 INSTALLATION_OUT_SUFFIXES=1 2 3 4
91
92 # URG.
93 # By popular demand,
94 # LilyPond on windows is configured with --prefix=/usr/lilypond-x.y.x
95 # The cygwin profile.d dir, however, is in /etc
96
97 INSTALLATION_DIR=$(shell dirname $(shell dirname $(prefix)))/etc/postinstall
98 INSTALLATION_FILES=$(OUT_POST_INSTALLS)
99
100 INSTALLATION_OUT_DIR1=$(shell dirname $(shell dirname $(prefix)))/etc/profile.d
101 INSTALLATION_OUT_FILES1=$(OUT_PROFILES)
102
103 INSTALLATION_OUT_DIR2=$(prefix)/wrappers
104 INSTALLATION_OUT_FILES2=$(OUT_PYTHON_WRAPPERS) $(OUT_TEX_WRAPPERS)
105
106 INSTALLATION_OUT_DIR3=$(datadir)/tex
107 INSTALLATION_OUT_FILES3=$(shell kpsewhich geometry.sty)
108
109 INSTALLATION_OUT_DIR4=$(datadir)/tfm
110 INSTALLATION_OUT_FILES4=$(shell kpsewhich cmr10.tfm)
111
112 else
113
114 local-install:
115         @echo skipping
116
117 local-install-outfiles:
118         @echo skipping
119
120 endif