Closed orbea closed 1 year ago
Hello, For testing some regresses call internal functions those are not exported from shared libraries. To cope with this, regresses are linked with static libraries that does not have export functionality. If Makefile.am indicates linking with .la files, regresses are linked with shared libraries. That is why Makefile.am is written to link with .a under the .libs/ dirs.
The internal functions are not public API and explicitly hidden (not exported), and those should not be described in Symbols.list.
I think building static libraries are required to run regresses.
As I was making the patch I realized why they were not exported as you described and stopped before completing it for that reason. However it is common practice to not build or install static libraries in many linux distros and if possible I would really appreciate if make check
worked with --disable-static
.
The difference with slibtool is that -export-symbols
is a no-op in slibtool, this should be fixed there.
The issue with --disable-static
could be fixed with PRs https://github.com/libressl-portable/openbsd/pull/132 and https://github.com/libressl-portable/portable/pull/765.
The difference with slibtool is that
-export-symbols
is a no-op in slibtool, this should be fixed there.
This is fixed in the slibtool main
branch which now supports both -export-symbols
and -export-symbols-regex
.
OS
gentoo
libressl: https://github.com/libressl-portable/portable/commit/5c7021517a6d7675276d3715f44ebef9f09ca0a7When doing
make check
with--disable-static
it will fail because of the following lines.https://github.com/libressl-portable/portable/blob/5c7021517a6d7675276d3715f44ebef9f09ca0a7/tests/Makefile.am#L15-L17
--disable-static
was used there are no static archives to link with and they should use the.la
files instead..libs
. That directory is for internal use by the libtool implementation where slibtool is more strict.I fixed it with this patch.
However this exposes a new issue for GNU libtool only.
The problem is many of the tests fail with undefined references which are missing from the
Symbols.list
files from the libcrypto, libssl and libtls directories in theopenbsd
repo where adding all of them is no trivial task.For example here is an incomplete patch where I started that.
Slibtool entirely avoids this issue and correctly passes all the tests by not passing the
-version-script
andlibcrypto.ver
,libssl.ver
andlibtls.ver
files to the compiler. I am not yet sure the reason why slibtool does this, but perhaps getting rid of these files altogether is the simple solution?