Re: Shared library linking to Static library

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

 



> Your requirements are self-contradictory.  On the one hand, you want
> the changes done to global variables of libstatic by the application
> to be reflected in libdynamic.so, and on the other hand you want to be
> able to use two incompatible versions of libstatic.
>
> It's traditional on this list to help people do what they want
> regardless of whether it's a good idea, but in your case I think it
> would be the wrong thing to do.  It is far better in the long run to
> tell you the truth:
>
> Your design is completely broken.
>
> Ian Taylor, being a nice guy, has been trying to help you do what you
> want, but it's not in your real best interests.  As you said,
> "Maintainability will be a problem.".  Well, yes, it will.  If you
> carry out this plan you'll end up with something difficult to maintain
> and horrible to debug.

Thanks for all your inputs. I understand your anguish. It is not that
I'm denying any of the approaches proposed. Unfortunately our
requirements looks to be complex.

Recently, we introduced restriction of symbols in libdynamic library
to export necessary symbols to the application. This is necessary to
avoid symbol conflicts of libdynamic with another library. Before
introduction of restriction of symbols, there used to be only one copy
of libstatic in the memory used by both application and libdynamic
library. After introduction of restriction of symbols in libdynamic
library we noticed that this creates two copies of libstatic in the
memory. Libstatic library provides some common functional
implementation like Debug module which is used by both application and
libdynamic library. The "Debug" value in application and libdynamic
library at the run-time needs to be same.

Thanks,
Roopa

[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux