Issue 64134 - libxau linking failure
Summary: libxau linking failure
Status: CLOSED FIXED
Alias: None
Product: gsl
Classification: Code
Component: code (show other issues)
Version: OOo 2.0.2
Hardware: PC Linux, all
: P3 Trivial with 1 vote (vote)
Target Milestone: OOo 2.2
Assignee: rene
QA Contact: issues@gsl
URL:
Keywords:
: 65789 (view as issue list)
Depends on:
Blocks:
 
Reported: 2006-04-08 15:33 UTC by Miklos Vajna
Modified: 2007-06-03 18:32 UTC (History)
7 users (show)

See Also:
Issue Type: PATCH
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
patch requested by kendy (1.65 KB, text/plain)
2006-05-04 21:03 UTC, Miklos Vajna
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description Miklos Vajna 2006-04-08 15:33:53 UTC
hi

2.0.2 fails to build here due to a mirring linker flag. the end of the log is:
Making: ../unxlngi6.pro/lib/libvclplug_gen680li.so
g++ -Wl,-z,combreloc -Wl,-z,defs -Wl,-rpath,'$ORIGIN' -Wl,-zdynsort -shared
-L../unxlngi6.pro/lib -L../lib
-L/var/tmp/fst/src/ooo-build-2.0.2/build/OOO_2_0_2/solenv/unxlngi6/lib
-L/var/tmp/fst/src/ooo-build-2.0.2/build/OOO_2_0_2/solver/680/unxlngi6.pro/lib
-L/var/tmp/fst/src/ooo-build-2.0.2/build/OOO_2_0_2/solenv/unxlngi6/lib
-LNO_JAVA_HOME/lib -LNO_JAVA_HOME/jre/lib/i386
-LNO_JAVA_HOME/jre/lib/i386/client -LNO_JAVA_HOME/jre/lib/i386/native_threads
-L/usr/X11R6/lib -L/usr/lib/firefox-1.5.0.1
../unxlngi6.pro/slo/vclplug_gen_dflt_version.o
../unxlngi6.pro/slo/vclplug_gen_dflt_description.o -o
../unxlngi6.pro/lib/libvclplug_gen680li.so ../unxlngi6.pro/slo/FWS.o
../unxlngi6.pro/slo/salframe.o ../unxlngi6.pro/slo/salobj.o
../unxlngi6.pro/slo/salmenu.o ../unxlngi6.pro/slo/salgdi2.o
../unxlngi6.pro/slo/salbmp.o ../unxlngi6.pro/slo/salgdi.o
../unxlngi6.pro/slo/salvd.o ../unxlngi6.pro/slo/salogl.o
../unxlngi6.pro/slo/dtint.o ../unxlngi6.pro/slo/salcvt.o
../unxlngi6.pro/slo/xfont.o ../unxlngi6.pro/slo/xlfd_attr.o
../unxlngi6.pro/slo/xlfd_extd.o ../unxlngi6.pro/slo/xlfd_smpl.o
../unxlngi6.pro/slo/salgdi3.o ../unxlngi6.pro/slo/pspgraphics.o
../unxlngi6.pro/slo/salprnpsp.o ../unxlngi6.pro/slo/gcach_xpeer.o
../unxlngi6.pro/slo/i18n_cb.o ../unxlngi6.pro/slo/i18n_ic.o
../unxlngi6.pro/slo/i18n_im.o ../unxlngi6.pro/slo/i18n_xkb.o
../unxlngi6.pro/slo/i18n_wrp.o ../unxlngi6.pro/slo/i18n_status.o
../unxlngi6.pro/slo/i18n_keysym.o ../unxlngi6.pro/slo/saldata.o
../unxlngi6.pro/slo/saltimer.o ../unxlngi6.pro/slo/saldisp.o
../unxlngi6.pro/slo/salinst.o ../unxlngi6.pro/slo/salsys.o
../unxlngi6.pro/slo/soicon.o ../unxlngi6.pro/slo/sm.o
../unxlngi6.pro/slo/keysymnames.o ../unxlngi6.pro/slo/wmadaptor.o
../unxlngi6.pro/slo/salsound2.o ../unxlngi6.pro/slo/osssound.o
../unxlngi6.pro/slo/devaudiosound.o ../unxlngi6.pro/slo/audioconvert.o
../unxlngi6.pro/slo/rptpsound.o ../unxlngi6.pro/slo/nassound.o
../unxlngi6.pro/slo/pasfsound.o -lvcl680li -lpsp680li -lsot680li -lutl680li
-ltl680li -lcomphelp4gcc3 -lucbhelper3gcc3 -luno_cppuhelpergcc3 -luno_cppu
-lvos3gcc3 -luno_sal -Wl,-Bstatic -lXinerama -Wl,-Bdynamic -lsndfile -lportaudio
-laudio -lstartup-notification-1 -lXext -lSM -lICE -lX11 -ldl -ldl -lpthread -lm
-Wl,-Bdynamic -lstlport_gcc
/var/tmp/fst/src/ooo-build-2.0.2/build/OOO_2_0_2/solver/680/unxlngi6.pro/lib/libaudio.a(ConnSvr.o):
In function `GetAuthorization':ConnSvr.c:(.text+0xe8f): undefined reference to
`XauGetBestAuthByAddr'
:ConnSvr.c:(.text+0xfde): undefined reference to `XauDisposeAuth'
collect2: ld returned 1 exit status
dmake:  Error code 1, while making '../unxlngi6.pro/lib/libvclplug_gen680li.so'
'---* tg_merge.mk *---'

ERROR: Error 65280 occurred while making
/var/tmp/fst/src/ooo-build-2.0.2/build/OOO_2_0_2/vcl/util
make: *** [stamp/build] Error 1

a trivial patch for this issue available at:
http://frugalware.org/~vmiklos/logs/ooo-build/libxau/buildfix-link-libxau2.diff

full buildlog at:
http://frugalware.org/~vmiklos/logs/ooo-build/libxau/openoffice.org-2.0.2-1-i686.log.bz2
Comment 1 Miklos Vajna 2006-04-15 16:20:01 UTC
m163 still has this issue:

------------------------------
Making: ../unxlngx6.pro/lib/libvclplug_gen680lx.so
g++ -Wl,-z,combreloc -Wl,-z,defs -Wl,-rpath,'$ORIGIN' -shared
-L../unxlngx6.pro/lib -L../lib
-L/var/tmp/fst/src/ooo-build/build/src680-m163/solenv/unxlngx6/lib
-L/var/tmp/fst/src/ooo-build/build/src680-m163/solver/680/unxlngx6.pro/lib
-L/var/tmp/fst/src/ooo-build/build/src680-m163/solenv/unxlngx6/lib
-LNO_JAVA_HOME/lib64 -LNO_JAVA_HOME/jre/lib/amd64
-LNO_JAVA_HOME/jre/lib/amd64/server -LNO_JAVA_HOME/jre/lib/amd64/native_threads
-L/usr/X11R6/lib64 -L/usr/lib/firefox-1.5.0.2
../unxlngx6.pro/slo/vclplug_gen_dflt_version.o
../unxlngx6.pro/slo/vclplug_gen_dflt_description.o -o
../unxlngx6.pro/lib/libvclplug_gen680lx.so ../unxlngx6.pro/slo/FWS.o
../unxlngx6.pro/slo/salframe.o ../unxlngx6.pro/slo/salobj.o
../unxlngx6.pro/slo/salmenu.o ../unxlngx6.pro/slo/salgdi2.o
../unxlngx6.pro/slo/salbmp.o ../unxlngx6.pro/slo/salgdi.o
../unxlngx6.pro/slo/salvd.o ../unxlngx6.pro/slo/salogl.o
../unxlngx6.pro/slo/dtint.o ../unxlngx6.pro/slo/salcvt.o
../unxlngx6.pro/slo/xfont.o ../unxlngx6.pro/slo/xlfd_attr.o
../unxlngx6.pro/slo/xlfd_extd.o ../unxlngx6.pro/slo/xlfd_smpl.o
../unxlngx6.pro/slo/salgdi3.o ../unxlngx6.pro/slo/pspgraphics.o
../unxlngx6.pro/slo/salprnpsp.o ../unxlngx6.pro/slo/gcach_xpeer.o
../unxlngx6.pro/slo/i18n_cb.o ../unxlngx6.pro/slo/i18n_ic.o
../unxlngx6.pro/slo/i18n_im.o ../unxlngx6.pro/slo/i18n_xkb.o
../unxlngx6.pro/slo/i18n_wrp.o ../unxlngx6.pro/slo/i18n_status.o
../unxlngx6.pro/slo/i18n_keysym.o ../unxlngx6.pro/slo/saldata.o
../unxlngx6.pro/slo/saltimer.o ../unxlngx6.pro/slo/saldisp.o
../unxlngx6.pro/slo/salinst.o ../unxlngx6.pro/slo/salsys.o
../unxlngx6.pro/slo/soicon.o ../unxlngx6.pro/slo/sm.o
../unxlngx6.pro/slo/keysymnames.o ../unxlngx6.pro/slo/wmadaptor.o
../unxlngx6.pro/slo/salsound2.o ../unxlngx6.pro/slo/osssound.o
../unxlngx6.pro/slo/devaudiosound.o ../unxlngx6.pro/slo/audioconvert.o
../unxlngx6.pro/slo/rptpsound.o ../unxlngx6.pro/slo/nassound.o
../unxlngx6.pro/slo/pasfsound.o -lvcl680lx -lpsp680lx -lsot680lx -lutl680lx
-ltl680lx -lcomphelp4gcc3 -lucbhelper3gcc3 -luno_cppuhelpergcc3 -luno_cppu
-lvos3gcc3 -luno_sal -Wl,-Bstatic -lXinerama -Wl,-Bdynamic -lsndfile -lportaudio
-laudio -lstartup-notification-1 -lXext -lSM -lICE -lX11 -ldl -ldl -lpthread -lm
-Wl,-Bdynamic -lstlport_gcc
/var/tmp/fst/src/ooo-build/build/src680-m163/solver/680/unxlngx6.pro/lib/libaudio.a(ConnSvr.o):
In function `GetAuthorization':ConnSvr.c:(.text+0xfa9): undefined reference to
`XauGetBestAuthByAddr'
:ConnSvr.c:(.text+0x1100): undefined reference to `XauDisposeAuth'
collect2: ld returned 1 exit status
dmake:  Error code 1, while making '../unxlngx6.pro/lib/libvclplug_gen680lx.so'
'---* tg_merge.mk *---'

ERROR: Error 65280 occurred while making
/var/tmp/fst/src/ooo-build/build/src680-m163/vcl/util
make: *** [stamp/build] Error 1
Comment 2 Martin Hollmichel 2006-04-17 10:17:06 UTC
reassign to ooo-build experts.
Comment 3 kendy 2006-04-18 12:27:57 UTC
Hmm, I have no idea about libXau...  Philipp, please, do you think it is really 
needed?  Or is that a misconfiguration of something?  The patch is easy: 
 
--- vcl/util/makefile.mk.orig   2006-03-23 18:38:20.000000000 +0100 
+++ vcl/util/makefile.mk        2006-03-23 18:39:53.000000000 +0100 
 -305,7 +305,7 @@ 
 .ENDIF # ENABLE_PASF 
  
 .IF "$(ENABLE_NAS)" != "" 
-SHL2STDLIBS += -laudio 
+SHL2STDLIBS += -laudio -lXau 
 .IF "$(OS)"=="SOLARIS" 
 # needed by libaudio.a 
 SHL2STDLIBS += -ldl -lnsl -lsocket 
Comment 4 sparcmoz 2006-04-22 14:37:16 UTC
same issue seen in vanilla upstream build m163 (GNU/Linux SPARC)
../unxlngs.pro/slo/pasfsound.o -lvcl680ls -lpsp680ls -lsot680ls -lutl680ls
-ltl680ls -lcomphelp4gcc3 -lucbhelper3gcc3 -luno_cppuhelpergcc3 -luno_cppu
-lvos3gcc3 -luno_sal -Wl,-Bstatic -lXinerama -Wl,-Bdynamic -lsndfile -lportaudio
-laudio -lXext -lSM -lICE -lX11 -ldl -ldl -lpthread -lm -Wl,-Bdynamic
-lstlport_gcc -lstdc++
/home/jim/vanilla/solver/680/unxlngs.pro/lib/libaudio.a(ConnSvr.o): In function
`GetAuthorization':
/home/jim/vanilla/nas/unxlngs.pro/misc/build/nas-1.6/lib/audio/ConnSvr.c:1981:
undefined reference to `XauDisposeAuth'
Comment 5 philipp.lohmann 2006-04-24 09:33:13 UTC
On other Linux platforms (e.g. SuSE 10) 'XauDisposeAuth' is defined within
libX11.so, so -lXau seems to be specific to your platform. One would need to
handle that in the configure script. Kendy, would you know how to achieve that ?

Yet another great advantage of every distribution having to diversify whatever
the cost. :-)
Comment 6 kendy 2006-04-24 11:56:56 UTC
vmiklos: Reassign to you to provide the configure check ;-) 
Comment 7 Miklos Vajna 2006-04-26 10:01:51 UTC
here is a proposed patch:
http://frugalware.org/~vmiklos/patches/ooo-build/libxau.diff
Comment 8 Miklos Vajna 2006-04-26 23:42:20 UTC
BTW, using --with-system-nas also is a usable workaround
Comment 9 Miklos Vajna 2006-05-04 16:15:43 UTC
hm, the situation is a bit strange now, the issue is assigned to me but i can't
push the patch, so could it be assigned to somebody who could review/reject it,
please?

thanks
Comment 10 kendy 2006-05-04 17:42:14 UTC
Well, I can neither - 
http://frugalware.org/~vmiklos/patches/ooo-build/libxau.diff does not exist any 
more :-(  Could you attach to this issue, please? 
Comment 11 Miklos Vajna 2006-05-04 21:03:57 UTC
Created attachment 36273 [details]
patch requested by kendy
Comment 12 bluedwarf 2006-05-20 18:07:22 UTC
m170 still has the same issue. /usr/lib/libX11.a doesn't have "XauDisposeAuth"
and "XauGetBestAuthByAddr" on Debian GNU/Linux unstable. 

=====
% nm /usr/lib/libX11.a | grep Xau
nm: lcDynamic.o: no symbols
         U XauDisposeAuth
         U XauGetBestAuthByAddr
=====

Debian GNU/Linux unstable have already adopted X.org 7.0 instead of 6.9 by
default. According to ChangeLog of X.org, some functions included by libXau and
libXdmcp was separated from libX11.so from version 7.0. This change cause this
issue.

===== http://webcvs.freedesktop.org/xorg/xc/ChangeLog?r1=1.365&r2=1.1587
2005-09-22  Alan Coopersmith  <alan.coopersmith@sun.com>
  	 
  	         * config/cf/X11.tmpl:
  	         * lib/Xau/Imakefile:
  	         * lib/Xdmcp/Imakefile:
  	         Make libXau & libXdmcp default to shared instead of static libraries
  	         to match modular build.   (See fd.o bugzilla #4200.)
=====

For this reason -lXau is not specific to Debian GNU/Linux, but depends on X.org
version. The configure script should evaluate its version and set linkage option
according to the version number. This issue should be resolved before more Linux
distributions will adopt the latest X.org.

vmiklos: I'm not sure but mh, tools project owner, may be appropriate person for
configure script.

Regards, Takashi Nakamoto
Comment 13 Miklos Vajna 2006-05-20 18:33:07 UTC
ok, but what can i do now? :)

the issue was assigned to me to provide a patch, i've provided one but can't
assign the issue back to mh or kendy ;)
Comment 14 Miklos Vajna 2006-08-18 22:58:42 UTC
just wanted to mention that this is still an issue and still can't reassign to
the appropriate person :-/
Comment 15 sparcmoz 2006-09-24 14:46:10 UTC
reassign the requested patch
Comment 16 kendy 2006-10-05 10:26:43 UTC
Looks good to me, I'd say ;-)

rene: Do you have a configure-related CWS where you could commit it, please?
Comment 17 mkretzschmar 2006-10-15 21:48:38 UTC
*** Issue 65789 has been marked as a duplicate of this issue. ***
Comment 18 mkretzschmar 2006-10-15 21:52:34 UTC
What does this mean for running official OOo binaries (not linked with libXau?)
on systems where the symbols are in libXau?
Comment 19 hjs 2006-10-17 18:35:48 UTC
.
Comment 20 Miklos Vajna 2006-10-18 09:59:34 UTC
hm. how should i test this?

probably just starting OOo won't trigger the problem since soffice.bin is not
linked to libvclplug_gen680li.so

thanks
Comment 21 pavel 2006-10-31 11:54:35 UTC
That plugin is loaded dynamically.

What is the status of this issue now?
Comment 22 Miklos Vajna 2006-10-31 13:49:58 UTC
i can still reproduce this problem if the version of XOrg is 7.x

i've attached a fix, but nobody committed it yet
Comment 23 pavel 2006-11-01 13:32:56 UTC
vmiklos:

Is vcl/util/makefile.mk the only place that needs it? I'd be more comfortable to
add it where -lX11 is if it was splited from it...

Anyone using Xorg 7 and can verify this issue?
Comment 24 Miklos Vajna 2006-11-01 13:35:06 UTC
yes, it's the only place

