Thread: 7.1 beta 3 CHANGES FOR QNX

7.1 beta 3 CHANGES FOR QNX

From
"Maurizio"
Date:
I have compiled 7.1 b3 in QNX but to let postgresql works I changed something.
 
In src/backend/port/qnx4/sem.c
#define SEMMAX      (PROC_NSEMS_PER_SET)             ----------------------OLD
#define SEMMAX      (PROC_NSEMS_PER_SET + 1)       ----------------------NEW
 
in src/include/storage/s_lock.h
#if defined(__i386__)                                                        ----------------------OLD
#if (defined(__i386__) && !defined(__QNX__))                     ----------------------NEW
in src/interfaces/ecpg/preproc/pgc.c
#ifndef ECHO                                                                 ---------------------OLD
#ifndef (ECHO || defined(__QNX__))                                  ----------------------NEW
Attached are the files

 

 

Maurizio Cauci
DREAMTECH di Cauci Maurizio
Via Ronchetti, 2 - 21013 Gallarate (VA)
www.dreamtech-it.com

Attachment

Re: 7.1 beta 3 CHANGES FOR QNX

From
Bruce Momjian
Date:
I have applied the following patch for QNX.  I had to do the ECHO test
in pgc.l because pgc.c is generated from pgc.l.  Can you test this to
see it fixes the problem?


in [ Charset ISO-8859-1 unsupported, converting... ]
> I have compiled 7.1 b3 in QNX but to let postgresql works I changed something.
>
> In src/backend/port/qnx4/sem.c
> #define SEMMAX      (PROC_NSEMS_PER_SET)             ----------------------OLD
> #define SEMMAX      (PROC_NSEMS_PER_SET + 1)       ----------------------NEW
>
> in src/include/storage/s_lock.h
> #if defined(__i386__)                                                        ----------------------OLD
> #if (defined(__i386__) && !defined(__QNX__))                     ----------------------NEW
>
> in src/interfaces/ecpg/preproc/pgc.c
> #ifndef ECHO                                                                 ---------------------OLD
> #ifndef (ECHO || defined(__QNX__))                                  ----------------------NEW
>
> Attached are the files
>
>
>
>
> Maurizio Cauci
> DREAMTECH di Cauci Maurizio
> Via Ronchetti, 2 - 21013 Gallarate (VA)
> www.dreamtech-it.com
>

[ Attachment, skipping... ]

[ Attachment, skipping... ]

[ Attachment, skipping... ]


--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026
? config.log
? config.cache
? config.status
? GNUmakefile
? src/Makefile.custom
? src/GNUmakefile
? src/Makefile.global
? src/log
? src/crtags
? src/backend/port/Makefile
? src/bin/pg_dump/pg_dump
? src/bin/pg_dump/pg_restore
? src/bin/pg_dump/pg_dumpall
? src/include/config.h
? src/include/stamp-h
? src/interfaces/libpq/libpq.so.2.1
Index: src/backend/port/qnx4/sem.c
===================================================================
RCS file: /home/projects/pgsql/cvsroot/pgsql/src/backend/port/qnx4/sem.c,v
retrieving revision 1.3
diff -c -r1.3 sem.c
*** src/backend/port/qnx4/sem.c    2000/04/12 17:15:30    1.3
--- src/backend/port/qnx4/sem.c    2001/02/02 18:13:12
***************
*** 26,32 ****


  #define SETMAX    ((MAXBACKENDS + PROC_NSEMS_PER_SET - 1) / PROC_NSEMS_PER_SET)
! #define SEMMAX    (PROC_NSEMS_PER_SET)
  #define OPMAX    8

  #define MODE    0700
--- 26,32 ----


  #define SETMAX    ((MAXBACKENDS + PROC_NSEMS_PER_SET - 1) / PROC_NSEMS_PER_SET)
! #define SEMMAX    (PROC_NSEMS_PER_SET+1)
  #define OPMAX    8

  #define MODE    0700
Index: src/include/storage/s_lock.h
===================================================================
RCS file: /home/projects/pgsql/cvsroot/pgsql/src/include/storage/s_lock.h,v
retrieving revision 1.86
diff -c -r1.86 s_lock.h
*** src/include/storage/s_lock.h    2001/01/24 19:43:28    1.86
--- src/include/storage/s_lock.h    2001/02/02 18:13:13
***************
*** 112,118 ****
   */


! #if defined(__i386__)
  #define TAS(lock) tas(lock)

  static __inline__ int
--- 112,118 ----
   */


! #if defined(__i386__) && !defined(__QNX__)
  #define TAS(lock) tas(lock)

  static __inline__ int
Index: src/interfaces/ecpg/preproc/pgc.l
===================================================================
RCS file: /home/projects/pgsql/cvsroot/pgsql/src/interfaces/ecpg/preproc/pgc.l,v
retrieving revision 1.73
diff -c -r1.73 pgc.l
*** src/interfaces/ecpg/preproc/pgc.l    2001/01/24 19:43:29    1.73
--- src/interfaces/ecpg/preproc/pgc.l    2001/02/02 18:13:17
***************
*** 35,40 ****
--- 35,45 ----
  #undef yywrap
  #endif /* yywrap */

+ #ifdef __QNX__
+ /* For some reason, QNX needs this, 2001-02-02 */
+ #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
+ #endif
+
  #define YY_NO_UNPUT

  extern YYSTYPE yylval;

Re: 7.1 beta 3 CHANGES FOR QNX

From
"Maurizio"
Date:
I have tested and works well.

.
----- Original Message -----
From: "Bruce Momjian" <pgman@candle.pha.pa.us>
To: "Maurizio" <maurizio.c@libero.it>
Cc: <pgsql-hackers@postgresql.org>
Sent: Friday, February 02, 2001 7:21 PM
Subject: Re: [HACKERS] 7.1 beta 3 CHANGES FOR QNX


> I have applied the following patch for QNX.  I had to do the ECHO test
> in pgc.l because pgc.c is generated from pgc.l.  Can you test this to
> see it fixes the problem?
>
>
> in [ Charset ISO-8859-1 unsupported, converting... ]
> > I have compiled 7.1 b3 in QNX but to let postgresql works I changed
something.
> >
> > In src/backend/port/qnx4/sem.c
> > #define SEMMAX
SEMS_PER_SET)             ----------------------OLD
> > #define SEMMAX      (PROC_NSEMS_PER_SET +  ----------------------NEW
> >
> > in src/include/storage/s_lock.h
> > #if                 ----------------------OLD
> > #if (defined(__i386__) &&                  ----------------------NEW
> >
> > in src/interfaces/ecpg/preproc/pgc.c
> > #ifndef    ---------------------OLD
> > #ifndef (ECHO ||                 ----------------------NEW
> >
> > Attached are the files
> >
> >
> >
> >
> > Maurizio Cauci
> > DREAMTECH di Cauci Maurizio
> > Via Ronchetti, 2 - 21013 Gallarate (VA)
> > www.dreamtech-it.com
> >
>
> [ Attachment, skipping... ]
>
> [ Attachment, skipping... ]
>
> [ Attachment, skipping... ]
>
>
> --
>   Bruce Momjian                        |  http://candle.pha.pa.us
>   pgman@candle.pha.pa.us               |  (610) 853-3000
>   +  If your life is a hard drive,     |  830 Blythe Avenue
>   +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026
>


----------------------------------------------------------------------------
----


> ? config.log
> ? config.cache
> ? config.status
> ? GNUmakefile
> ? src/Makefile.custom
> ? src/GNUmakefile
> ? src/Makefile.global
> ? src/log
> ? src/crtags
> ? src/backend/port/Makefile
> ? src/bin/pg_dump/pg_dump
> ? src/bin/pg_dump/pg_restore
> ? src/bin/pg_dump/pg_dumpall
> ? src/include/config.h
> ? src/include/stamp-h
> ? src/interfaces/libpq/libpq.so.2.1
> Index: src/backend/port/qnx4/sem.c
> ===================================================================
> RCS file: /home/projects/pgsql/cvsroot/pgsql/src/backend/port/qnx4/sem.c,v
> retrieving revision 1.3
> diff -c -r1.3 sem.c
> *** src/backend/port/qnx4/sem.c 2000/04/12 17:15:30 1.3
> --- src/backend/port/qnx4/sem.c 2001/02/02 18:13:12
> ***************
> *** 26,32 ****
>
>
>   #define SETMAX ((MAXBACKENDS + PROC_NSEMS_PER_SET - 1) /
PROC_NSEMS_PER_SET)
> ! #define SEMMAX (PROC_NSEMS_PER_SET)
>   #define OPMAX 8
>
>   #define MODE 0700
> --- 26,32 ----
>
>
>   #define SETMAX ((MAXBACKENDS + PROC_NSEMS_PER_SET - 1) /
PROC_NSEMS_PER_SET)
> ! #define SEMMAX (PROC_NSEMS_PER_SET+1)
>   #define OPMAX 8
>
>   #define MODE 0700
> Index: src/include/storage/s_lock.h
> ===================================================================
> RCS file:
/home/projects/pgsql/cvsroot/pgsql/src/include/storage/s_lock.h,v
> retrieving revision 1.86
> diff -c -r1.86 s_lock.h
> *** src/include/storage/s_lock.h 2001/01/24 19:43:28 1.86
> --- src/include/storage/s_lock.h 2001/02/02 18:13:13
> ***************
> *** 112,118 ****
>    */
>
>
> ! #if defined(__i386__)
>   #define TAS(lock) tas(lock)
>
>   static __inline__ int
> --- 112,118 ----
>    */
>
>
> ! #if defined(__i386__) && !defined(__QNX__)
>   #define TAS(lock) tas(lock)
>
>   static __inline__ int
> Index: src/interfaces/ecpg/preproc/pgc.l
> ===================================================================
> RCS file:
/home/projects/pgsql/cvsroot/pgsql/src/interfaces/ecpg/preproc/pgc.l,v
> retrieving revision 1.73
> diff -c -r1.73 pgc.l
> *** src/interfaces/ecpg/preproc/pgc.l 2001/01/24 19:43:29 1.73
> --- src/interfaces/ecpg/preproc/pgc.l 2001/02/02 18:13:17
> ***************
> *** 35,40 ****
> --- 35,45 ----
>   #undef yywrap
>   #endif /* yywrap */
>
> + #ifdef __QNX__
> + /* For some reason, QNX needs this, 2001-02-02 */
> + #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
> + #endif
> +
>   #define YY_NO_UNPUT
>
>   extern YYSTYPE yylval;
>



Re: 7.1 beta 3 CHANGES FOR QNX

From
Tom Lane
Date:
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> *** src/interfaces/ecpg/preproc/pgc.l    2001/01/24 19:43:29    1.73
> --- src/interfaces/ecpg/preproc/pgc.l    2001/02/02 18:13:17
> ***************
> *** 35,40 ****
> --- 35,45 ----
>   #undef yywrap
>   #endif /* yywrap */ 
> + #ifdef __QNX__
> + /* For some reason, QNX needs this, 2001-02-02 */
> + #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
> + #endif
> + 
>   #define YY_NO_UNPUT 
>   extern YYSTYPE yylval;

I do not believe this patch is correct or necessary.  What is it trying
to fix, and if there's a problem here then why is there not a problem in
every other one of our flex outputs?

If there is a real problem --- presumably of the form "some QNX header
file pollutes the namespace with a definition of ECHO" ---  then a more
appropriate fix would be

+ #ifdef __QNX__
+ /* Get rid of conflicting definition of ECHO from QNX's <something.h> */
+ #undef ECHO
+ #endif

so as not to tie ourselves to the exact definition of ECHO that flex is
currently using.  However, I would first like to know where the conflict
is and why it doesn't break every other flex output in existence.
        regards, tom lane


Re: 7.1 beta 3 CHANGES FOR QNX

