UnixWare 7.x port updates. - Mailing list pgsql-hackers

From Billy G. Allie
Subject UnixWare 7.x port updates.
Date
Msg-id 199810040930.FAA21833@bgalli.mug.org
Whole thread Raw
Responses Re: [HACKERS] UnixWare 7.x port updates.  (Bruce Momjian <maillist@candle.pha.pa.us>)
Re: [HACKERS] UnixWare 7.x port updates.  (Bruce Momjian <maillist@candle.pha.pa.us>)
List pgsql-hackers
Recent additions to the PostgreSQL 6.4 tree broke the UnixWare 7.x port.  Here
are the patches to fix them:

1.  In 'src/backend/utils/adt/ip.c', the functions 'ipaddr_eq()' and
    'ipaddr_ge()' were used before being defined.  I reordered the functions so
    that they were defined before being used.

2.  In 'src/include/utils/mac.h', I included the file 'sys/bitypes.h' if the
    code is being compiled by a USL compiler (i.e. UnixWare).  This is needed
    to define the 'u_int32_t' type.

3.  In 'src/include/c.h', I add a check to see if 'bool' had been defined as a
    macro before attempting to typeset it.  In some instances, 'bool' is
    defined as a macro that expands to 'char'.  The UnixWare compiler complains
    if you try to compile "typeset char char;".

4.  In 'src/pl/plpgsql/src/pl_exec.c', there is a construct that is incorrect.
    This construct is '((int4)(var->value))--' and '((int4)(var->value))++'.
    What this is saying is to take result of the expression '(var->value)',
    cast it as an 'int4', and then increment it.  This can not work as the
    result of the expression is not an 'LVALUE' and thus can not be the target
    of the '--' or the '++' operator.  What is needed is '(int4)var->value--'
    or '(int4)var->value++' [assuming the desired result is to decrement(in-
    crement) 'var->value' as if it were an 'int4'].

5.  In 'src/test/regress/checkresults', the use of the '-u' option is assuming
    the use of GNU diff.

There were some additional portability problems with the make file for plpgsql
that I do not address with these patches.  I will supply a Makefile.in for
plpgsql that will address these problems shortly.

The UnixWare 7.x port now passes the regression tests except for differences
in the some error messages and floating point precision.

BTW:  The plpgsql language seems to working well, at least for the simple
      things that I am currently using them for.

      Thanks Jan for the good work on PL/pgsql!

____       | Billy G. Allie    | Domain....: Bill.Allie@mug.org
|  /|      | 7436 Hartwell     | Compuserve: 76337,2061
|-/-|----- | Dearborn, MI 48126| MSN.......: B_G_Allie@email.msn.com
|/  |LLIE  | (313) 582-1540    |

Attachment

pgsql-hackers by date:

Previous
From: "Thomas G. Lockhart"
Date:
Subject: Re: IP test program
Next
From: Sergio Brandano
Date:
Subject: ...