From: | "D'Arcy" "J(dot)M(dot)" Cain <darcy(at)druid(dot)net> |
---|---|
To: | current-users(at)netbsd(dot)org, pgsql-hackers(at)postgreSQL(dot)org |
Subject: | More on shared objects problem |
Date: | 1999-07-27 12:12:19 |
Message-ID: | m11965j-0000dNC@druid.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Many thanks to everyone who helped so far especially Todd Vierling for
the RTFF. I think I am closer but I still have a problem. Here is the
rule in my makefile now.
.o.so:
ld -shared -L${PGDIR}/lib --export-dynamic -rpath ${PGDIR}/lib \
-lpq -lc -o $@ $<
ldd now shows this.
glaccount.so:
-lpq => /usr/pgsql/lib/libpq.so
-lc.12 => /usr/lib/libc.so.12
I then went into the PostgreSQL code and added a dlerror() call to the
error message after dlopen(). I still get an error but now I get a little
more information.
ERROR: Load of file /usr/pgsql/modules/glaccount.so failed: dlopen (/usr/pgsql/modules/glaccount.so) failed (/usr/pgsql/modules/glaccount.so: Undefined symbol "CurrentMemoryContext" (reloc type = 6, symnum = 6))
CurrentMemoryContext is defined in the postmaster (I checked with nm) which
is the program doing the dlopen. Here is the relevant line from nm.
08138544 D CurrentMemoryContext
So it looks like everything should be working but it doesn't. Is this
possibly a case of bogus error message or am I misunderstanding it? Is
ELF fully baked or do I need to revert to a pre-ELF system?
Hmm. I just noticed that nm is an old binary and that it doesn't build
from current sources due to a missing bfd.h. Is nm like ldconfig and
not needed any more on ELF systems or is there just a problem with
the current sources?
--
D'Arcy J.M. Cain <darcy(at){druid|vex}.net> | Democracy is three wolves
http://www.druid.net/darcy/ | and a sheep voting on
+1 416 424 2871 (DoD#0082) (eNTP) | what's for dinner.
From | Date | Subject | |
---|---|---|---|
Next Message | A James Lewis | 1999-07-27 12:12:43 | Re: [HACKERS] BLOBS and security |
Previous Message | Vince Vielhaber | 1999-07-27 10:19:35 | Re: [HACKERS] postgres Web problem |