kendy said it looks ok to him
Comment 25 kendy 2006-11-01 14:14:29 UTC
But I am no xorg expert, so please don't take it as an argument ;-) - maybe I 
am completely wrong...
Comment 26 philipp.lohmann 2006-11-01 14:33:05 UTC
Should be ok, since the library that actually needs the Xau functionality is
libaudio.a and that only gets linked to libvclplug_gen* which is SHL2TARGET in
said makefile.

Just my 2 cents.
Comment 27 pavel 2006-11-10 08:20:39 UTC
patch, retarget to 2.2.
Comment 28 mkretzschmar 2006-11-22 11:20:27 UTC
By now, this is very likely a build breaker on Ubuntu 6.06, 6.10, openSUSE
10.2(beta), FC5 and FC6, MEPIS 6, Mandriva 2007, Debian etch (testing) and sid
(unstable)!
Comment 29 rene 2006-11-22 12:03:39 UTC
mkretzschmar: afaik not. IIRC, At least with X 7 it didn't have a problem, no 
idea about 7.1.

In Debian, libX11 is correctzly linked against libXau, making it work.
If libX11 uses libXau functions and is not linked against it it's a libX11 
issue (i.e. the distributions' packages). Not OOo.

Comment 30 sparcmoz 2006-11-23 11:15:33 UTC
@rene: I am uncertain - what do you mean by "making it work"? On debian/unstable this breaks the build, 
(apt-get update again today). 
Comment 31 rene 2006-11-24 13:34:53 UTC
sparcmoz: works for me on Debian unstable (powerpc)
Comment 32 sparcmoz 2006-11-24 19:34:05 UTC
rene: i am just thinking what could be different in our builds... The only thing not "debian" in my case is 
the compiler - my own build of gcc4.1.2preview. Also - do you use system nas or internal build of nas? I 
use the internal build and -lXau is used in there. Could that be relevant?
Comment 33 Miklos Vajna 2006-11-25 12:15:52 UTC
If you build with system nas then you won't hit this bug.
Comment 34 pavel 2007-01-09 14:47:53 UTC
is 2.2 still OK?
Comment 35 hjs 2007-01-09 16:53:31 UTC
added to ause072 - will attach the patch if noone complains...
Comment 36 hjs 2007-01-09 16:54:26 UTC
s/attach/apply/
Comment 37 hjs 2007-01-10 15:08:47 UTC
.
Comment 38 pavel 2007-01-16 20:52:27 UTC
Can anyone who had this issue please verify this task and the patch in ause072?
Comment 39 Miklos Vajna 2007-01-16 21:26:56 UTC
i'm newbie to CWS, if you can show how can i get that patch to test, then i
could test it :)

thanks
Comment 40 jens-heiner.rechtien 2007-01-18 16:39:47 UTC
Verified.
Comment 41 caolanm 2007-06-03 18:32:23 UTC
closed