On Tue, Nov 25, 2014 at 10:36 AM, Niels Möller nisse@lysator.liu.se wrote:
I think it lacked a linker script for hogweed, with symbol version tracking libhogweed's major version rather than libnettle's.
Attached a patch which separates the .map files.
What I now realize is that that mini-gmp mpz_*, gmp_* and mpn_* symbols are not exported in the script that I sent. They could be put unconditionally there, or via a configure variable.
I think it's generally a bit dangerous to make shared libraries with mini-gmp (the result is not promised to be binary compatible with regular builds). Anyone trying that really needs to know what he/she is doing. So I think a sensible default is to disable hogweed symbol versioning in that case, and possibly have a configure option to explicitly specify the linker script to use for each library.
I'm not sure what is the correct path. Disabling the linker script would mean that more symbols will be exported than normally (all internal symbols) and there can be clashes that wouldn't be with the normal library. In any case this is not really related to the version script, it is mostly an issue of having a different soname when nettle-mini is used.
regards, Nikos