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 # not eh, normally used
14 DEPTH = $(depth)/$(package-depth)
16 topdir := $(shell cd $(depth); pwd)
21 outdir=out-$(CONFIGSUFFIX)
28 distdir = $(depth)/$(outdir)/$(DIST_NAME)
29 DIST_NAME = $(package)-$(TOPLEVEL_VERSION)
31 distname = $(package)-$(TOPLEVEL_VERSION)
38 makeout = $(depth)/make/$(outdir)
39 docout = $(depth)/Documentation/$(outdir)
40 binout = $(depth)/bin/$(outdir)
42 doc-dir = $(depth)/Documentation
43 make-dir = $(depth)/make
47 INSTALL = $(stepdir)/../bin/install-sh -c
51 include $(make-dir)/Variables.make
52 include $(make-dir)/User.make
56 # sort-out which of these are still needed
58 $(package)_bindir = $(depth)/bin
59 step-bindir = $(depth)/$(stepmake)/bin
60 abs-step-bindir = $(topdir)/$(stepmake)/bin
62 group-dir = $(shell cd $(DEPTH)/..; pwd)
63 release-dir = $(group-dir)/releases
64 patch-dir = $(group-dir)/patches
66 # i have in $HOME/.rpmrc
67 # topdir: /home/fred/usr/src/Redhat
69 rpm-sources = $(release-dir)
70 rpm-build = $(group-dir)/RedHat/BUILD
74 configheader=$(outdir)/config.hh
76 # need to be defined in local Makefiles:
81 ifneq ($(MY_PATCH_LEVEL),$(FOOBAR))
82 VERSION=$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_LEVEL).$(MY_PATCH_LEVEL)
84 VERSION=$(MAJOR_VERSION).$(MINOR_VERSION).$(PATCH_LEVEL)
87 ifneq ($(TOPLEVEL_MY_PATCH_LEVEL),$(FOOBAR))
88 TOPLEVEL_VERSION=$(TOPLEVEL_MAJOR_VERSION).$(TOPLEVEL_MINOR_VERSION).$(TOPLEVEL_PATCH_LEVEL).$(TOPLEVEL_MY_PATCH_LEVEL)
90 TOPLEVEL_VERSION=$(TOPLEVEL_MAJOR_VERSION).$(TOPLEVEL_MINOR_VERSION).$(TOPLEVEL_PATCH_LEVEL)
92 state-vector = $(make-dir)/STATE-VECTOR
97 ERROR_LOG = 2> /dev/null
98 SILENT_LOG = 2>&1 > /dev/null
99 date := $(shell date +%x) #duplicated?
101 # compile and link options:
105 INCLUDES = -Iinclude -I$(outdir) $($(PACKAGE)_INCLUDES)
106 LDFLAGS = $(ILDFLAGS) $(USER_LDFLAGS) $(EXTRA_LDFLAGS) $(MODULE_LDFLAGS) $($(PACKAGE)_LDFLAGS)
108 MODULE_LIBES=$(addsuffix /$(outdir)/library.a, $(MODULE_LIBS))
109 LOADLIBES = $(MODULE_LIBES) $($(PACKAGE)_LIBES) $(EXTRA_LIBES)
111 # LOADLIBES = $(MODULE_LIBES) $($(PACKAGE)_LIBES) $(EXTRA_LIBES) -lstdc++
120 LD_COMMAND = $(LD) $(LDFLAGS) -o $@
125 depfile = $(depdir)/$(subst .o,.dep,$(notdir $@))#
126 DODEP=rm -f $(depfile); DEPENDENCIES_OUTPUT="$(depfile) $(outdir)/$(notdir $@)"
130 # generic target names:
133 EXECUTABLE = $(outdir)/$(NAME)$(EXE)
138 EXECUTABLES = $(notdir $(EXECUTABLE))
143 #replace to do stripping of certain objects
146 DIST_FILES=$(EXTRA_DIST_FILES) Makefile $(ALL_SOURCES)
147 DOCDIR=$(depth)/$(outdir)
150 STRIP=strip --strip-debug
152 STABLEOBS=$(addprefix $(outdir)/,$(stablecc:.cc=.o))
155 # substitute $(STRIP) in Site.make if you want stripping
159 LOOP=$(foreach i, $(SUBDIRS), $(MAKE) -C $(i) $@ &&) true