]> git.donarmstrong.com Git - lilypond.git/blob - lily/GNUmakefile
(all-grob-descriptions): set thickness to
[lilypond.git] / lily / GNUmakefile
1
2 depth = ..
3
4 NAME = lilypond
5 SUBDIRS = include
6
7 MODULE_LIBS=$(depth)/flower
8 MODULE_INCLUDES= $(depth)/flower/include 
9
10 # need this to convert between function pointers and member function pointers.
11 MODULE_CXXFLAGS= -Wno-pmf-conversions
12
13
14 HELP2MAN_EXECS = lilypond
15 STEPMAKE_TEMPLATES=c c++ executable po help2man
16
17 # list parser.hh first: making parser.hh removes parser.cc
18 OUT_DIST_FILES=$(addprefix $(outdir)/,parser.hh parser.cc)
19
20 include $(depth)/make/stepmake.make 
21
22 ifeq ($(HAVE_LIBKPATHSEA_SO),no)
23 MODULE_LDFLAGS += $(KPATHSEA_LIBS)
24 endif
25 ifeq ($(LINK_GXX_STATICALLY),yes)
26 MODULE_LDFLAGS += -L$(outdir) -static-libgcc
27 endif
28
29
30
31 # for profiling, link guile statically:
32 #
33 # CONFIG_LDFLAGS += -static -lltdl -ldl
34 #
35
36 ifeq ($(PLATFORM_WINDOWS),yes)
37 WINDRES_FLAGS += -DLilyPond=0 -DLY=1
38 O_FILES += $(outdir)/lilypond.rc.o
39 $(outdir)/lilypond: $(outdir)/lilypond.rc.o
40
41 $(outdir)/lilypond.rc.o: $(outdir)/lilypond.ico $(outdir)/ly.ico
42 $(top-build-dir)/Documentation/pictures/$(outbase)/lilypond.ico:
43         $(MAKE) -C $(top-build-dir)/Documentation/pictures
44
45 $(outdir)/lilypond.ico: $(top-build-dir)/Documentation/pictures/$(outbase)/lilypond.ico
46         cp $< $@ 
47 $(top-build-dir)/Documentation/pictures/$(outbase)/ly.ico:
48         $(MAKE) -C $(top-build-dir)/Documentation/pictures
49
50 $(outdir)/ly.ico: $(top-build-dir)/Documentation/pictures/$(outbase)/ly.ico
51         cp $< $@ 
52 endif
53
54 ETAGS_FLAGS += --regex='{c++}/^LY_DEFINE *(\([^,]+\)/\1/'
55 ETAGS_FLAGS += --regex='{c++}/^LY_DEFINE *([^"]*"\([^"]+\)"/\1/'
56
57 default:
58
59
60 $(outdir)/libstdc++.a:
61         rm -f $@
62         ln -s `$(CXX) -print-file-name=libstdc++.a` $(outdir)/
63
64 ifeq ($(LINK_GXX_STATICALLY),yes)
65 $(outdir)/lilypond: $(outdir)/libstdc++.a
66 endif
67
68 # force these: Make can't know these have to be generated in advance
69 $(outdir)/lily-parser.o: $(outdir)/parser.hh
70 $(outdir)/lily-lexer.o: $(outdir)/parser.hh $(outdir)/FlexLexer.h
71 $(outdir)/lexer.o: $(outdir)/parser.hh $(outdir)/version.hh
72
73 ifneq ($(FLEXLEXER_FILE),)
74 $(outdir)/FlexLexer.h: $(FLEXLEXER_FILE)
75         cp $< $@
76 endif
77
78
79
80 $(outdir)/general-scheme.o: $(outdir)/version.hh
81 $(outdir)/kpath.o: $(outdir)/version.hh
82 $(outdir)/lily-guile.o: $(outdir)/version.hh
83 $(outdir)/lily-version.o: $(outdir)/version.hh
84
85 local-po: $(outdir)/parser.cc
86
87 # ugh.  For --srcdir builds, these must exist to satisfy their broken
88 # lexer.dep and parser.dep file entries.
89 ifneq ($(configure-srcdir),.)
90 .PRECIOUS: $(outdir)/lexer.cc $(outdir)/parser.cc
91 endif