GNOME Bugzilla – Bug 503359
solaris ld does not support --version-script
Last modified: 2009-02-26 12:52:36 UTC
Please describe the problem: On solaris, I'm using suncc to compile gtk-vnc trunk code. /opt/jdsbld/bin/ld-wrapper -G -h libgtk-vnc-1.0.so.0 -o .libs/libgtk-vnc-1.0.so.0.0.1 .libs/libgtk_vnc_1_0_la-continuation.o .libs/libgtk_vnc_1_0_la-coroutine.o .libs/libgtk_vnc_1_0_la-d3des.o .libs/libgtk_vnc_1_0_la-gvnc.o .libs/libgtk_vnc_1_0_la-vncdisplay.o .libs/libgtk_vnc_1_0_la-vncshmimage.o .libs/libgtk_vnc_1_0_la-vncmarshal.o -R/usr/X11/lib -L/usr/X11/lib -lgtk-x11-2.0 -lgdk-x11-2.0 -lXi -lXext -lX11 -latk-1.0 -lgdk_pixbuf-2.0 -lm -lmlib -lpangocairo-1.0 -lfontconfig -lXrandr -lXcomposite -lXdamage -lpango-1.0 -lcairo -lXfixes -lgobject-2.0 -lgmodule-2.0 -lglib-2.0 -lgnutls -lc --version-script=./libgtk-vnc_sym.version /usr/ccs/bin/ld: illegal option -- version-script=./libgtk-vnc_sym.version usage: ld [-6:abc:d:e:f:h:il:mo:p:rstu:z:B:CD:F:GI:L:M:N:P:Q:R:S:VY:?] file(s) [-64] enforce a 64-bit link-edit [-a] create an absolute file [-b] do not do special PIC relocations in a.out [-B direct | nodirect] establish direct bindings, or inhibit direct binding to, the object being created Steps to reproduce: 1. 2. 3. Actual results: build pass Expected results: build fail Does this happen every time? yes Other information:
According a gnome-keyring bug #462349, we should use -export-symbols-regex instead of --version-script for the compatible concern. I merge the patch with bug #503360.
Hi, Halton. Is this already fixed?
Created attachment 108765 [details] [review] patch for bug #503359 No, this bug is not fixed on trunk yet. --version-script is not supported with solaris ld. Use export-symbols-regex will fix this bug.
Hi, Halton. This patch worked for me (on linux). Could you send it to gtk-vnc mailing list? Also, you don't need to edit Changelog file, it's automatically generated by the messages you supply when committing.
Created attachment 109354 [details] [review] patch for bug #503359 rework patch, request from Anthony Liguori. That's b/c --version-script has to take an option. If you do ld --version-script= you'll get the right output. This patch will let ld work on Solaris and Linux both. On system which ld does not support --version-script like Solaris $cat src/Makefile|grep ^libgtk_vnc_1_0_la_LDFLAGS libgtk_vnc_1_0_la_LDFLAGS = -Wl, export-symbols-regex 'vnc_' \ On system which ld support --version-script like Ubuntu $ cat src/Makefile|grep ^libgtk_vnc_1_0_la_LDFLAGS libgtk_vnc_1_0_la_LDFLAGS = -Wl, --version-script= $(srcdir)/libgtk-vnc_sym.version \
Fixed.