From
"Maurizio"
Date:
ECHO is defined in the following QNX gcc include files :
termio.h
termios.h

If ECHO was not redefined in pgc.l you can't compile in embedded SQL C.

I am also checking for another problem.
I have some errors if I compile pgsql without change the typedef Size in
c.h.
To succesfully compile pgsql I have changed typedef Size in int insteed
size_t.

regards
Maurizio Cauci



.
----- Original Message -----
From: "Tom Lane" <tgl@sss.pgh.pa.us>
To: "Bruce Momjian" <pgman@candle.pha.pa.us>
Cc: "Maurizio" <maurizio.c@libero.it>; <pgsql-hackers@postgresql.org>
Sent: Saturday, February 03, 2001 9:49 PM
Subject: Re: [HACKERS] 7.1 beta 3 CHANGES FOR QNX


> Bruce Momjian <pgman@candle.pha.pa.us> writes:
> > *** src/interfaces/ecpg/preproc/pgc.l 2001/01/24 19:43:29 1.73
> > --- src/interfaces/ecpg/preproc/pgc.l 2001/02/02 18:13:17
> > ***************
> > *** 35,40 ****
> > --- 35,45 ----
> >   #undef yywrap
> >   #endif /* yywrap */
>
> > + #ifdef __QNX__
> > + /* For some reason, QNX needs this, 2001-02-02 */
> > + #define ECHO (void) fwrite( yytext, yyleng, 1, yyout )
> > + #endif
> > +
> >   #define YY_NO_UNPUT
>
> >   extern YYSTYPE yylval;
>
> I do not believe this patch is correct or necessary.  What is it trying
> to fix, and if there's a problem here then why is there not a problem in
> every other one of our flex outputs?
>
> If there is a real problem --- presumably of the form "some QNX header
> file pollutes the namespace with a definition of ECHO" ---  then a more
> appropriate fix would be
>
> + #ifdef __QNX__
> + /* Get rid of conflicting definition of ECHO from QNX's <something.h> */
> + #undef ECHO
> + #endif
>
> so as not to tie ourselves to the exact definition of ECHO that flex is
> currently using.  However, I would first like to know where the conflict
> is and why it doesn't break every other flex output in existence.
>
> regards, tom lane



Re: 7.1 beta 3 CHANGES FOR QNX

From
Tom Lane
Date:
"Maurizio" <maurizio.c@libero.it> writes:
> ECHO is defined in the following QNX gcc include files :
> termio.h
> termios.h
> If ECHO was not redefined in pgc.l you can't compile in embedded SQL C.

Well, my question still stands: why aren't the other four flex outputs
also broken?  They all use ECHO.

In any case, I'd prefer to see this fixed by not including <termios.h>
rather than hacking up the .l files.  Surely it doesn't need to be
included everywhere, as src/include/port/qnx4.h is now causing to
happen.  In fact, it looks to me like qnx4.h probably includes and
defines a lot more than it needs to; would you experiment with stripping
it down?

> I am also checking for another problem.
> I have some errors if I compile pgsql without change the typedef Size in
> c.h.
> To succesfully compile pgsql I have changed typedef Size in int insteed
> size_t.

That strikes me as *horribly* dangerous.  There is too much code whose
behavior might change in unpleasant ways if Size becomes a signed type.
Please explain what problems you are seeing that make you think this is
a good idea.


Andreas, the QNX port is largely your work IIRC.  What do you think of
these issues?  Have you tried 7.1beta on QNX?
        regards, tom lane


Re: 7.1 beta 3 CHANGES FOR QNX

From
"Maurizio"
Date:
> "Tom Lane" <tgl@sss.pgh.pa.us> writes:
>> Well, my question still stands: why aren't the other four flex outputs
>> also broken?  They all use ECHO.

I don't know why, but probably you are right. I only know that if ECHO was
not redefined, when I compile with ecpg the output c file has all the
original lines on the same row (without an LF).

