[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Intend to create an -fPIC library package...

On Mon, Jul 20, 2009 at 11:10:11PM +0200, Christian Hammers wrote:
> Hello
> In the Cc'ed bug report we were asked to created a libmysqld-pic package that
> only contains libmysqld_pic.a which should be compiled with -fPIC.
> As I'm no library expert I gladly follow the recommendation of Policy §10.2
> and ask for comments :) The reason for creating this package was that
> libmysqld.a (the embeddable MySQL server) should be included in other shared
> libraries, like one from Modestas' Amarok package.

If other libraries are including this library, then why is libmysqld
not being provided as a properly-versioned shared object?

I am not convinced that compiling with -fPIC is appropriate here--it's
working around the fact that mysql isn't providing a properly
reusable shared library.  Linking an -fPIC static library (a) with a
shared library (b) will make the contents of (a) part of the exported
interface of (b) because it will by default be added to the dynamic
symbol table unless you take special action with linker scripts.

There are obvious issues with security updates if people are linking
against libmysqld.a, since all libraries linking against it will need
rebuilding if there's a security update.  If it's shared, that won't
normally be required.


  .''`.  Roger Leigh
 : :' :  Debian GNU/Linux             http://people.debian.org/~rleigh/
 `. `'   Printing on GNU/Linux?       http://gutenprint.sourceforge.net/
   `-    GPG Public Key: 0x25BFB848   Please GPG sign your mail.

Attachment: signature.asc
Description: Digital signature

Reply to: