]> git.donarmstrong.com Git - lilypond.git/blob - stepmake/stepmake/generic-vars.make
Doc-es: Update of Rhythms.
[lilypond.git] / stepmake / stepmake / generic-vars.make
1 top-build-dir = $(shell cd $(depth) && pwd)
2 build-dir = $(shell cd . && pwd)
3 tree-dir = $(subst $(top-build-dir),,$(build-dir))
4
5 absdir = $(shell cd $(1) ; pwd)
6
7
8 ifneq ($(configure-srcdir),.)
9 srcdir-build = 1
10 endif
11
12 ifndef srcdir-build
13 src-depth = $(depth)
14 else
15 src-depth = $(configure-srcdir)
16 endif
17
18 top-src-dir := $(shell cd $(src-depth); pwd)
19
20 ifndef srcdir-build
21 src-dir = .
22 else
23 src-dir = $(top-src-dir)$(tree-dir)
24 VPATH = $(src-dir)
25 endif
26
27 .UNEXPORT: build-dir src-dir tree-dir
28
29 src-wildcard = $(subst $(src-dir)/,,$(wildcard $(src-dir)/$(1)))
30
31 ifeq ($(distdir),)
32   distdir = $(top-build-dir)/$(outdir)/$(DIST_NAME)
33   DIST_NAME = $(package)-$(TOPLEVEL_VERSION)
34 endif
35 distname = $(package)-$(TOPLEVEL_VERSION)
36
37 doc-dir = $(src-depth)/Documentation
38 po-dir = $(src-depth)/po
39 step-bindir = $(stepmake)/bin
40
41 # stepmake package support.
42 DEPTH = $(depth)/$(package-depth)
43
44 INSTALLPY=$(PYTHON) $(step-bindir)/install.py -c
45 INSTALL=$(INSTALLPY)
46
47 group-dir = $(shell cd $(DEPTH);pwd)/..
48 patch-dir = $(group-dir)/patches
49 rpm-sources = $(release-dir)
50 rpm-build = $(group-dir)/RedHat/BUILD
51 package-icon = $(outdir)/$(package)-icon.xpm
52
53 ifneq ($(strip $(MY_PATCH_LEVEL)),)
54 VERSION=$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_LEVEL).$(MY_PATCH_LEVEL)
55 else
56 VERSION=$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_LEVEL)
57 endif
58
59 ifneq ($(strip $(TOPLEVEL_MY_PATCH_LEVEL)),)
60 TOPLEVEL_VERSION=$(TOPLEVEL_MAJOR_VERSION).$(TOPLEVEL_MINOR_VERSION).$(TOPLEVEL_PATCH_LEVEL).$(TOPLEVEL_MY_PATCH_LEVEL)
61 else
62 TOPLEVEL_VERSION=$(TOPLEVEL_MAJOR_VERSION).$(TOPLEVEL_MINOR_VERSION).$(TOPLEVEL_PATCH_LEVEL)
63 endif
64
65
66 # no local settings in the build process.
67 LANG=
68 export LANG
69
70 # clean file lists:
71 #
72 ERROR_LOG = 2> /dev/null
73 SILENT_LOG = 2>&1 >  /dev/null
74 date := $(shell date +%x)       #duplicated?
75
76 INCLUDES = $(src-dir)/include $(outdir) $($(PACKAGE)_INCLUDES) $(MODULE_INCLUDES)
77
78 M4 = m4
79
80 DIST_FILES=$(EXTRA_DIST_FILES) GNUmakefile $(ALL_SOURCES) $(call src-wildcard,SConscript)
81 DOCDIR=$(depth)/$(outdir)
82
83 #?
84 STRIPDEBUG=true
85 STRIP=strip --strip-debug
86 DO_STRIP=true
87
88 LOOP=+$(foreach i, $(SUBDIRS), $(MAKE) PACKAGE=$(PACKAGE) package=$(package) -C $(i) $@ &&) true
89
90 ETAGS_FLAGS =
91 CTAGS_FLAGS =
92
93 makeflags=$(patsubst %==, %, $(patsubst ---%,,$(patsubst ----%,,$(MAKEFLAGS:%=--%))))
94
95 IN_FILES := $(call src-wildcard,*.in)
96 SOURCE_FILES += $(IN_FILES)
97
98 # Preprocessed .in documentation _FILES:
99 OUTIN_FILES = $(addprefix $(outdir)/, $(IN_FILES:%.in=%))
100
101 ALL_SOURCES = $(SOURCE_FILES)
102
103 ifeq (cygwin,$(findstring cygwin,$(HOST_ARCH)))
104 CYGWIN_BUILD = yes
105 endif
106
107 ifeq (mingw,$(findstring mingw,$(HOST_ARCH)))
108 MINGW_BUILD = yes
109 endif
110
111 ifeq (darwin,$(findstring darwin,$(HOST_ARCH)))
112 DARWIN_BUILD = yes
113 endif