Mail Archives: cygwin/2007/10/09/22:42:14
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 -