> In any case, I'd prefer to see this fixed by not including <termios.h>
> rather than hacking up the .l files.  Surely it doesn't need to be
> included everywhere, as src/include/port/qnx4.h is now causing to
> happen.  In fact, it looks to me like qnx4.h probably includes and
> defines a lot more than it needs to; would you experiment with stripping
> it down?

If You want I can experiment on qnx4.h. On Saturday I will post the risults.

> That strikes me as *horribly* dangerous.  There is too much code whose
> behavior might change in unpleasant ways if Size becomes a signed type.
> Please explain what problems you are seeing that make you think this is
> a good idea.

In 7.0.2 and 7.0.3 release I have errors about some parameters in TCP/IP
functions.
The compiler tells me that I have a long int where an int was expected. When
I changed Size in int I compiled successfuly PGSQL. In 7.1 I changed
immediatly the size type and all seems works.
After your message I modified again Size type in size_t and recompiled 7.1
release. I compiled successfuly this version the only warnings are about
elog lines in wich there are Size variables. The compiler tells me I have a
long int where an unsigned was expected  (only the format, there is a %u).
However PGSQL works right.

> Andreas, the QNX port is largely your work IIRC.  What do you think of
> these issues?  Have you tried 7.1beta on QNX?

I  also would like to know what Andreas Kardos think. When, some month ago,
I starded looking for POSTGRESQL and I had a lot of problems compiling 7.0.1
version (the major problem was what I have to do for the Size type?) I send
some e-mails to Dr. Kardos and he tells me that his version working fine.
After the first replay he didn't replay to me.
Also other QNX users has the same problems I had and send me e-mails to know
if I have compiled successfully PGSQl for QNX. Nobody has had a reply from
Dr. Kardos.

regards
Maurizio Cauci


----- Original Message -----
From: "Tom Lane" <tgl@sss.pgh.pa.us>
To: "Maurizio" <maurizio.c@libero.it>
Cc: <pgsql-hackers@postgresql.org>; "Bruce Momjian"
<pgman@candle.pha.pa.us>; "Kardos, Dr. Andreas" <
Sent: Tuesday, February 06, 2001 4:08 AM
Subject: Re: [HACKERS] 7.1 beta 3 CHANGES FOR QNX


> "Maurizio" <maurizio.c@libero.it> writes:
> > ECHO is defined in the following QNX gcc include files :
> > termio.h
> > termios.h
> > If ECHO was not redefined in pgc.l you can't compile in embedded SQL C.
>
> Well, my question still stands: why aren't the other four flex outputs
> also broken?  They all use ECHO.
>
> In any case, I'd prefer to see this fixed by not including <termios.h>
> rather than hacking up the .l files.  Surely it doesn't need to be
> included everywhere, as src/include/port/qnx4.h is now causing to
> happen.  In fact, it looks to me like qnx4.h probably includes and
> defines a lot more than it needs to; would you experiment with stripping
> it down?
>
> > I am also checking for another problem.
> > I have some errors if I compile pgsql without change the typedef Size in
> > c.h.
> > To succesfully compile pgsql I have changed typedef Size in int insteed
> > size_t.
>
> That strikes me as *horribly* dangerous.  There is too much code whose
> behavior might change in unpleasant ways if Size becomes a signed type.
> Please explain what problems you are seeing that make you think this is
> a good idea.
>
>
> Andreas, the QNX port is largely your work IIRC.  What do you think of
> these issues?  Have you tried 7.1beta on QNX?
>
> regards, tom lane




Re: 7.1 beta 3 CHANGES FOR QNX

From
"Maurizio"
Date:
> "Tom Lane" <tgl@sss.pgh.pa.us> writes:
>> Well, my question still stands: why aren't the other four flex outputs
>> also broken?  They all use ECHO.

I don't know why, but probably you are right. I only know that if ECHO was
not redefined, when I compile with ecpg the output c file has all the
original lines on the same row (without an LF).

> In any case, I'd prefer to see this fixed by not including <termios.h>
> rather than hacking up the .l files.  Surely it doesn't need to be
> included everywhere, as src/include/port/qnx4.h is now causing to
> happen.  In fact, it looks to me like qnx4.h probably includes and
> defines a lot more than it needs to; would you experiment with stripping
> it down?

