Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf3d6d94

Browse files
committed
Change pg_ctl to be in C. This was the final shell script and is
helpful for the Win32 port.Andrew Dunstan, with additions by Bruce.
1 parentc792cbc commitf3d6d94

File tree

3 files changed

+1035
-424
lines changed

3 files changed

+1035
-424
lines changed

‎src/bin/pg_ctl/Makefile

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,33 +2,41 @@
22
#
33
# Makefile for src/bin/pg_ctl
44
#
5-
# Copyright (c) 1999, PostgreSQL Global Development Group
5+
# Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
6+
# Portions Copyright (c) 1994, Regents of the University of California
67
#
7-
# $PostgreSQL: pgsql/src/bin/pg_ctl/Makefile,v 1.13 2003/12/23 21:56:21 tgl Exp $
8+
# $PostgreSQL: pgsql/src/bin/pg_ctl/Makefile,v 1.14 2004/05/27 03:37:55 momjian Exp $
89
#
910
#-------------------------------------------------------------------------
1011

1112
subdir = src/bin/pg_ctl
1213
top_builddir = ../../..
1314
include$(top_builddir)/src/Makefile.global
1415

15-
all: pg_ctl
16+
overrideCPPFLAGS := -DFRONTEND -DDEF_PGPORT=$(DEF_PGPORT) -I$(libpq_srcdir)$(CPPFLAGS)
1617

17-
pg_ctl: pg_ctl.sh$(top_builddir)/src/Makefile.global
18-
sed -e's/@VERSION@/$(VERSION)/g'\
19-
-e's,@bindir@,$(bindir),g'\
20-
-e's,@DEF_PGPORT@,$(DEF_PGPORT),g'\
21-
$<>$@
22-
chmod a+x$@
18+
OBJS=pg_ctl.o exec.o
19+
20+
all: submake-libpq submake-libpgport pg_ctl
21+
22+
pg_ctl:$(OBJS)$(libpq_builddir)/libpq.a
23+
$(CC)$(CFLAGS)$(OBJS)$(libpq)$(LDFLAGS)$(LIBS) -o$@$(X)
24+
25+
exec.c:% :$(top_srcdir)/src/port/%
26+
rm -f$@&&$(LN_S)$<.
2327

2428
install: all installdirs
25-
$(INSTALL_SCRIPT) pg_ctl$(DESTDIR)$(bindir)/pg_ctl
29+
$(INSTALL_PROGRAM) pg_ctl$(X)$(DESTDIR)$(bindir)/pg_ctl$(X)
2630

2731
installdirs:
2832
$(mkinstalldirs)$(DESTDIR)$(bindir)
2933

3034
uninstall:
31-
rm -f$(DESTDIR)$(bindir)/pg_ctl
35+
rm -f$(DESTDIR)$(bindir)/pg_ctl$(X)
3236

3337
cleandistcleanmaintainer-clean:
34-
rm -f pg_ctl
38+
rm -f pg_ctl$(X)$(OBJS) exec.c
39+
40+
41+
# ensure that changes in DEF_PGPORT propagate into object file
42+
pg_ctl.o: pg_ctl.c$(top_builddir)/src/Makefile.global

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp