This is the mail archive of the
mailing list for the GCC project.
Re: [Patch,fortran] PR 27740 Symbol versioning for libgfortran
- From: Janne Blomqvist <Janne dot Blomqvist at tkk dot fi>
- To: Thomas Koenig <Thomas dot Koenig at online dot de>
- Cc: gfortran <fortran at gcc dot gnu dot org>, gcc-patches <gcc-patches at gcc dot gnu dot org>
- Date: Sun, 05 Nov 2006 18:38:09 +0200
- Subject: Re: [Patch,fortran] PR 27740 Symbol versioning for libgfortran
- References: <454C89C3.email@example.com> <20061105093720.GA24783@meiner.onlinehome.de>
Thomas Koenig wrote:
just two questions (which I hope can be answered by a quick pointer
to relevant documentation):
If this patch is applied, and I change the interface to a library
- What do I need to do?
I put some notes on http://gcc.gnu.org/wiki/SymbolVersioning
- How can I make sure I don't forget to do whatever needs doing?
Well, I don't have any foolproof rules of thumb.
But if you, say, forget to add a new symbol to the map file, test cases
that use said functionality won't link since by default all symbols are
If you change an interface, you need to figure out how to keep the old
interface around in the library. Either by using different symbol names,
or by using the asm trickery explained in the wiki page.
Is there some automated test?
Not that I know of. The following can be done, but I don't know if it's
possible/reasonable to bend dejagnu to do it.
If you change an interface (compatible or incompatible):
* Old code should continue to work with the new library.
* New code should refuse to run with the old library (without symbol
versioning, the program fails at runtime when trying to access the new
symbol for the first time, with versioning the check happens at startup).