1- #----------------------------------------------------------------------------
2- #
3- # Makefile.global--
4- # global configuration for the Makefiles
5- #
6- # Copyright (c) 1994, Regents of the University of California
7- #
8- #
9- # IDENTIFICATION
10- # $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.91 2000/08/28 11:53:14 petere Exp $
11- #
12- # NOTES
13- # Essentially all Postgres make files include this file and use the
14- # variables it sets.
15- #
16- # To override the default setting, create a Makefile.custom in this
17- # directory and put your defines there. (Makefile.custom is included
18- # near the end of this file). Sometimes, a variable gets set in
19- # Makefile.global after Makefile.custom has been included, so you can't
20- # simply set that variable in Makefile.custom. In those cases, there is
21- # often another variable (like CUSTOM_COPT) that you can set in
22- # Makefile.custom that influences the later setting of the true variable
23- # of interest (like CFLAGS) by Makefile.global.
24- #
25- #
26- # If you change any of these defines you probably have to
27- # make clean; make
28- # since no dependencies are created for these. (of course you can
29- # be crafty and check what files really depend on them and just remake
30- # those).
31- #
32- # Before including this file, you must set the SRCDIR variable to the
33- # path of the top of the Postgres source tree (the directory that
34- # contains this file).
1+ # $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.92 2000/08/31 16:09:22 petere Exp $
2+
3+ #------------------------------------------------------------------------------
4+ # All PostgreSQL makefiles include this file and use the variables it sets,
5+ # which in turn are put here by the configure script. There is no need for
6+ # users to edit this file -- if it turns out to be necessary then that's a
7+ # bug.
358#
36- #-------------------------------------------------------------------------
9+ # A makefile that includes this file needs to set the variable `subdir' to
10+ # the relative path from the top to itself and `top_builddir' to the relative
11+ # path from itself to the top before including this file. (The "top" is the
12+ # parent directory of the directory this file is in.)
13+ #------------------------------------------------------------------------------
3714
3815# PostgreSQL version number
3916VERSION = @VERSION@
4017
41- ifndef top_builddir
42- top_builddir = $(SRCDIR)/..
43- endif
44-
45- ifndef SRCDIR
46- SRCDIR = $(top_builddir)/src
47- endif
48-
4918# This should be changed once we have separate build dirs.
5019top_srcdir = $(top_builddir)
5120
@@ -73,13 +42,14 @@ BSD_SHLIB= true
7342# systems now. May be applicable to other systems to?
7443ELF_SYSTEM= @ELF_SYS@
7544
76- LIBPQDIR= $(SRCDIR)/interfaces/libpq
77- LIBPGEASYDIR= $(SRCDIR)/interfaces/libpgeasy
78- LIBPGTCLDIR= $(SRCDIR)/interfaces/libpgtcl
45+ libpq_srcdir = $(top_srcdir)/src/interfaces/libpq
46+ libpq_builddir = $(top_builddir)/src/interfaces/libpq
47+ libpq = -L$(libpq_builddir) -lpq
48+
49+ libpgeasy_srcdir = $(top_srcdir)/src/interfaces/libpgeasy
50+ libpgeasy_builddir = $(top_builddir/src/interfaces/libpgeasy
51+ libpgeasy = -L$(libpgeasy_builddir) -lpgeasy
7952
80- LIBPQ= -L$(LIBPQDIR) -lpq
81- LIBPGTCL= -L$(LIBPGTCLDIR) -lpgtcl
82- LIBPGEASY= -L$(LIBPGEASYDIR) -lpgeasy
8353
8454# installation directories
8555
@@ -99,16 +69,6 @@ docdir = @docdir@
9969
10070odbcinst_ini_dir = @odbcinst_ini_dir@
10171
102- # old variable names for installation directories
103-
104- POSTGRESDIR= $(prefix)
105- BINDIR= $(bindir)
106- LIBDIR= $(libdir)
107- TEMPLATEDIR= $(libdir)
108- POSTMANDIR= $(mandir)
109- POSTDOCDIR= $(docdir)
110- HEADERDIR= $(includedir)
111-
11272
11373##############################################################################
11474#
@@ -117,10 +77,6 @@ HEADERDIR= $(includedir)
11777# To disable a feature, comment out the entire definition
11878# (that is, prepend '#', don't set it to "0" or "no").
11979
120- # Comment out ENFORCE_ALIGNMENT if you do NOT want unaligned access to
121- # multi-byte types to generate a bus error.
122- ENFORCE_ALIGNMENT= true
123-
12480# Comment out PROFILE to generate a profile version of the binaries
12581#PROFILE= -p -non_shared
12682
@@ -156,7 +112,6 @@ MULTIBYTE=@MULTIBYTE@
156112#
157113# Installation.
158114#
159- # For many ports, INSTALL is overridden below.
160115INSTALL= @INSTALL@
161116
162117INSTALL_PROGRAM = @INSTALL_PROGRAM@
@@ -180,7 +135,7 @@ FLEX = @FLEX@
180135FLEXFLAGS = @FLEXFLAGS@ $(LFLAGS)
181136AROPT= @AROPT@
182137CPPFLAGS = @CPPFLAGS@
183- CFLAGS = -I$(SRCDIR) /include $(CPPFLAGS) @CFLAGS@
138+ CFLAGS = -I$(top_srcdir)/src /include $(CPPFLAGS) @CFLAGS@
184139CFLAGS_SL= @SHARED_LIB@
185140LIBS= @LIBS@
186141LDFLAGS= @LDFLAGS@ $(LIBS)
@@ -210,7 +165,7 @@ CPU= @CPU@
210165HAVE_POSIX_SIGNALS= @HAVE_POSIX_SIGNALS@
211166HPUXMATHLIB= @HPUXMATHLIB@
212167
213- include $(SRCDIR) /Makefile.port
168+ include $(top_builddir)/src /Makefile.port
214169
215170##############################################################################
216171#
@@ -219,9 +174,7 @@ include $(SRCDIR)/Makefile.port
219174# This includes your local customizations if Makefile.custom exists
220175# in the source directory. This file doesn't exist in the original
221176# distribution so that it doesn't get overwritten when you upgrade.
222- ifneq ($(wildcard $(SRCDIR)/Makefile.custom), )
223- include $(SRCDIR)/Makefile.custom
224- endif
177+ -include $(top_srcdir)/src/Makefile.custom
225178
226179# This goes here so that customization in Makefile.custom is effective
227180##############################################################################
0 commit comments