Shared libraries nightmare :-(

From: Carlos Moreno (moreno_at_mochima_dot_com_at_xx.xxx)
Date: 05/29/05


Date: Sun, 29 May 2005 16:20:47 -0400


Hi,

After checking out the Libraries HOWTO and some (old) postings on
the subject, I'm still struggling with this.

I have a library that I created (in C++) for my own use. Since the
library is intended to be used by many different applications on
multi-user Linux servers, I compiled the whole thing as a shared
library, and copied a bunch of .h files to /usr/include (and also
copied the .so file to /usr/lib)

Now, I just made some improvements that break binary compatibility.

I compiled it, and as soon as I run one of the old, already-compiled
applications, hell breaks loose (well, ok, I just get a "relocation
error: undefined symbol: _ZN10etcetcetc_ )

Is there a way that I can solve the problem cleanly?

Right now, the only obvious solution that comes to mind is to forget
about the shared stuff (both shared library and the .h files) and
use the new version as a completely local and statically-compiled
fragment of code.

Is there a better way? Could I create a new version and have things
more or less automatically do the right thing?

Thanks,

Carlos

--


Relevant Pages

  • Re: Can MS listen to customers?
    ... IE is comprised of a set of libraries that other applications use. ... a HUGE portion of even a minimal install of Windows (or even in ... For Windows, Notepad, Paint, IE, OE, msconfig, Wordpad, Hearts, NT ...
    (microsoft.public.windowsxp.general)
  • [Full-Disclosure] Overflow in SunRPC-derived XDR libraries
    ... Applications using vulnerable implementations of SunRPC-derived XDR ... BSD-derived libraries with XDR/RPC routines ... Note that this vulnerability is similar to, but distinct from, ... Because SunRPC-derived XDR libraries are used by a variety of vendors ...
    (Full-Disclosure)
  • Re: Reading great code
    ... not aware of any mission-critical applications that use .NET, ... and libraries) or no operating system at all (except perhaps ... The C language, for example, can't be used ... more than Java is a prototyping platform. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: Reading great code
    ... aware of any mission-critical applications that use .NET, and the more critical applications use specialist operating systems (and compilers, and libraries) or no operating system at all, for just the reason you've spotted. ... And even when the languages used do have code libraries available, those libraries are generally not used unless they have been specifically designed with mission-critical applications in mind. ...
    (microsoft.public.dotnet.languages.csharp)
  • Re: [Lit.] Buffer overruns
    ... >>safe application difficult and secure applications impossible. ... >>libraries can be shrunk to fit and C's RTL is one of those. ... applications it might be (I suspect the performance-sensitive apps are ...
    (sci.crypt)