1 top-build-dir
= $(shell cd
$(depth
) && pwd
)
2 build-dir
= $(shell cd .
&& pwd
)
3 tree-dir
= $(subst $(top-build-dir
),,$(build-dir
))
5 absdir
= $(shell cd
$(1) ; pwd
)
8 ifneq ($(configure-srcdir
),.
)
15 src-depth
= $(configure-srcdir
)
18 top-src-dir
:= $(shell cd
$(src-depth
); pwd
)
23 src-dir
= $(top-src-dir
)$(tree-dir
)
27 .UNEXPORT
: build-dir src-dir tree-dir
29 src-wildcard
= $(subst $(src-dir
)/,,$(wildcard $(src-dir
)/$(1)))
32 distdir
= $(top-build-dir
)/$(outdir
)/$(DIST_NAME
)
33 DIST_NAME
= $(package
)-$(TOPLEVEL_VERSION
)
35 distname
= $(package
)-$(TOPLEVEL_VERSION
)
37 doc-dir
= $(src-depth
)/Documentation
38 po-dir
= $(src-depth
)/po
39 step-bindir
= $(stepmake
)/bin
41 # stepmake package support.
42 DEPTH
= $(depth
)/$(package-depth
)
44 INSTALLPY
=$(PYTHON
) $(step-bindir
)/install.py
-c
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
53 ifneq ($(strip $(MY_PATCH_LEVEL
)),)
54 VERSION
=$(MAJOR_VERSION
).
$(MINOR_VERSION
).
$(PATCH_LEVEL
).
$(MY_PATCH_LEVEL
)
56 VERSION
=$(MAJOR_VERSION
).
$(MINOR_VERSION
).
$(PATCH_LEVEL
)
59 ifneq ($(strip $(TOPLEVEL_MY_PATCH_LEVEL
)),)
60 TOPLEVEL_VERSION
=$(TOPLEVEL_MAJOR_VERSION
).
$(TOPLEVEL_MINOR_VERSION
).
$(TOPLEVEL_PATCH_LEVEL
).
$(TOPLEVEL_MY_PATCH_LEVEL
)
62 TOPLEVEL_VERSION
=$(TOPLEVEL_MAJOR_VERSION
).
$(TOPLEVEL_MINOR_VERSION
).
$(TOPLEVEL_PATCH_LEVEL
)
66 # no local settings in the build process.
72 ERROR_LOG
= 2> /dev
/null
73 SILENT_LOG
= 2>&1 > /dev
/null
74 date
:= $(shell date
+%x
) #duplicated?
76 INCLUDES
= $(src-dir
)/include $(outdir
) $($(PACKAGE
)_INCLUDES
) $(MODULE_INCLUDES
)
80 DIST_FILES
=$(EXTRA_DIST_FILES
) GNUmakefile
$(ALL_SOURCES
) $(call src-wildcard
,SConscript
)
81 DOCDIR
=$(depth
)/$(outdir
)
85 STRIP
=strip --strip-debug
88 LOOP
=+$(foreach i
, $(SUBDIRS
), $(MAKE
) PACKAGE
=$(PACKAGE
) package
=$(package
) -C
$(i
) $@
&&) true
93 makeflags
=$(patsubst %==, %, $(patsubst ---%,,$(patsubst ----%,,$(MAKEFLAGS
:%=--%))))
95 IN_FILES
:= $(call src-wildcard
,*.in
)
96 SOURCE_FILES
+= $(IN_FILES
)
98 # Preprocessed .in documentation _FILES:
99 OUTIN_FILES
= $(addprefix $(outdir
)/, $(IN_FILES
:%.in
=%))
101 ALL_SOURCES
= $(SOURCE_FILES
)
103 ifeq (cygwin
,$(findstring cygwin
,$(HOST_ARCH
)))
107 ifeq (mingw
,$(findstring mingw
,$(HOST_ARCH
)))
111 ifeq (darwin
,$(findstring darwin
,$(HOST_ARCH
)))