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

Commit b1a38a4

Browse files
committed
Install the SQL command man pages into a section appropriate for each
system. Some systems did not understand the 'l' section, and in general it wasn't entirely appropriate. On SCO OpenServer, the man pages won't be installed at all until someone figures out their man system.
1 parent 2c6b599 commit b1a38a4

29 files changed

+117
-73
lines changed

doc/FAQ_SCO

Lines changed: 11 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
============================================================
2-
Frequently Asked Questions (FAQ) for PostgreSQL V7.1
2+
Frequently Asked Questions (FAQ) for PostgreSQL 7.2
33
SCO UnixWare and OpenServer specific
44
to be read in conjunction with the installation instructions
55
============================================================
6-
last updated: $Date: 2001/03/13 20:52:04 $
6+
last updated: $Date: 2001/08/29 19:14:39 $
77

88
current maintainer: Billy G. Allie (Bill.Allie@mug.org)
99
original author: Andrew Merrill (andrew@compclass.com)
@@ -21,7 +21,7 @@ Topics:
2121
*) Readline
2222
*) Using the UDK on OpenServer
2323
*) Compiling PostgreSQL using the UDK
24-
*) Reading the PostgreSQL man pages on UnixWare
24+
*) Reading the PostgreSQL man pages
2525

2626

2727
***************************************************************************
@@ -125,52 +125,15 @@ This compiler bug seems to be fixed at least in
125125

126126

127127
***************************************************************************
128-
*) Reading the PostgreSQL man pages on UnixWare
128+
*) Reading the PostgreSQL man pages
129129

130-
By default, the PostgreSQL man pages are installed into /usr/local/pgsql/man.
131-
By default, UnixWare does not look there for man pages, so you will not be
132-
able to read them.
133-
134-
You need to make the following changes to access the PostgreSQL man pages
135-
from UnixWare.
136-
137-
1) You need to modify the MANPATH variable in /etc/default/man. I use:
130+
By default, the PostgreSQL man pages are installed into
131+
/usr/local/pgsql/man. By default, UnixWare does not look there for
132+
man pages. To be able to read them you need to modify the MANPATH
133+
variable in /etc/default/man. I use:
138134

139135
MANPATH=/usr/lib/scohelp/%L/man:/usr/dt/man:/usr/man:/usr/share/man:scohelp:/usr/local/man:/usr/local/pgsql/man
140136

141-
2) Add a line that says '1sql' to /etc/default/manSection.
142-
143-
3) The man pages for SQL commands are, by default, placed in section 'l'
144-
(normally used for "l"ocal pages). UnixWare does not support the 'l'
145-
section.
146-
147-
The solution I use is to move all these pages from section 'l' to a section
148-
named '1sql'. To following KSH script will perform the move and change the
149-
section names in the man page:
150-
151-
------------------------------8< CUT HERE >8------------------------------
152-
#!/bin/ksh
153-
cd /usr/local/pgsql/man
154-
mv man1 man.1
155-
mkdir man.1sql
156-
157-
cd /usr/local/pgsql/man/manl
158-
for i in *.l
159-
do
160-
sed -e '/^\.TH/s/"l"/"1sql"/' \
161-
-e 's/\\fR(l)/\\fR(1sql)/' $i >../man.1sql/${i%.l}.1sql
162-
done
163-
cd /usr/local/pgsql/man
164-
rm -rf manl
165-
/usr/ucb/catman -M /usr/local/pgsql/man 1
166-
/usr/ucb/catman -M /usr/local/pgsql/man 1sql
167-
------------------------------8< CUT HERE >8------------------------------
168-
169-
After running this script, you can view the man pages using the 'man'
170-
command. They will not be usable from the scohelp system.
171-
172-
I am working on integrating the man pages into the scohelp system. When I
173-
generate a PostgreSQL package for UnixWare 7.x, the man pages will be
174-
integrated into the scohelp system.
175-
176-
I have not tried using the PostgreSQL man pages on OpenServer. Volunteers??
137+
On OpenServer, some extra research needs to be invested to make the
138+
man pages usable, because the man system is a bit different from other
139+
platforms. Currently, PostgreSQL will not install them at all.

