On Mon, Feb 28, 2000 at 06:26:54PM -0500, Bruce Momjian wrote:
> > >> 2) gcc warns about redefine of CURRENT_TIME. Nothing
> > >> serious (I mean the compile does not fail..), I just thought I mention.
> > >> defined in backend/parse.h & <sys/ipc.h> (cygwin32_ipc-1.03)
> > >
> > > Seems this is getting in our way. We could try undefining it before
> > > defining it, I guess. I don't think it affects the compile.
> > I wonder whether it is possible to avoid including <sys/ipc.h> in the
> > files that need to include parse.h. Which files show the warning,
> > anyway?
> Probably possible. Not sure. Perhaps the user can supply a patch.
> #ifndef CURRENT_TIME
> #include <ipc.h>
> may work.
Well. IMHO (after looking into it) the CURRENT_TIME has no business
of being in ipc.h in the first place. Here follows a patch that moves
it into a private header file of cygwin32_ipc.
As the http://penguin.cz/~horak/cygwin32_ipc-1.03.tar.gz seems to
be the "official" (only) place of cygwin32_ipc, it should be easy to
push a next version or something. Or to include the patch with postgresql.
If this is wrong, I can look what should be done to PostgreSQL about it.
BTW, about doc/README.NT: There is a line:
> 12. Initdb --username=jkr (do not run this command as administrator)
but initdb does not have option --username ...
Also there is a patch attached (for cygwin32_ipc, it seems), but nothing said
what should be done about it.
diff -ur cygwin32_ipc-1.03.orig/include/IpcNtExt.h cygwin32_ipc-1.03/include/IpcNtExt.h
--- cygwin32_ipc-1.03.orig/include/IpcNtExt.h Wed Jun 17 15:08:04 1998
+++ cygwin32_ipc-1.03/include/IpcNtExt.h Tue Feb 29 12:08:50 2000
@@ -51,6 +51,8 @@
+#define CURRENT_TIME time(0)
EXTERN HANDLE GSemSem, GSemShm, GSemMsg ;
EXTERN CYGWIN32_IPCNT_SEMSTR *GStrSem ;
diff -ur cygwin32_ipc-1.03.orig/include/sys/ipc.h cygwin32_ipc-1.03/include/sys/ipc.h
--- cygwin32_ipc-1.03.orig/include/sys/ipc.h Wed May 13 23:26:28 1998
+++ cygwin32_ipc-1.03/include/sys/ipc.h Tue Feb 29 12:08:28 2000
@@ -35,7 +35,6 @@
-#define CURRENT_TIME time(0)
#define IPC_PRIVATE ((key_t) 0)
In response to
pgsql-bugs by date
|Next:||From: michael||Date: 2000-03-01 10:21:19|
|Subject: initdb and version 7|
|Previous:||From: Peter Eisentraut||Date: 2000-02-29 11:22:31|
|Subject: Re: [BUGS] initdb and version 7|