1 # title generic variables
2 # file make/Variables.make
4 # do not change this file for site-wide extensions; please use
5 # make/$(outdir)/Site.make;
7 # Any change in files in this directory (make/) would be distributed, if
12 # depth from group-dir
13 # internal, not normally used
14 DEPTH = $(depth)/$(package-depth)
17 topdir := $(shell cd $(depth); pwd)
21 # $(depth) is deprecated, for most cases you'll want $(src-depth)
23 # Well, on second thought.
24 # It can do no harm, but using src-depth iso depth is only necessary
25 # for broken rules that do
26 # cd $(outdir) && foo $(depth) ...
27 src-depth = $(depth)/$(srcdir)
31 distdir = $(topdir)/$(outdir)/$(DIST_NAME)
32 DIST_NAME = $(package)-$(TOPLEVEL_VERSION)
34 distname = $(package)-$(TOPLEVEL_VERSION)
37 #makeout = $(depth)/make/$(outdir)
38 #docout = $(depth)/Documentation/$(outdir)
39 #binout = $(depth)/bin/$(outdir)
41 doc-dir = $(src-depth)/Documentation
42 po-dir = $(src-depth)/po
44 # sort-out which of these are still needed
46 $(package)_bindir = $(depth)/bin
47 step-bindir = $(stepmake)/bin
49 group-dir = $(shell cd $(DEPTH)/..; pwd)
50 release-dir = $(group-dir)/releases
51 patch-dir = $(group-dir)/patches
53 # i have in $HOME/.rpmrc
54 # topdir: /home/fred/usr/src/Redhat
56 rpm-sources = $(release-dir)
57 rpm-build = $(group-dir)/RedHat/BUILD
61 # need to be defined in local Makefiles:
66 ifneq ($(MY_PATCH_LEVEL),$(FOOBAR))
67 VERSION=$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_LEVEL).$(MY_PATCH_LEVEL)
69 VERSION=$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_LEVEL)
72 ifneq ($(TOPLEVEL_MY_PATCH_LEVEL),$(FOOBAR))
73 TOPLEVEL_VERSION=$(TOPLEVEL_MAJOR_VERSION).$(TOPLEVEL_MINOR_VERSION).$(TOPLEVEL_PATCH_LEVEL).$(TOPLEVEL_MY_PATCH_LEVEL)
75 TOPLEVEL_VERSION=$(TOPLEVEL_MAJOR_VERSION).$(TOPLEVEL_MINOR_VERSION).$(TOPLEVEL_PATCH_LEVEL)
82 ERROR_LOG = 2> /dev/null
83 SILENT_LOG = 2>&1 > /dev/null
84 date := $(shell date +%x) #duplicated?
86 # compile and link options:
90 #INCLUDES = $(depth)/$(builddir) include $(outdir) $($(PACKAGE)_INCLUDES) $(MODULE_INCLUDES)
91 INCLUDES = include $(outdir) $($(PACKAGE)_INCLUDES) $(MODULE_INCLUDES)
94 # LOADLIBES = $(MODULE_LIBES) $($(PACKAGE)_LIBES) $(EXTRA_LIBES) -lstdc++
103 LD_COMMAND = $(LD) $(LDFLAGS) -o $@
108 depfile = $(outdir)/$(subst .o,.dep,$(notdir $@))#
109 DODEP=rm -f $(depfile); DEPENDENCIES_OUTPUT="$(depfile) $(outdir)/$(notdir $@)"
113 # generic target names:
116 EXECUTABLE = $(outdir)/$(NAME)
121 EXECUTABLES = $(notdir $(EXECUTABLE))
126 #replace to do stripping of certain objects
129 DIST_FILES=$(EXTRA_DIST_FILES) GNUmakefile $(ALL_SOURCES)
130 DOCDIR=$(depth)/$(outdir)
133 STRIP=strip --strip-debug
135 STABLEOBS=$(addprefix $(outdir)/,$(stablecc:.cc=.o))
138 # substitute $(STRIP) in Site.make if you want stripping
140 LOOP=$(foreach i, $(SUBDIRS), $(MAKE) PACKAGE=$(PACKAGE) package=$(package) -C $(i) $@ &&) true
142 # different redhat releases need different flags for etags. Just use defaults.
146 include $(stepdir)/files.make