libpq.so linking problem on Solaris using --with-gssapi
От | Bjorn Munch |
---|---|
Тема | libpq.so linking problem on Solaris using --with-gssapi |
Дата | |
Msg-id | 20080304115744.GA5471@khepri12.norway.sun.com обсуждение исходный текст |
Ответы |
Re: libpq.so linking problem on Solaris using --with-gssapi
|
Список | pgsql-patches |
When building PostgreSQL 8.3 on Solaris using the configure option "--with-gssapi", libpq.so is not linked correctly. This line in the libpq Makefile is selecting the appropriate linker options: --- SHLIB_LINK += $(filter -lcrypt -ldes -lcom_err -lcrypto -lk5crypto -lkrb5 -lgssapi_krb5 -lssl -lsocket -lnsl -lresolv -lintl,$(LIBS)) $(LDAP_LIBS_FE) $(PTHREAD_LIBS) --- This includes "-lgssapi_krb5", but for Solaris this should be just "-lgss". The result is that libpq.so does not load libgss.so. psql still works because it apparently loads libgss.so before it loads libpq.so, otherwise it would surely have been discovered earlier. But when I tried to run a test for the TCL client interface I got: --- TCL test status: Started couldn't load file "libpgtcl1.5.so": ld.so.1: tclsh8.4: fatal: relocation error: file <....>/lib/libpq.so.5: symbol GSS_C_NT_HOSTBASED_SERVICE:referenced symbol not found while executing "load libpgtcl1.5.so" (file "./import_sampledata.tcl" line 7) --- This could affect other clients too. The fix is simply to add "-lgss" to the list, as the attached patch does. I'm pretty sure no other Makefiles are affected. Tested on Solaris (x86 and sparc), and also Linux (RHEL 5). I plan to apply this patch when I integrate 8.3.0 into OpenSolaris. -- Bjorn Munch Database Technology Group Sun Microsystems
Вложения
В списке pgsql-patches по дате отправления: