aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>2000-02-09 16:23:44 +0000
committerBruce Momjian <bruce@momjian.us>2000-02-09 16:23:44 +0000
commitecd853737690478f85c5304a5ea1f4a3792480b3 (patch)
treed3ae4fc16d9e5d56514a03f3aa05998f79f8fb8f
parent3dec14197bba4013e8688dfeea452388a9846587 (diff)
downloadpostgresql-ecd853737690478f85c5304a5ea1f4a3792480b3.tar.gz
postgresql-ecd853737690478f85c5304a5ea1f4a3792480b3.zip
I checked the WinNT port yesterday (a few days old snapshot from CVS) and I
am including a patch to get it compile. changes to psql: - added less as default pager when compiling on Cygwin - need to declare "filename_completion_function" because it is not exported from readline -> added to include/port/win.h changes to pg_id: - include of <getopt.h> - add .exe when installing I think there is a problem with calling the regress tests on WinNT - it should be called with PORTNAME not HOST as the parameter to regress.sh or the check when to add "-h localhost" to psql has to be changed. Now it is checked against the PORTNAME. The results of the regress tests were OK with expected failures ;-) Daniel Horak
-rw-r--r--src/bin/pg_id/Makefile4
-rw-r--r--src/bin/pg_id/pg_id.c5
-rw-r--r--src/bin/psql/print.c6
-rw-r--r--src/include/port/win.h3
4 files changed, 14 insertions, 4 deletions
diff --git a/src/bin/pg_id/Makefile b/src/bin/pg_id/Makefile
index 1801becbe56..eccdb89cbdc 100644
--- a/src/bin/pg_id/Makefile
+++ b/src/bin/pg_id/Makefile
@@ -5,7 +5,7 @@
#
# Copyright (C) 2000 by PostgreSQL Global Development Team
#
-# $Header: /cvsroot/pgsql/src/bin/pg_id/Attic/Makefile,v 1.14 2000/01/20 21:51:07 petere Exp $
+# $Header: /cvsroot/pgsql/src/bin/pg_id/Attic/Makefile,v 1.15 2000/02/09 16:23:42 momjian Exp $
#
#-------------------------------------------------------------------------
@@ -20,7 +20,7 @@ pg_id: $(OBJS)
$(CC) -o pg_id $(OBJS) $(LDFLAGS)
install: pg_id
- $(INSTALL) $(INSTL_EXE_OPTS) pg_id$(X) $(BINDIR)/pg_id
+ $(INSTALL) $(INSTL_EXE_OPTS) pg_id$(X) $(BINDIR)/pg_id$(X)
depend dep:
$(CC) -MM $(CFLAGS) *.c >depend
diff --git a/src/bin/pg_id/pg_id.c b/src/bin/pg_id/pg_id.c
index fcba3b3e3c5..59c86eeb9ae 100644
--- a/src/bin/pg_id/pg_id.c
+++ b/src/bin/pg_id/pg_id.c
@@ -6,10 +6,13 @@
*
* Copyright (C) 2000 by PostgreSQL Global Development Group
*
- * $Header: /cvsroot/pgsql/src/bin/pg_id/Attic/pg_id.c,v 1.11 2000/01/20 21:51:07 petere Exp $
+ * $Header: /cvsroot/pgsql/src/bin/pg_id/Attic/pg_id.c,v 1.12 2000/02/09 16:23:42 momjian Exp $
*/
#include <c.h>
+#ifdef HAVE_GETOPT_H
+#include <getopt.h>
+#endif
#include <pwd.h>
#include <stdio.h>
#include <stdlib.h>
diff --git a/src/bin/psql/print.c b/src/bin/psql/print.c
index 44faad5850f..8acc18827ac 100644
--- a/src/bin/psql/print.c
+++ b/src/bin/psql/print.c
@@ -3,7 +3,7 @@
*
* Copyright 2000 by PostgreSQL Global Development Group
*
- * $Header: /cvsroot/pgsql/src/bin/psql/print.c,v 1.10 2000/02/07 23:10:06 petere Exp $
+ * $Header: /cvsroot/pgsql/src/bin/psql/print.c,v 1.11 2000/02/09 16:23:43 momjian Exp $
*/
#include <c.h>
#include "print.h"
@@ -24,7 +24,11 @@
#include <libpq-fe.h>
#include <postgres_ext.h> /* for Oid type */
+#ifndef __CYGWIN__
#define DEFAULT_PAGER "more"
+#else
+#define DEFAULT_PAGER "less"
+#endif
diff --git a/src/include/port/win.h b/src/include/port/win.h
index 61acdb3e21e..77081fa36af 100644
--- a/src/include/port/win.h
+++ b/src/include/port/win.h
@@ -14,3 +14,6 @@ typedef unsigned char slock_t;
#if (CYGWIN_VERSION_API_MAJOR >= 0) && (CYGWIN_VERSION_API_MINOR >= 8)
#define sys_nerr _sys_nerr
#endif
+
+/* not exported in readline.h */
+char * filename_completion_function();