Re: [HACKERS] int8 type -- call for porting results! - Mailing list pgsql-hackers

From Bruce Momjian
Subject Re: [HACKERS] int8 type -- call for porting results!
Date
Msg-id 199808240105.VAA28217@candle.pha.pa.us
Whole thread Raw
In response to Re: [HACKERS] int8 type -- call for porting results!  (David Hartwig <daveh@insightdist.com>)
List pgsql-hackers
Has this been fixed?


> I just started compiling the 6.4 snapshot from this weekend on our AIX 4.1.4
> system.   I am running into problems surrounding snprintf().
>
> 1.  Do I need to set something in Makefile.global to activate the
> compilation of snprintf()
>
> 2.  snprintf() does not compile clean.  It has several explicate referenced
> to FILE data elements which are not on our FILE structure.   The error
> messages follow:
>
>        81 |         f._flags = __SWR | __SSTR;
>             ........a..........b.......c......
> a - 1506-022 (S) "_flags" is not a member of "struct {...}".
> b - 1506-045 (S) Undeclared identifier __SWR.
> c - 1506-045 (S) Undeclared identifier __SSTR.
>        82 |         f._bf._base = f._p = (unsigned char *)str;
>             ........a.............b...........................
> a - 1506-022 (S) "_bf" is not a member of "struct {...}".
> b - 1506-022 (S) "_p" is not a member of "struct {...}".
>        83 |         f._bf._size = f._w = n;
>             ........a.............b........
> a - 1506-022 (S) "_bf" is not a member of "struct {...}".
> b - 1506-022 (S) "_w" is not a member of "struct {...}".
>        86 |                 *f._p = '\0';
>             .................a...........
> a - 1506-022 (S) "_p" is not a member of "struct {...}".
> gmake: *** [snprintf.o] Error 1
>
> This section does not look to portable.   I'm thinking that you could  use a
> simple sprintf() in int8out() and made the buffer sufficiently big enough
> that it could not overflow.   I will gladly submit a patch.
>
> Please advise.
>
> Thomas G. Lockhart wrote:
>
> > Hi. A month or two ago I put an int8 data type into Postgres. Aside from
> > being useful on its own, it could also form the basis for other types
> > needing extended range, such as money, decimal, and numeric types (the
> > last two are SQL92 types).
> >
> > Anyway, I implemented it on a gcc/x86/Linux machine, and we will need to
> > ensure that it works on other platforms. If you are doing any work at
> > all with a post-v6.3.2 source tree on another platform/OS combination,
> > can you please look at the results of the int8 regression test, or run
> > that test on your own, and let me know if it worked? If it didn't work,
> > then we should either put it on the list of things to do or make it work
> > in time for v6.4. But at the moment I don't know either way.
> >
> > btw, there is a chance that the Alpha port will work since I coded for
> > it and I used to work on Alpha machines...
> >
> > TIA
> >
> >                      - Tom
>
>
>
>
>


--
Bruce Momjian                          |  830 Blythe Avenue
maillist@candle.pha.pa.us              |  Drexel Hill, Pennsylvania 19026
  +  If your life is a hard drive,     |  (610) 353-9879(w)
  +  Christ can be your backup.        |  (610) 853-3000(h)

pgsql-hackers by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] initdb problem
Next
From: Bruce Momjian
Date:
Subject: Re: new MB patch and pg_type oid problem