delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2007/10/09/22:42:14

X-Recipient: archive-cygwin AT delorie DOT com
X-Spam-Check-By: sourceware.org
To: cygwin AT cygwin DOT com
From: =?ISO-8859-1?Q?Ren=E9_Berber?= <r DOT berber AT computer DOT org>
Subject: Re: libuuid
Date: Tue, 09 Oct 2007 21:41:38 -0500
Lines: 51
Message-ID: <fehe52$sfa$1@sea.gmane.org>
References: <3ee066b40710091923q612ff18s469961f5ed363d76 AT mail DOT gmail DOT com>
Mime-Version: 1.0
User-Agent: Thunderbird 2.0.0.6 (Windows/20070728)
In-Reply-To: <3ee066b40710091923q612ff18s469961f5ed363d76@mail.gmail.com>
OpenPGP: url=hkp://wwwkeys.pgp.net
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Antony Baxter wrote:

[snip]
> I've just tried:
>=20
> dllwrap -o uuid.dll --def uuid.def uuid.o
>   /usr/lib/postgresql/pgxs/src/../../src/utils/dllinit.o -L/usr/lib -lpos=
tgres
>   -Wl,-Bstatic -luuid -Wl,-Bdynamic
...
> All three give the same errors:
>=20
> uuid.o:uuid.c:(.text+0xe): undefined reference to `_uuid_compare'
> uuid.o:uuid.c:(.text+0x55): undefined reference to `_uuid_generate_random'
> uuid.o:uuid.c:(.text+0x98): undefined reference to `_uuid_parse'
> uuid.o:uuid.c:(.text+0x174): undefined reference to `_uuid_unparse_lower'
> uuid.o:uuid.c:(.text+0x2fd): undefined reference to `_uuid_unparse_lower'
> collect2: ld returned 1 exit status
> dllwrap: gcc exited with status 1
>=20
> Probably should have mentioned: latest Cygwin DLL, Cygwin (not native Win=
dows)
> PostgreSQL 8.1.4, latest w32api.

Wrong library.

The problem is, where are those functions defined?  There are 2 uuid librar=
ies,
one is /usr/lib/w32api/libuuid.a, but that doesn't have functions that start
with uuid.  The other is /usr/lib/e2fsprogs/libuuid.a and ... bingo! that o=
ne
has the uuid_compare, etc. functions.

So change the command, and BTW libpostgres is also static, so my next guess=
 is:

dllwrap -o uuid.dll --def uuid.def uuid.o
   /usr/lib/postgresql/pgxs/src/../../src/utils/dllinit.o -L/usr/lib
   -L/usr/lib/e2fsprogs -Wl,-Bstatic -lpostgres -luuid -Wl,-Bdynamic

Another hint of what may be wrong was on your first message, the "warning:
implicit declaration of function `uuid_unparse_lower'" means that the code =
is so
bad that they didn't even include the header.
--=20
Ren=E9 Berber


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019