If You want I can experiment on qnx4.h. On Saturday I will post the risults.

> That strikes me as *horribly* dangerous.  There is too much code whose
> behavior might change in unpleasant ways if Size becomes a signed type.
> Please explain what problems you are seeing that make you think this is
> a good idea.

In 7.0.2 and 7.0.3 release I have errors about some parameters in TCP/IP
functions.
The compiler tells me that I have a long int where an int was expected. When
I changed Size in int I compiled successfuly PGSQL. In 7.1 I changed
immediatly the size type and all seems works.
After your message I modified again Size type in size_t and recompiled 7.1
release. I compiled successfuly this version the only warnings are about
elog lines in wich there are Size variables. The compiler tells me I have a
long int where an unsigned was expected  (only the format, there is a %u).
e.g. readfuncs.c at 2089 and 2113.
However PGSQL works right.

> Andreas, the QNX port is largely your work IIRC.  What do you think of
> these issues?  Have you tried 7.1beta on QNX?

I  also would like to know Andreas Kardos is still out there and what he
think. When, some month ago,
I starded looking for POSTGRESQL and I had a lot of problems compiling 7.0.1
version (the major problem was what I have to do for the Size type?) I send
some e-mails to Dr. Kardos and he tells me that his version working fine.
After the first replay he never didn't replay to me.
Also other QNX users has the same problems I had and send me e-mails to know
if I have compiled successfully PGSQL for QNX. Nobody has had a reply from
Dr. Kardos.

thanks

regards
Maurizio Cauci


----- Original Message -----
From: "Tom Lane" <tgl@sss.pgh.pa.us>
To: "Maurizio" <maurizio.c@libero.it>
Cc: <pgsql-hackers@postgresql.org>; "Bruce Momjian"
<pgman@candle.pha.pa.us>; "Kardos, Dr. Andreas" <
Sent: Tuesday, February 06, 2001 4:08 AM
Subject: Re: [HACKERS] 7.1 beta 3 CHANGES FOR QNX


> "Maurizio" <maurizio.c@libero.it> writes:
> > ECHO is defined in the following QNX gcc include files :
> > termio.h
> > termios.h
> > If ECHO was not redefined in pgc.l you can't compile in embedded SQL C.
>
> Well, my question still stands: why aren't the other four flex outputs
> also broken?  They all use ECHO.
>
> In any case, I'd prefer to see this fixed by not including <termios.h>
> rather than hacking up the .l files.  Surely it doesn't need to be
> included everywhere, as src/include/port/qnx4.h is now causing to
> happen.  In fact, it looks to me like qnx4.h probably includes and
> defines a lot more than it needs to; would you experiment with stripping
> it down?
>
> > I am also checking for another problem.
> > I have some errors if I compile pgsql without change the typedef Size in
> > c.h.
> > To succesfully compile pgsql I have changed typedef Size in int insteed
> > size_t.
>
> That strikes me as *horribly* dangerous.  There is too much code whose
> behavior might change in unpleasant ways if Size becomes a signed type.
> Please explain what problems you are seeing that make you think this is
> a good idea.
>
>
> Andreas, the QNX port is largely your work IIRC.  What do you think of
> these issues?  Have you tried 7.1beta on QNX?
>
> regards, tom lane





Re: 7.1 beta 3 CHANGES FOR QNX

From
"Maurizio"
Date:
Hi,
I have deleted the include of termios.h in include/port/qnx4.h.
Then I recompiled pgsql and I have compiled a program with ecpg.

All seem to work right.

Thanks
Maurizio

.
----- Original Message -----
From: "Tom Lane" <tgl@sss.pgh.pa.us>
To: "Maurizio" <maurizio.c@libero.it>
Cc: <pgsql-hackers@postgresql.org>; "Bruce Momjian"
<pgman@candle.pha.pa.us>; "Kardos, Dr. Andreas" <kardos@repas-aeg.de>
Sent: Tuesday, February 06, 2001 4:08 AM
Subject: Re: [HACKERS] 7.1 beta 3 CHANGES FOR QNX


