Thread: BUG #5623: xml2 and uuid-ossp contribs fail to compile

BUG #5623: xml2 and uuid-ossp contribs fail to compile

From
"Jens Wilke"
Date:
The following bug has been logged online:

Bug reference:      5623
Logged by:          Jens Wilke
Email address:      jens.wilke@affinitas.de
PostgreSQL version: 9.0b4
Operating system:   Debian GNU/Linux Lenny
Description:        xml2 and uuid-ossp contribs fail to compile
Details:

Hi,

to compile xml2 this link was necessary:
ln -s /usr/include/libxml2/libxml ../../src/include

uuid-ossp fails  with
libossp-uuid-dev installed:
postgres@dbmaster:/usr/src/postgresql-9.0beta4/contrib/uuid-ossp$ make
gcc -O2 -Wall -Wmissing-prototypes -Wpointer-arith
-Wdeclaration-after-statement -Wendif-labels -fno-strict-aliasing -fwrapv
-fpic -I. -I. -I../../src/include -D_GNU_SOURCE   -c -o uuid-ossp.o
uuid-ossp.c
uuid-ossp.c:29:2: error: #error OSSP uuid.h not found

uuid-ossp.c:35:2: error: #error UUID length mismatch

uuid-ossp.c:68: error: expected ‘)’ before ‘rc’

uuid-ossp.c:83: warning: type defaults to ‘int’ in declaration of
‘uuid_t’
uuid-ossp.c:83: error: expected ‘;’, ‘,’ or ‘)’ before ‘*’
token
uuid-ossp.c:99: error: expected declaration specifiers or ‘...’ before
‘uuid_t’
uuid-ossp.c: In function ‘string_to_uuid’:

uuid-ossp.c:101: error: ‘uuid_rc_t’ undeclared (first use in this
function)
uuid-ossp.c:101: error: (Each undeclared identifier is reported only once

uuid-ossp.c:101: error: for each function it appears in.)

uuid-ossp.c:101: error: expected ‘;’ before ‘rc’

Re: BUG #5623: xml2 and uuid-ossp contribs fail to compile

From
Mike Fowler
Date:
On 18/08/10 14:55, Jens Wilke wrote:
> The following bug has been logged online:
>
> Bug reference:      5623
> Logged by:          Jens Wilke
> Email address:      jens.wilke@affinitas.de
> PostgreSQL version: 9.0b4
> Operating system:   Debian GNU/Linux Lenny
> Description:        xml2 and uuid-ossp contribs fail to compile
> Details:
>
> Hi,
>
> to compile xml2 this link was necessary:
> ln -s /usr/include/libxml2/libxml ../../src/include
>

I can't comment on uuid-ossp, but your XML problem sounds to me like
libxml2 wasn't installed correctly. What parameters did you pass to
configure? Could you build postgres with xml support? As in:

path/to/pgsql/src> ./configure --with-libxml
path/to/pgsql/src> make && make check

Regards,

--
Mike Fowler
Registered Linux user: 379787

Re: BUG #5623: xml2 and uuid-ossp contribs fail to compile

From
Robert Haas
Date:
On Wed, Aug 18, 2010 at 9:55 AM, Jens Wilke <jens.wilke@affinitas.de> wrote:
> uuid-ossp.c:29:2: error: #error OSSP uuid.h not found

This seems like the one to look at.  Perhaps you need to apt-get
install the package that contains that file.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise Postgres Company

Re: BUG #5623: uuid-ossp contribs fail to compile

From
Jens Wilke
Date:
Am Mittwoch 18 August 2010 19:30:51 schrieb Robert Haas:
> On Wed, Aug 18, 2010 at 9:55 AM, Jens Wilke <jens.wilke@affinitas.de> wro=
te:
> > uuid-ossp.c:29:2: error: #error OSSP uuid.h not found
>=20
> This seems like the one to look at.  Perhaps you need to apt-get
> install the package that contains that file.

After a=20
./configure --with-libxml --with-libxslt --with-python --with-perl --with-o=
ssp-
uuid --enable-thread-safety --prefix=3D/server/postgres/9.0b4

the not found error message went away, but i still get the following error:
uuid-ossp$ make=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
gcc -O2 -Wall -Wmissing-prototypes -Wpointer-arith -Wdeclaration-after-
statement -Wendif-labels -fno-strict-aliasing -fwrapv -fpic -I. -I. -
I../../src/include -D_GNU_SOURCE -I/usr/include/libxml2   -c -o uuid-ossp.o=
=20
uuid-ossp.c=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:35:2: error: #error UUID length mismatch=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20
uuid-ossp.c:68: error: expected =E2=80=98)=E2=80=99 before =E2=80=98rc=E2=
=80=99=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c: In function =E2=80=98uuid_to_string=E2=80=99:=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:85: error: =E2=80=98UUID_LEN_STR=E2=80=99 undeclared (first use=
 in this function)=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:85: error: (Each undeclared identifier is reported only once=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:85: error: for each function it appears in.)=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:88: error: =E2=80=98uuid_rc_t=E2=80=99 undeclared (first use in=
 this function)=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:88: error: expected =E2=80=98;=E2=80=99 before =E2=80=98rc=E2=
=80=99=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:90: error: =E2=80=98rc=E2=80=99 undeclared (first use in this f=
unction)=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:90: warning: implicit declaration of function =E2=80=98uuid_exp=
ort=E2=80=99=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:90: error: =E2=80=98UUID_FMT_STR=E2=80=99 undeclared (first use=
 in this function)=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:91: error: =E2=80=98UUID_RC_OK=E2=80=99 undeclared (first use i=
n this function)=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c:92: warning: implicit declaration of function =E2=80=98pguuid_c=
omplain=E2=80=99=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20
uuid-ossp.c: In function =E2=80=98string_to_uuid=E2=80=99:=20=20=20=20=20=
=20=20=20=20=20=20=20=20=20=20=20=20

--=20
Affinitas GmbH  |  Kohlfurter Stra=C3=9Fe 41/43  |  10999 Berlin  |  Germany

Gesch=C3=A4ftsf=C3=BChrer: Lukas Brosseder, David Khalil, Kai Rieke, Christ=
ian Vollmann
Eingetragen beim Amtsgericht Berlin, HRB 115958

Re: BUG #5623: xml2 and uuid-ossp contribs fail to compile

From
Jens Wilke
Date:
On a freshly untared archive, make uuid-ossp  woked fine now.

Jens

--=20
Affinitas GmbH  |  Kohlfurter Stra=DFe 41/43  |  10999 Berlin  |  Germany

Gesch=E4ftsf=FChrer: Lukas Brosseder, David Khalil, Kai Rieke, Christian Vo=
llmann
Eingetragen beim Amtsgericht Berlin, HRB 115958