Hi,
This is driving me crazy. When we were using MySQL 4.0.x we could create
a shared library with libmysqlclient.a bound in.
With MySQL 4.1 onwards, we get the error,
/usr/ccs/bin/ld: Invalid loader fixup in text space needed in output
file for symbol "$0000003A" in input file
"/usr/local/mysql5/lib/libmysqlclient.a(client.o)"
Operating system: HPUX 11.00 (yes, I have to keep it going to support
some customers who won't upgrade!)
Compiler: HPUX C
This is really easily reproduced with a 7 line program...
test.c
/* === snip === */
#include <stdlib.h>
#include <stdio.h>
#include <mysql.h>
void testfunc() {
static MYSQL* conn;
conn= mysql_init(NULL);
}
/* === snip === */
On MySQL 4.0.x, you can create the shared library libtest.sl using,
cc -I/usr/local/mysql4/include -o libtest.sl -b -Aa +e +DAportable
-Wl,+s -notrigraph test.c -L/usr/local/mysql4/lib -lmysqlclient -lcrypt
-lnsl -lm
That works fine.
However on 4.1 and later versions of MySQL, the command (-lz needs to be
added for these versions) gives,
cc -I/usr/local/mysql5/include -o libtest.sl -b -Aa +e +DAportable
-Wl,+s -notrigraph test.c -L/usr/local/mysql5/lib -lmysqlclient -lz
-lcrypt -lnsl -lm
/usr/ccs/bin/ld: Invalid loader fixup in text space needed in output
file for symbol "$0000003A" in input file
"/usr/local/mysql5/lib/libmysqlclient.a(client.o)"
Help!
Regards,
Ian Collins.
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]