> "Maurizio" <maurizio.c@libero.it> writes:
> > ECHO is defined in the following QNX gcc include files :
> > termio.h
> > termios.h
> > If ECHO was not redefined in pgc.l you can't compile in embedded SQL C.
>
> Well, my question still stands: why aren't the other four flex outputs
> also broken?  They all use ECHO.
>
> In any case, I'd prefer to see this fixed by not including <termios.h>
> rather than hacking up the .l files.  Surely it doesn't need to be
> included everywhere, as src/include/port/qnx4.h is now causing to
> happen.  In fact, it looks to me like qnx4.h probably includes and
> defines a lot more than it needs to; would you experiment with stripping
> it down?
>
> > I am also checking for another problem.
> > I have some errors if I compile pgsql without change the typedef Size in
> > c.h.
> > To succesfully compile pgsql I have changed typedef Size in int insteed
> > size_t.
>
> That strikes me as *horribly* dangerous.  There is too much code whose
> behavior might change in unpleasant ways if Size becomes a signed type.
> Please explain what problems you are seeing that make you think this is
> a good idea.
>
>
> Andreas, the QNX port is largely your work IIRC.  What do you think of
> these issues?  Have you tried 7.1beta on QNX?
>
> regards, tom lane



Re: 7.1 beta 3 CHANGES FOR QNX

From
Bruce Momjian
Date:
OK, I have removed the termios.h, and thc ECHO hack from pgc.l.

[ Charset ISO-8859-1 unsupported, converting... ]
> Hi,
> I have deleted the include of termios.h in include/port/qnx4.h.
> Then I recompiled pgsql and I have compiled a program with ecpg.
> 
> All seem to work right.
> 
> Thanks
> Maurizio
> 
> .
> ----- Original Message -----
> From: "Tom Lane" <tgl@sss.pgh.pa.us>
> To: "Maurizio" <maurizio.c@libero.it>
> Cc: <pgsql-hackers@postgresql.org>; "Bruce Momjian"
> <pgman@candle.pha.pa.us>; "Kardos, Dr. Andreas" <kardos@repas-aeg.de>
> Sent: Tuesday, February 06, 2001 4:08 AM
> Subject: Re: [HACKERS] 7.1 beta 3 CHANGES FOR QNX
> 
> 
> > "Maurizio" <maurizio.c@libero.it> writes:
> > > ECHO is defined in the following QNX gcc include files :
> > > termio.h
> > > termios.h
> > > If ECHO was not redefined in pgc.l you can't compile in embedded SQL C.
> >
> > Well, my question still stands: why aren't the other four flex outputs
> > also broken?  They all use ECHO.
> >
> > In any case, I'd prefer to see this fixed by not including <termios.h>
> > rather than hacking up the .l files.  Surely it doesn't need to be
> > included everywhere, as src/include/port/qnx4.h is now causing to
> > happen.  In fact, it looks to me like qnx4.h probably includes and
> > defines a lot more than it needs to; would you experiment with stripping
> > it down?
> >
> > > I am also checking for another problem.
> > > I have some errors if I compile pgsql without change the typedef Size in
> > > c.h.
> > > To succesfully compile pgsql I have changed typedef Size in int insteed
> > > size_t.
> >
> > That strikes me as *horribly* dangerous.  There is too much code whose
> > behavior might change in unpleasant ways if Size becomes a signed type.
> > Please explain what problems you are seeing that make you think this is
> > a good idea.
> >
> >
> > Andreas, the QNX port is largely your work IIRC.  What do you think of
> > these issues?  Have you tried 7.1beta on QNX?
> >
> > regards, tom lane
> 
> 


--  Bruce Momjian                        |  http://candle.pha.pa.us pgman@candle.pha.pa.us               |  (610)
853-3000+  If your life is a hard drive,     |  830 Blythe Avenue +  Christ can be your backup.        |  Drexel Hill,
Pennsylvania19026