[PATCH] xprint is broken in xserver git

Drew Parsons dparsons at debian.org
Tue Aug 21 18:24:57 PDT 2007


On Tue, 2007-08-21 at 15:49 +0200, Maarten Maathuis wrote:
> The function of the link flag --as-needed is to prevent unnecesary linking.
> 
> Example: A -> B -> C
> 
> Normally A would link to B and also depend on C, this is ofcource
> unnecesary. In this situation however we do need to link to C, so this
> must be done explicitly. This flag comes in handy when a library ABI
> is changed, minimizing the amount of recompilations needed.

OK :)



> Error message:
> 
> ../../config/libconfig.a(dbus-core.o): In function `teardown':
> dbus-core.c:(.text+0x8a): undefined reference to `dbus_connection_unref'
> ../../config/libconfig.a(hal.o): In function `get_prop_string':
> hal.c:(.text+0x19b): undefined reference to `libhal_device_get_property_string'

There it is, just as I thought - the bug is carried in to Xprt via
libconfig.a.  So I think that makes a "clean" solution (in the sense of
keeping hal/dbus out of Xprint) tricky, since it would imply building
two libconfig.a, one with hal support and one without.  We not want to
go to that kind of trouble, in which case the workaround is to just add
the simple dummy functions, which you did in your patch.

The alternative is to have Xprint (and Xdmx) build their own libconfig.a
locally, and remove $CONFIG_LIB from XPRINT_EXTENSIONS in configure.ac
(and adding -lconfig explcitly to xprint/Makefile.am). This is not
particularly difficult to do, it just means creating some symlinks to
the source files in ./config/.

I'm inclined to prefer the second solution, creating an Xprint-specific
libconfig.a, since that's logically (or aesthetically?) more correct.
I'm not sure about Xdmx, however. Does hal/dbus support make sense in
Xdmx?

Does anyone have a clear preference for one solution over the other? 

Drew

p.s. thanks for the full build log, Łukasz



More information about the xorg mailing list