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

Commitb680d5b

Browse files
committed
Add installation of pg_ctl
Locate path of postmaster in a portable way (stolen from initdb)Add postmaster.opts.default.sample which should be copied into$PGLIB in the installtion process. Also, it will be installed into$PGDATA while initdb is running.
1 parenta3e2bc7 commitb680d5b

File tree

4 files changed

+44
-7
lines changed

4 files changed

+44
-7
lines changed

‎src/bin/Makefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,15 +7,16 @@
77
#
88
#
99
# IDENTIFICATION
10-
# $Header: /cvsroot/pgsql/src/bin/Makefile,v 1.21 1999/12/08 10:29:36 momjian Exp $
10+
# $Header: /cvsroot/pgsql/src/bin/Makefile,v 1.22 1999/12/22 04:12:54 ishii Exp $
1111
#
1212
#-------------------------------------------------------------------------
1313

1414
SRCDIR= ..
1515
include ../Makefile.global
1616

1717
DIRS = pg_id pg_version psql pg_dump pg_passwd\
18-
scripts initdb initlocation ipcclean
18+
scripts initdb initlocation ipcclean\
19+
pg_ctl
1920

2021
ifdefMULTIBYTE
2122
DIRS += pg_encoding

‎src/bin/pg_ctl/Makefile

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
#
88
#
99
# IDENTIFICATION
10-
# $Header: /cvsroot/pgsql/src/bin/pg_ctl/Makefile,v 1.2 1999/12/08 10:29:51 momjian Exp $
10+
# $Header: /cvsroot/pgsql/src/bin/pg_ctl/Makefile,v 1.3 1999/12/22 04:12:55 ishii Exp $
1111
#
1212
#-------------------------------------------------------------------------
1313

@@ -17,10 +17,11 @@ include ../../Makefile.global
1717
all: pg_ctl
1818

1919
pg_ctl: pg_ctl.sh
20-
sed -e's@__BINDIR__@$(BINDIR)@' pg_ctl.sh> pg_ctl
20+
cat pg_ctl.sh> pg_ctl
2121

2222
install: pg_ctl
2323
$(INSTALL)$(INSTL_EXE_OPTS)$+$(BINDIR)
24+
$(INSTALL)$(INSTLOPTS) postmaster.opts.default.sample$(LIBDIR)
2425

2526
clean:
2627
rm -f pg_ctl

‎src/bin/pg_ctl/pg_ctl.sh

Lines changed: 36 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,46 @@
88
#
99
#
1010
# IDENTIFICATION
11-
# $Header: /cvsroot/pgsql/src/bin/pg_ctl/Attic/pg_ctl.sh,v 1.3 1999/12/06 08:49:00 ishii Exp $
11+
# $Header: /cvsroot/pgsql/src/bin/pg_ctl/Attic/pg_ctl.sh,v 1.4 1999/12/22 04:12:55 ishii Exp $
1212
#
1313
#-------------------------------------------------------------------------
1414
CMDNAME=`basename$0`
1515

16-
# set default path to postmaster
17-
po_path=__BINDIR__/postmaster
16+
#
17+
# Find out where we're located
18+
#
19+
ifecho"$0"| grep'/'> /dev/null2>&1
20+
then
21+
# explicit dir name given
22+
PGPATH=`echo$0| sed's,/[^/]*$,,'`# (dirname command is not portable)
23+
else
24+
# look for it in PATH ('which' command is not portable)
25+
fordirin`echo"$PATH"| sed's/:/ /g'`
26+
do
27+
# empty entry in path means current dir
28+
[-z"$dir" ]&& dir='.'
29+
if [-f"$dir/$CMDNAME" ]
30+
then
31+
PGPATH="$dir"
32+
break
33+
fi
34+
done
35+
fi
36+
37+
# Check if needed programs actually exist in path
38+
forprogin postmaster
39+
do
40+
if [!-x"$PGPATH/$prog" ]
41+
then
42+
echo"The program$prog needed by$CMDNAME could not be found. It was"
43+
echo"expected at:"
44+
echo"$PGPATH/$prog"
45+
echo"If this is not the correct directory, please start$CMDNAME"
46+
echo"with a full search path. Otherwise make sure that the program"
47+
echo"was installed successfully."
48+
exit 1
49+
fi
50+
done
1851

1952
# set default shutdown signal
2053
sig="-TERM"
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
postmaster
2+
-S

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp