Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 542d4e5

Browse files
committed
First pass through, of many to come, towards making the whole source
tree "non-PORTNAME" dependent. Technically, anything that is PORTNAME dependent should be able to be derived at compile time, through configure or through gcc
1 parent 9ef6b32 commit 542d4e5

File tree

9 files changed

+57
-31
lines changed

9 files changed

+57
-31
lines changed

src/backend/Makefile

+13-1
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
#
3535
#
3636
# IDENTIFICATION
37-
# $Header: /cvsroot/pgsql/src/backend/Makefile,v 1.27 1997/11/13 03:22:10 momjian Exp $
37+
# $Header: /cvsroot/pgsql/src/backend/Makefile,v 1.28 1997/12/17 04:58:19 scrappy Exp $
3838
#
3939
#-------------------------------------------------------------------------
4040

@@ -60,7 +60,11 @@ postgres: $(OBJS) ../utils/version.o
6060
$(OBJS): $(DIRS:%=%.dir)
6161

6262
$(DIRS:%=%.dir):
63+
ifdef PORTNAME
6364
$(MAKE) -C $(subst .dir,,$@) all PORTNAME=$(PORTNAME)
65+
else
66+
$(MAKE) -C $(subst .dir,,$@) all
67+
endif
6468

6569
../utils/version.o:
6670
$(MAKE) -C ../utils version.o
@@ -96,10 +100,18 @@ clean:
96100
rm -f postgres $(POSTGRES_IMP) fmgr.h parse.h \
97101
global1.bki.source local1_template1.bki.source \
98102
global1.description local1_template1.description
103+
ifdef PORTNAME
99104
for i in $(DIRS); do $(MAKE) -C $$i clean PORTNAME=$(PORTNAME); done
105+
else
106+
for i in $(DIRS); do $(MAKE) -C $$i clean; done
107+
endif
100108

101109
.DEFAULT:
110+
ifdef PORTNAME
102111
for i in $(DIRS); do $(MAKE) -C $$i $@ PORTNAME=$(PORTNAME); done
112+
else
113+
for i in $(DIRS); do $(MAKE) -C $$i $@; done
114+
endif
103115

104116
#############################################################################
105117
#

src/backend/bootstrap/Makefile

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
# Makefile for the bootstrap module
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/bootstrap/Makefile,v 1.10 1997/06/11 01:11:55 scrappy Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/bootstrap/Makefile,v 1.11 1997/12/17 04:58:21 scrappy Exp $
88
#
99
#
1010
# We must build bootparse.c and bootscanner.c with yacc and lex and sed,
@@ -21,9 +21,11 @@
2121
SRCDIR= ../..
2222
include ../../Makefile.global
2323

24-
INCLUDE_OPT= -I.. \
25-
-I../port/$(PORTNAME) \
26-
-I../../include
24+
INCLUDE_OPT= -I..
25+
26+
ifdef PORTNAME
27+
INCLUDE_OPT+=-I../port/$(PORTNAME)
28+
endif
2729

2830
CFLAGS+= $(INCLUDE_OPT)
2931

src/backend/catalog/Makefile

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,18 @@
44
# Makefile for catalog
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/catalog/Makefile,v 1.5 1997/11/15 20:57:02 momjian Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/catalog/Makefile,v 1.6 1997/12/17 04:58:25 scrappy Exp $
88
#
99
#-------------------------------------------------------------------------
1010

1111
SRCDIR = ../..
1212
include ../../Makefile.global
1313

14-
INCLUDE_OPT = -I.. \
15-
-I../port/$(PORTNAME) \
16-
-I../../include
14+
INCLUDE_OPT = -I..
15+
16+
ifdef PORTNAME
17+
INCLUDE_OPT+=-I../port/$(PORTNAME)
18+
endif
1719

1820
CFLAGS+=$(INCLUDE_OPT)
1921

src/backend/executor/Makefile

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,18 @@
44
# Makefile for executor
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/executor/Makefile,v 1.3 1997/08/30 10:28:47 vadim Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/executor/Makefile,v 1.4 1997/12/17 04:58:33 scrappy Exp $
88
#
99
#-------------------------------------------------------------------------
1010

1111
SRCDIR = ../..
1212
include ../../Makefile.global
1313

14-
INCLUDE_OPT = -I.. \
15-
-I../port/$(PORTNAME) \
16-
-I../../include
14+
INCLUDE_OPT = -I..
15+
16+
ifdef PORTNAME
17+
INCLUDE_OPT+=-I../port/$(PORTNAME)
18+
endif
1719

1820
CFLAGS+=$(INCLUDE_OPT)
1921

src/backend/lib/Makefile

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,18 @@
44
# Makefile for lib (miscellaneous stuff)
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/lib/Makefile,v 1.7 1997/01/14 02:35:34 momjian Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/lib/Makefile,v 1.8 1997/12/17 04:58:40 scrappy Exp $
88
#
99
#-------------------------------------------------------------------------
1010

1111
SRCDIR = ../..
1212
include ../../Makefile.global
1313

14-
INCLUDE_OPT = -I.. \
15-
-I../port/$(PORTNAME) \
16-
-I../../include
14+
INCLUDE_OPT = -I..
15+
16+
ifdef PORTNAME
17+
INCLUDE_OPT+=-I../port/$(PORTNAME)
18+
endif
1719

1820
CFLAGS+=$(INCLUDE_OPT)
1921

src/backend/libpq/Makefile

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,18 @@
44
# Makefile for libpq subsystem (backend half of libpq interface)
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/libpq/Makefile,v 1.8 1997/12/04 00:26:47 scrappy Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/libpq/Makefile,v 1.9 1997/12/17 04:58:58 scrappy Exp $
88
#
99
#-------------------------------------------------------------------------
1010

1111
SRCDIR = ../..
1212
include ../../Makefile.global
1313

14-
INCLUDE_OPT = -I.. \
15-
-I../port/$(PORTNAME) \
16-
-I../../include
14+
INCLUDE_OPT = -I..
15+
16+
ifdef PORTNAME
17+
INCLUDE_OPT+=-I../port/$(PORTNAME)
18+
endif
1719

1820
CFLAGS+=$(INCLUDE_OPT)
1921

src/backend/main/Makefile

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,18 @@
44
# Makefile for main
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/main/Makefile,v 1.2 1996/11/09 06:18:04 momjian Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/main/Makefile,v 1.3 1997/12/17 04:59:05 scrappy Exp $
88
#
99
#-------------------------------------------------------------------------
1010

1111
SRCDIR = ../..
1212
include ../../Makefile.global
1313

14-
INCLUDE_OPT = -I.. \
15-
-I../port/$(PORTNAME) \
16-
-I../../include
14+
INCLUDE_OPT = -I..
15+
16+
ifdef PORTNAME
17+
INCLUDE_OPT+=-I../port/$(PORTNAME)
18+
endif
1719

1820
CFLAGS+=$(INCLUDE_OPT)
1921

src/backend/main/main.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
*
88
*
99
* IDENTIFICATION
10-
* $Header: /cvsroot/pgsql/src/backend/main/main.c,v 1.9 1997/09/08 02:23:24 momjian Exp $
10+
* $Header: /cvsroot/pgsql/src/backend/main/main.c,v 1.10 1997/12/17 04:59:10 scrappy Exp $
1111
*
1212
*-------------------------------------------------------------------------
1313
*/
@@ -22,7 +22,7 @@
2222
#include "miscadmin.h"
2323
#include "bootstrap/bootstrap.h"/* for BootstrapMain() */
2424
#include "tcop/tcopprot.h" /* for PostgresMain() */
25-
#include "port-protos.h" /* for init_address_fixup() */
25+
/* #include "port-protos.h" */ /* for init_address_fixup() */
2626

2727
#define NOROOTEXEC "\
2828
\n\"root\" execution of the PostgreSQL backend is not permitted\n\n\

src/backend/nodes/Makefile

+6-4
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,18 @@
44
# Makefile for nodes
55
#
66
# IDENTIFICATION
7-
# $Header: /cvsroot/pgsql/src/backend/nodes/Makefile,v 1.3 1996/11/06 08:54:16 scrappy Exp $
7+
# $Header: /cvsroot/pgsql/src/backend/nodes/Makefile,v 1.4 1997/12/17 04:59:16 scrappy Exp $
88
#
99
#-------------------------------------------------------------------------
1010

1111
SRCDIR = ../..
1212
include ../../Makefile.global
1313

14-
INCLUDE_OPT = -I.. \
15-
-I../port/$(PORTNAME) \
16-
-I../../include
14+
INCLUDE_OPT = -I..
15+
16+
ifdef PORTNAME
17+
INCLUDE_OPT+=-I../port/$(PORTNAME)
18+
endif
1719

1820
CFLAGS+=$(INCLUDE_OPT)
1921

0 commit comments

Comments
 (0)