doc/Makefile

Lines changed: 55 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,17 @@
44
#
55
# Copyright (c) 1994, Regents of the University of California
66
#
7-
# $Header: /cvsroot/pgsql/doc/Makefile,v 1.20 2000/12/26 20:47:07 petere Exp $
7+
# $Header: /cvsroot/pgsql/doc/Makefile,v 1.21 2001/08/29 19:14:39 petere Exp $
88
#
99
#----------------------------------------------------------------------------
1010

11-
# This directory doesn't build anything, it is only responsible for
12-
# installing the documenation. It is invoked automatically by the
13-
# top-level makefile. The files to be installed are prepared specially
14-
# and are placed in this directory during distribution bundling. In
15-
# CVS-based trees these files don't exist, so we skip the installation
16-
# in that case.
11+
# This makefile is responsible for installing the documentation. The
12+
# files to be installed are prepared specially and are placed in this
13+
# directory during distribution bundling. In CVS-based trees these
14+
# files don't exist, so we skip the installation in that case.
15+
#
16+
# Before we install the man pages, we massage the section numbers to
17+
# follow the local conventions.
1718
#
1819
# To actually build the documenation, look into the src/ and src/sgml
1920
# subdirectories.
@@ -22,36 +23,79 @@ subdir = doc
2223
top_builddir = ..
2324
include $(top_builddir)/src/Makefile.global
2425

26+
.NOTPARALLEL:
2527

2628
ifneq ($(wildcard $(srcdir)/postgres.tar.gz),)
2729
found_html := yes
2830
endif
2931

3032
ifneq ($(wildcard $(srcdir)/man.tar.gz),)
33+
# SCO OpenServer's man system is sufficiently different to not bother.
34+
ifneq ($(PORTNAME), sco)
3135
found_man := yes
3236
endif
37+
endif
38+
39+
40+
ifdef found_man
41+
ifndef sqlmansect
42+
sqlmansect = 7
43+
endif
44+
sqlmansectnum = $(shell expr X'$(sqlmansect)' : X'\([0-9]\)')
45+
46+
all: man1/.timestamp man$(sqlmansectnum)/.timestamp
3347

48+
man1/.timestamp man$(sqlmansect_dummy)/.timestamp: man.tar.gz
49+
gzip -d -c $< | $(TAR) xf -
50+
for file in man1/*.1; do \
51+
mv $$file $$file.bak && \
52+
sed -e 's/\\fR($(sqlmansect_dummy))/\\fR($(sqlmansectnum))/' $$file.bak >$$file && \
53+
rm $$file.bak || exit; \
54+
done
55+
@echo timestamp >man1/.timestamp
56+
@echo timestamp >man$(sqlmansect_dummy)/.timestamp
3457

35-
all:
58+
man$(sqlmansectnum)/.timestamp: man$(sqlmansect_dummy)/.timestamp
59+
$(mkinstalldirs) man$(sqlmansectnum)
60+
for file in man$(sqlmansect_dummy)/*.$(sqlmansect_dummy); do \
61+
sed -e '/^\.TH/s/"$(sqlmansect_dummy)"/"$(sqlmansect)"/' \
62+
-e 's/\\fR($(sqlmansect_dummy))/\\fR($(sqlmansectnum))/' \
63+
$$file >man$(sqlmansectnum)/`basename $$file | sed 's/.$(sqlmansect_dummy)$$/.$(sqlmansect)/'` || exit; \
64+
done
65+
@echo timestamp >$@
66+
endif # found_man
3667

3768

3869
install: all installdirs
3970
ifdef found_html
4071
gzip -d -c postgres.tar.gz | ( cd $(DESTDIR)$(docdir)/html && $(TAR) xf - )
4172
endif
4273
ifdef found_man
43-
gzip -d -c man.tar.gz | ( cd $(DESTDIR)$(mandir) && $(TAR) xf - )
74+
for file in man1/*.1 man$(sqlmansectnum)/*.$(sqlmansect) ; do \
75+
$(INSTALL_DATA) $$file $(DESTDIR)$(mandir)/$$file || exit; \
76+
done
4477
endif
4578

4679

4780
installdirs:
48-
$(mkinstalldirs) $(DESTDIR)$(mandir) $(DESTDIR)$(docdir)/html
81+
ifdef found_html
82+
$(mkinstalldirs) $(DESTDIR)$(docdir)/html
83+
endif
84+
ifdef found_man
85+
$(mkinstalldirs) $(addprefix $(DESTDIR)$(mandir)/man, 1 $(sqlmansectnum))
86+
endif
4987

5088

5189
uninstall:
5290
ifdef found_html
5391
-rm -f $(addprefix $(DESTDIR)$(docdir)/html/, $(shell gunzip -c $(srcdir)/postgres.tar.gz | tar tf -))
5492
endif
5593
ifdef found_man
56-
-rm -f $(addprefix $(DESTDIR)$(mandir)/, $(shell gunzip -c $(srcdir)/man.tar.gz | tar tf -))
94+
-rm -f $(addprefix $(DESTDIR)$(mandir)/, $(shell gunzip -c $(srcdir)/man.tar.gz | tar tf - | sed -e 's,man$(sqlmansect_dummy)/,man$(sqlmansectnum)/,' -e 's/.$(sqlmansect_dummy)$$/.$(sqlmansect)/'))
5795
endif
96+
97+
98+
clean:
99+
rm -rf man1/ man$(sqlmansectnum)/ man$(sqlmansect_dummy)/
100+
101+
distclean maintainer-clean: clean

doc/src/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Postgres documentation makefile
2-
# $Header: /cvsroot/pgsql/doc/src/Makefile,v 1.18 2001/03/27 16:34:14 momjian Exp $
2+
# $Header: /cvsroot/pgsql/doc/src/Makefile,v 1.19 2001/08/29 19:14:39 petere Exp $
33

44
subdir = doc/src
55
top_builddir = ../..
@@ -60,7 +60,7 @@ postgres.tar:
6060

6161
man.tar:
6262
$(MAKE) -C sgml man
63-
$(TAR) -cf $@ -C sgml man1 manl
63+
$(TAR) -cf $@ -C sgml man1 man$(sqlmansect_dummy)
6464

6565
# Generic production rules
6666

doc/src/sgml/Makefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#
99
#
1010
# IDENTIFICATION
11-
# $Header: /cvsroot/pgsql/doc/src/sgml/Makefile,v 1.37 2001/05/12 22:51:34 petere Exp $
11+
# $Header: /cvsroot/pgsql/doc/src/sgml/Makefile,v 1.38 2001/08/29 19:14:39 petere Exp $
1212
#
1313
#----------------------------------------------------------------------------
1414

@@ -60,7 +60,7 @@ CATALOG = $(DOCBOOKSTYLE)/catalog
6060

6161
.PHONY: man
6262

63-
DEFAULTSECTION := l
63+
DEFAULTSECTION := $(sqlmansect_dummy)
6464

6565
man: $(ALLSGML)
6666
$(NSGMLS) $(NSGMLS_FLAGS) $(srcdir)/book-decl.sgml $(srcdir)/reference.sgml \

src/Makefile.global.in

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# -*-makefile-*-
2-
# $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.135 2001/08/28 14:20:26 petere Exp $
2+
# $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.136 2001/08/29 19:14:39 petere Exp $
33

44
#------------------------------------------------------------------------------
55
# All PostgreSQL makefiles include this file and use the variables it sets,
@@ -88,6 +88,7 @@ includedir_server = $(pkgincludedir)/server
8888
includedir_internal = $(pkgincludedir)/internal
8989

9090
mandir := @mandir@
91+
sqlmansect_dummy = l
9192

9293
docdir := @docdir@
9394
ifeq "$(findstring pgsql, $(docdir))" ""

src/backend/storage/lmgr/lock.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*
99
*
1010
* IDENTIFICATION
11-
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.92 2001/08/23 23:06:38 tgl Exp $
11+
* $Header: /cvsroot/pgsql/src/backend/storage/lmgr/lock.c,v 1.93 2001/08/29 19:14:39 petere Exp $
1212
*
1313
* NOTES
1414
* Outside modules can create a lock table and acquire/release
@@ -65,8 +65,6 @@ static char *lock_mode_names[] =
6565
"AccessExclusiveLock"
6666
};
6767

68-
static char *DeadLockMessage = "Deadlock detected.\n\tSee the lock(l) manual page for a possible cause.";
69-
7068

7169
#ifdef LOCK_DEBUG
7270

@@ -953,7 +951,7 @@ WaitOnLock(LOCKMETHOD lockmethod, LOCKMODE lockmode,
953951
*/
954952
LOCK_PRINT("WaitOnLock: aborting on lock", lock, lockmode);
955953
SpinRelease(lockMethodTable->ctl->masterLock);
956-
elog(ERROR, DeadLockMessage);
954+
elog(ERROR, "deadlock detected");
957955
/* not reached */
958956
}
959957

src/interfaces/jdbc/org/postgresql/jdbc1/DatabaseMetaData.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1196,7 +1196,7 @@ public int getMaxColumnsInSelect() throws SQLException
11961196

11971197
/**
11981198
* What is the maximum number of columns in a table? From the
1199-
* create_table(l) manual page...
1199+
* CREATE TABLE reference page...
12001200
*
12011201
* <p>"The new class is created as a heap with no initial data. A
12021202
* class can have no more than 1600 attributes (realistically,

src/interfaces/jdbc/org/postgresql/jdbc2/DatabaseMetaData.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1196,7 +1196,7 @@ public int getMaxColumnsInSelect() throws SQLException
11961196

11971197
/**
11981198
* What is the maximum number of columns in a table? From the
1199-
* create_table(l) manual page...
1199+
* CREATE TABLE reference page...
12001200
*
12011201
* <p>"The new class is created as a heap with no initial data. A
12021202
* class can have no more than 1600 attributes (realistically,

src/makefiles/Makefile.aix

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,5 @@ endif
4343
%$(DLSUFFIX): %.o %$(EXPSUFF)
4444
@echo Making shared library $@ from $*.o, $*$(EXPSUFF) and postgres.imp
4545
$(CC) -Wl,-H512 -Wl,-bM:SRE -Wl,-bI:$(top_builddir)/src/backend/$(POSTGRES_IMP) -Wl,-bE:$*$(EXPSUFF) -o $@ $*.o $(LDFLAGS) $(LIBS) $(LDFLAGS_SL)
46+
47+
sqlmansect = 7

src/makefiles/Makefile.beos

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,3 +11,5 @@ CFLAGS_SL = -fpic -DPIC
1111
%.so: %.o
1212
ln -fs $(top_srcdir)/src/backend/postgres _APP_
1313
$(CC) -nostart -Xlinker -soname=$@ -o $@ _APP_ $<
14+
15+
sqlmansect = 7

src/makefiles/Makefile.bsdi

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,5 @@ endif
2222

2323
%.so: %.o
2424
$(CC) -shared -o $@ $<
25+
26+
sqlmansect = 7

src/makefiles/Makefile.darwin

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,5 @@ CFLAGS_SL = -bundle -undefined suppress
66

77
%.so: %.o
88
$(CC) $(CFLAGS) $(CFLAGS_SL) -o $@ $<
9+
10+
sqlmansect = 7

src/makefiles/Makefile.dgux

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,5 @@ CFLAGS_SL = -fpic
44

55
%.so: %.o
66
$(CC) -shared -o $@ $<
7+
8+
sqlmansect = 5

src/makefiles/Makefile.freebsd

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,3 +21,5 @@ else
2121
@rm -f $@
2222
$(LD) -x -Bshareable -Bforcearchive -o $@ $@.pic
2323
endif
24+
25+
sqlmansect = 7

src/makefiles/Makefile.hpux

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,3 +52,5 @@ endif
5252
# shlib ... should go away, since this is not really enough knowledge)
5353
%.sl: %.o
5454
$(LD) -b -o $@ $<
55+
56+
sqlmansect = 5

src/makefiles/Makefile.irix5

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,5 @@ ifneq ($(GCC), yes)
1616
CFLAGS += -woff 1164,1171,1185,1195,1552
1717
endif
1818
LDFLAGS += -Wl,-woff,15 -Wl,-woff,84
19+
20+
sqlmansect = 5sql

src/makefiles/Makefile.linux

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,5 @@ CFLAGS_SL = -fpic
88

99
%.so: %.o
1010
$(CC) -shared -o $@ $<
11+
12+
sqlmansect = 7

src/makefiles/Makefile.netbsd

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,3 +24,5 @@ else
2424
$(LD) -x -Bshareable -Bforcearchive \
2525
-o $@ $@.pic
2626
endif
27+
28+
sqlmansect = 7

src/makefiles/Makefile.openbsd

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,5 @@ else
2222
$(LD) -x -Bshareable -Bforcearchive \
2323
-o $@ $@.pic
2424
endif
25+
26+
sqlmansect = 7

src/makefiles/Makefile.osf

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,5 @@ rpath = -rpath $(libdir)
55

66
%.so: %.o
77
$(LD) -shared -expect_unresolved '*' -o $@ $<
8+
9+
sqlmansect = 5

src/makefiles/Makefile.qnx4

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,5 @@ CFLAGS_SL =
1515

1616
override CXXFLAGS +=-I/usr/local/include/g++
1717
override CFLAGS +=-I/usr/local/include
18+
19+
sqlmansect = 7

src/makefiles/Makefile.sco

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,4 @@ endif
1616

1717
%.so: %.o
1818
$(LD) -G -Bdynamic -o $@ $<
19+
sqlmansect = 7

src/makefiles/Makefile.solaris

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# $Header: /cvsroot/pgsql/src/makefiles/Makefile.solaris,v 1.6 2000/12/16 18:14:25 petere Exp $
1+
# $Header: /cvsroot/pgsql/src/makefiles/Makefile.solaris,v 1.7 2001/08/29 19:14:40 petere Exp $
22

33
AROPT = crs
44

@@ -24,3 +24,5 @@ endif
2424

2525
%.so: %.o
2626
$(LD) -G -Bdynamic -o $@ $<
27+
28+
sqlmansect = 5sql

src/makefiles/Makefile.sunos4

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,4 @@ endif
1515
%.so: %.o
1616
$(LD) -assert pure-text -Bdynamic -o $@ $<
1717

18+
sqlmansect = 7

src/makefiles/Makefile.svr4

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,3 +10,5 @@ CFLAGS_SL =
1010

1111
%.so: %.o
1212
$(LD) -G -Bdynamic -o $@ $<
13+
14+
sqlmansect = 5

src/makefiles/Makefile.ultrix4

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,3 +8,5 @@ CFLAGS_SL = -G 0
88

99
%.so: %.c
1010
$(CC) -c -G 0 $(CPPFLAGS) $(CFLAGS) -o $@ $<
11+
12+
sqlmansect = 7

0 commit comments

Comments
 (0)