summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Eisentraut2000-01-19 02:59:03 +0000
committerPeter Eisentraut2000-01-19 02:59:03 +0000
commit1a6b29d05f3b55ccab8d386bc6f9ab211e6a87fe (patch)
treeaf313c841d9f86a8f8b46148875abd58cbd1442c
parentf789613f8a2d2d6b63fafff38cae0778ee21c7c4 (diff)
Removed MBFLAGS from makefiles since it's now done in include/config.h.
-rw-r--r--src/backend/access/common/Makefile4
-rw-r--r--src/backend/bootstrap/Makefile3
-rw-r--r--src/backend/commands/Makefile4
-rw-r--r--src/backend/libpq/Makefile4
-rw-r--r--src/backend/parser/Makefile4
-rw-r--r--src/backend/regex/Makefile1
-rw-r--r--src/backend/regex/engine.c2
-rw-r--r--src/backend/regex/regcomp.c2
-rw-r--r--src/backend/regex/regerror.c2
-rw-r--r--src/backend/regex/regexec.c2
-rw-r--r--src/backend/regex/regfree.c2
-rw-r--r--src/backend/rewrite/Makefile3
-rw-r--r--src/backend/storage/lmgr/Makefile3
-rw-r--r--src/backend/storage/smgr/Makefile4
-rw-r--r--src/backend/tcop/Makefile4
-rw-r--r--src/backend/utils/adt/Makefile4
-rw-r--r--src/backend/utils/init/Makefile3
-rw-r--r--src/backend/utils/mb/Makefile3
-rw-r--r--src/backend/utils/misc/Makefile4
-rw-r--r--src/bin/Makefile2
-rw-r--r--src/bin/pg_dump/pg_dump.c29
-rw-r--r--src/bin/psql/Makefile.in4
-rw-r--r--src/bin/scripts/createuser20
-rw-r--r--src/include/miscadmin.h2
-rw-r--r--src/include/regex/regex.h1
-rw-r--r--src/include/regex/regex2.h2
-rw-r--r--src/include/regex/utils.h2
-rw-r--r--src/interfaces/libpq/Makefile.in4
28 files changed, 61 insertions, 63 deletions
diff --git a/src/backend/access/common/Makefile b/src/backend/access/common/Makefile
index 73528dfe2b..96aecc4b56 100644
--- a/src/backend/access/common/Makefile
+++ b/src/backend/access/common/Makefile
@@ -13,10 +13,6 @@ include ../../../Makefile.global
CFLAGS+=-I../..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS = heaptuple.o indextuple.o indexvalid.o printtup.o \
scankey.o tupdesc.o
diff --git a/src/backend/bootstrap/Makefile b/src/backend/bootstrap/Makefile
index 19ad6c0928..e949e7b28e 100644
--- a/src/backend/bootstrap/Makefile
+++ b/src/backend/bootstrap/Makefile
@@ -22,9 +22,6 @@ SRCDIR= ../..
include ../../Makefile.global
CFLAGS += -I..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
ifeq ($(CC), gcc)
CFLAGS+= -Wno-error
diff --git a/src/backend/commands/Makefile b/src/backend/commands/Makefile
index e39a6c59ee..70e18bd9a1 100644
--- a/src/backend/commands/Makefile
+++ b/src/backend/commands/Makefile
@@ -13,10 +13,6 @@ include ../../Makefile.global
CFLAGS += -I..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS = async.o creatinh.o command.o comment.o copy.o indexcmds.o define.o \
remove.o rename.o vacuum.o view.o cluster.o \
explain.o sequence.o trigger.o user.o proclang.o \
diff --git a/src/backend/libpq/Makefile b/src/backend/libpq/Makefile
index 58bd140444..e656242987 100644
--- a/src/backend/libpq/Makefile
+++ b/src/backend/libpq/Makefile
@@ -19,10 +19,6 @@ CFLAGS+= $(KRBFLAGS)
LDFLAGS+= $(KRBLIBS)
endif
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS = be-dumpdata.o be-fsstubs.o be-pqexec.o portal.o portalbuf.o \
auth.o hba.o crypt.o password.o \
pqcomm.o pqformat.o pqpacket.o pqsignal.o util.o
diff --git a/src/backend/parser/Makefile b/src/backend/parser/Makefile
index f98f1ca256..5de8d2dd38 100644
--- a/src/backend/parser/Makefile
+++ b/src/backend/parser/Makefile
@@ -17,10 +17,6 @@ ifeq ($(CC), gcc)
CFLAGS+= -Wno-error
endif
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS= analyze.o gram.o keywords.o parser.o parse_agg.o parse_clause.o \
parse_expr.o parse_func.o parse_node.o parse_oper.o parse_relation.o \
parse_type.o parse_coerce.o parse_target.o scan.o scansup.o
diff --git a/src/backend/regex/Makefile b/src/backend/regex/Makefile
index d24fe4054a..4053c1f2d3 100644
--- a/src/backend/regex/Makefile
+++ b/src/backend/regex/Makefile
@@ -19,7 +19,6 @@ DEBUGOBJ =
OBJS = regcomp.o regerror.o regexec.o regfree.o
ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
DEBUGOBJ += ../utils/mb/SUBSYS.o
endif
diff --git a/src/backend/regex/engine.c b/src/backend/regex/engine.c
index 698d5da729..b4f6844549 100644
--- a/src/backend/regex/engine.c
+++ b/src/backend/regex/engine.c
@@ -37,6 +37,8 @@
* @(#)engine.c 8.5 (Berkeley) 3/20/94
*/
+#include "postgres.h"
+
/*
* The matching engine and friends. This file is #included by regexec.c
* after suitable #defines of a variety of macros used herein, so that
diff --git a/src/backend/regex/regcomp.c b/src/backend/regex/regcomp.c
index b6c01ef004..65cf92fc56 100644
--- a/src/backend/regex/regcomp.c
+++ b/src/backend/regex/regcomp.c
@@ -42,6 +42,8 @@ static char sccsid[] = "@(#)regcomp.c 8.5 (Berkeley) 3/20/94";
#endif /* LIBC_SCCS and not lint */
+#include "postgres.h"
+
#include <sys/types.h>
#include <stdio.h>
#include <string.h>
diff --git a/src/backend/regex/regerror.c b/src/backend/regex/regerror.c
index 93b4733061..d44b6db57c 100644
--- a/src/backend/regex/regerror.c
+++ b/src/backend/regex/regerror.c
@@ -42,6 +42,8 @@ static char sccsid[] = "@(#)regerror.c 8.4 (Berkeley) 3/20/94";
#endif /* LIBC_SCCS and not lint */
+#include "postgres.h"
+
#include <sys/types.h>
#include <stdio.h>
#include <string.h>
diff --git a/src/backend/regex/regexec.c b/src/backend/regex/regexec.c
index ec71296cc4..c5a45b3889 100644
--- a/src/backend/regex/regexec.c
+++ b/src/backend/regex/regexec.c
@@ -42,6 +42,8 @@ static char sccsid[] = "@(#)regexec.c 8.3 (Berkeley) 3/20/94";
#endif /* LIBC_SCCS and not lint */
+#include "postgres.h"
+
/*
* the outer shell of regexec()
*
diff --git a/src/backend/regex/regfree.c b/src/backend/regex/regfree.c
index f0a019b0f6..55d5c62810 100644
--- a/src/backend/regex/regfree.c
+++ b/src/backend/regex/regfree.c
@@ -42,6 +42,8 @@ static char sccsid[] = "@(#)regfree.c 8.3 (Berkeley) 3/20/94";
#endif /* LIBC_SCCS and not lint */
+#include "postgres.h"
+
#include <sys/types.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/src/backend/rewrite/Makefile b/src/backend/rewrite/Makefile
index ddf309a554..9002a31b08 100644
--- a/src/backend/rewrite/Makefile
+++ b/src/backend/rewrite/Makefile
@@ -12,9 +12,6 @@ SRCDIR = ../..
include ../../Makefile.global
CFLAGS += -I..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
OBJS = rewriteRemove.o rewriteDefine.o \
rewriteHandler.o rewriteManip.o rewriteSupport.o locks.o
diff --git a/src/backend/storage/lmgr/Makefile b/src/backend/storage/lmgr/Makefile
index bd455c4f29..274d7fc406 100644
--- a/src/backend/storage/lmgr/Makefile
+++ b/src/backend/storage/lmgr/Makefile
@@ -12,9 +12,6 @@ SRCDIR = ../../..
include ../../../Makefile.global
CFLAGS += -I../..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
OBJS = lmgr.o lock.o proc.o
diff --git a/src/backend/storage/smgr/Makefile b/src/backend/storage/smgr/Makefile
index fded026075..12b8ae1f54 100644
--- a/src/backend/storage/smgr/Makefile
+++ b/src/backend/storage/smgr/Makefile
@@ -13,10 +13,6 @@ include ../../../Makefile.global
CFLAGS += -I../..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS = md.o mm.o smgr.o smgrtype.o
all: SUBSYS.o
diff --git a/src/backend/tcop/Makefile b/src/backend/tcop/Makefile
index 2338bc617e..aab34b1e37 100644
--- a/src/backend/tcop/Makefile
+++ b/src/backend/tcop/Makefile
@@ -13,10 +13,6 @@ include ../../Makefile.global
CFLAGS+= -I..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
ifeq ($(CC), gcc)
CFLAGS+= -Wno-error
endif
diff --git a/src/backend/utils/adt/Makefile b/src/backend/utils/adt/Makefile
index a4da442b40..f5522ef98b 100644
--- a/src/backend/utils/adt/Makefile
+++ b/src/backend/utils/adt/Makefile
@@ -23,10 +23,6 @@ CFLAGS+= -mieee
endif
endif
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS = acl.o arrayfuncs.o arrayutils.o bool.o cash.o char.o chunk.o \
date.o datetime.o datum.o dt.o filename.o float.o \
geo_ops.o geo_selfuncs.o int.o int8.o like.o \
diff --git a/src/backend/utils/init/Makefile b/src/backend/utils/init/Makefile
index c8eeae3e64..42ed87bbdf 100644
--- a/src/backend/utils/init/Makefile
+++ b/src/backend/utils/init/Makefile
@@ -12,9 +12,6 @@ SRCDIR = ../../..
include ../../../Makefile.global
CFLAGS += -I../..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
OBJS = enbl.o findbe.o globals.o miscinit.o postinit.o
diff --git a/src/backend/utils/mb/Makefile b/src/backend/utils/mb/Makefile
index fa17abcfab..d58616d1cd 100644
--- a/src/backend/utils/mb/Makefile
+++ b/src/backend/utils/mb/Makefile
@@ -12,9 +12,6 @@ SRCDIR = ../../..
include ../../../Makefile.global
CFLAGS += -I../..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
OBJS = common.o conv.o mbutils.o wchar.o wstrcmp.o wstrncmp.o variable.o \
big5.o
diff --git a/src/backend/utils/misc/Makefile b/src/backend/utils/misc/Makefile
index 7a8ca42232..acf90c1d2b 100644
--- a/src/backend/utils/misc/Makefile
+++ b/src/backend/utils/misc/Makefile
@@ -13,10 +13,6 @@ include ../../../Makefile.global
CFLAGS += -I../..
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS = database.o superuser.o trace.o
all: SUBSYS.o
diff --git a/src/bin/Makefile b/src/bin/Makefile
index 7d8576235a..5ab59888b3 100644
--- a/src/bin/Makefile
+++ b/src/bin/Makefile
@@ -14,7 +14,7 @@
SRCDIR= ..
include ../Makefile.global
-DIRS = pg_id pg_version psql pg_dump pg_passwd \
+DIRS = pg_version psql pg_dump pg_passwd \
scripts initdb initlocation ipcclean \
pg_ctl
diff --git a/src/bin/pg_dump/pg_dump.c b/src/bin/pg_dump/pg_dump.c
index da754b2b26..8de9c9dcd9 100644
--- a/src/bin/pg_dump/pg_dump.c
+++ b/src/bin/pg_dump/pg_dump.c
@@ -608,9 +608,9 @@ main(int argc, char **argv)
*/
#ifdef HAVE_GETOPT_LONG
- while ((c = getopt_long(argc, argv, "acdDh:nNoOp:st:uvxzV?\037", long_options, &optindex)) != -1)
+ while ((c = getopt_long(argc, argv, "acdDf:h:nNoOp:st:uvxzV?\037", long_options, &optindex)) != -1)
#else
- while ((c = getopt(argc, argv, "acdDh:nNoOp:st:uvxzV?")) != -1)
+ while ((c = getopt(argc, argv, "acdDf:h:nNoOp:st:uvxzV?-")) != -1)
#endif
{
switch (c)
@@ -630,6 +630,10 @@ main(int argc, char **argv)
dumpData = true;
attrNames = true;
break;
+ case 'f':
+ fprintf(stderr, "%s: The -f option is obsolete. You can achieve the same by writing %s > %s.\n",
+ progname, progname, optarg);
+ exit(1);
case '\037': /* output file name, see note above */
filename = optarg;
break;
@@ -695,9 +699,26 @@ main(int argc, char **argv)
exit(0);
break;
case '?':
- help(progname);
- exit(0);
+ /* getopt returns '?' on unknown argument. That's not
+ quite what we want */
+ if (strcmp(argv[optind-1], "-?")==0)
+ {
+ help(progname);
+ exit(1);
+ }
+ else
+ {
+ fputs("Try -? for help.\n", stderr);
+ exit(1);
+ }
break;
+#ifndef HAVE_GETOPT_LONG
+ case '-':
+ fprintf(stderr, "%s was compiled without support for long options.\n"
+ "Use -? for help on invocation options.\n", progname);
+ exit(1);
+ break;
+#endif
default:
fprintf(stderr, "%s: unknown option -%c\nTry -? for help.\n", progname, c);
exit(1);
diff --git a/src/bin/psql/Makefile.in b/src/bin/psql/Makefile.in
index 58384b2aac..b456eb6760 100644
--- a/src/bin/psql/Makefile.in
+++ b/src/bin/psql/Makefile.in
@@ -24,10 +24,6 @@ LDFLAGS+= $(KRBLIBS)
CFLAGS+= $(KRBFLAGS)
endif
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS=command.o common.o help.o input.o stringutils.o mainloop.o \
copy.o startup.o prompt.o variables.o large_obj.o print.o describe.o \
tab-complete.o
diff --git a/src/bin/scripts/createuser b/src/bin/scripts/createuser
index e4b0b9cced..7fa6990acc 100644
--- a/src/bin/scripts/createuser
+++ b/src/bin/scripts/createuser
@@ -147,6 +147,11 @@ if [ "$SysID" ]; then
fi
fi
+# Don't want to leave the user blind if he breaks
+# during password entry.
+
+trap 'stty echo >& /dev/null' 1 2 3 15
+
# Get missing user attributes
if [ -z "$NewUser" ]; then
@@ -157,7 +162,20 @@ fi
if [ "$PwPrompt" ]; then
$ECHO_N "Enter password for user \"$NewUser\": "$ECHO_C
- read Password
+ stty -echo >& /dev/null
+ read FirstPw
+ stty echo >& /dev/null
+ echo
+ $ECHO_N "Enter it again: "$ECHO_C
+ stty -echo >& /dev/null
+ read SecondPw
+ stty echo >& /dev/null
+ echo
+ if [ "$FirstPw" != "$SecondPw" ]; then
+ echo "Passwords didn't match."
+ exit 1
+ fi
+ Password=$FirstPw
fi
if [ -z "$CanCreateDb" ]; then
diff --git a/src/include/miscadmin.h b/src/include/miscadmin.h
index 7439822e20..8795ce080b 100644
--- a/src/include/miscadmin.h
+++ b/src/include/miscadmin.h
@@ -22,6 +22,8 @@
#ifndef MISCADMIN_H
#define MISCADMIN_H
+#include "postgres.h"
+
#include "utils/trace.h"
/*****************************************************************************
diff --git a/src/include/regex/regex.h b/src/include/regex/regex.h
index b0b86f3cb6..677f5ca9a2 100644
--- a/src/include/regex/regex.h
+++ b/src/include/regex/regex.h
@@ -40,6 +40,7 @@
#ifndef _REGEX_H_
#define _REGEX_H_
+#include "postgres.h"
#include <sys/types.h>
#include "mb/pg_wchar.h"
diff --git a/src/include/regex/regex2.h b/src/include/regex/regex2.h
index aab9195dc5..25d7853c42 100644
--- a/src/include/regex/regex2.h
+++ b/src/include/regex/regex2.h
@@ -37,6 +37,8 @@
* @(#)regex2.h 8.4 (Berkeley) 3/20/94
*/
+#include "postgres.h"
+
/*
* First, the stuff that ends up in the outside-world include file
*/
diff --git a/src/include/regex/utils.h b/src/include/regex/utils.h
index bf51a8b8e7..b2e2307e1d 100644
--- a/src/include/regex/utils.h
+++ b/src/include/regex/utils.h
@@ -37,7 +37,7 @@
* @(#)utils.h 8.3 (Berkeley) 3/20/94
*/
-#include "config.h"
+#include "postgres.h"
/* utility definitions */
#define DUPMAX 100000000 /* xxx is this right? */
diff --git a/src/interfaces/libpq/Makefile.in b/src/interfaces/libpq/Makefile.in
index 0b4bd0ca12..0009311625 100644
--- a/src/interfaces/libpq/Makefile.in
+++ b/src/interfaces/libpq/Makefile.in
@@ -23,10 +23,6 @@ ifdef KRBVERS
CFLAGS+= $(KRBFLAGS)
endif
-ifdef MULTIBYTE
-CFLAGS+= $(MBFLAGS)
-endif
-
OBJS= fe-auth.o fe-connect.o fe-exec.o fe-misc.o fe-print.o fe-lobj.o \
pqexpbuffer.o dllist.o pqsignal.o @SNPRINTF@