Closed ffontaine closed 1 year ago
@ffontaine Can you share the output of pkg-config --static --libs openssl
and pkg-config --libs openssl
on that machine? Is the problem that -latomic is listed after both -lssl and -lcrypto?
Here is the output:
output/host/bin/pkg-config --static --libs openssl
-Loutput/host/bin/../sparc-buildroot-linux-uclibc/sysroot/usr/lib -lssl -Loutput/host/bin/../sparc-buildroot-linux-uclibc/sysroot/usr/lib -lz -pthread -latomic -lcrypto -lz -pthread -latomic
The issue is indeed that -latomic
is listed after both -lssl
and -lcrypto
. But the issue is not only related to -latomic
. There is the same issue with -lz
and -pthread
. As you know, when building statically all the dependencies should be listed in the correct order.
Yes, it is unfortunate that the dependencies aren't just listed once at the end.
Do not use
AX_APPEND_FLAG
as it will break static builds by removing duplicates such as-lz
or-latomic
which are needed by-lssl
and-lcrypto
. This will fix the following build failure with sparc which needs-latomic
:Fixes: