build: pass -no-undefined properly
PATCH 1/2 build: pass -no-undefined properly
From: Ross Burton <[email protected]>
-no-undefined was added to the libell.la LDFLAGS in commit 8391d72d, back in 2012, as part of adding versioning. I believe there was some confusion here as passing -no-undefined to libtool is different to passing -no-undefined to the linker. The former changes libtool's behaviour on Windows hosts related to static libraries, the latter will warn if symbols are used but not defined.
--- Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Makefile.am +1 -1
@@ -141,7 +141,7 @@ ell_libell_la_SOURCES = $(linux_headers) \ ell/icmp6.c \ ell/icmp6-private.h -ell_libell_la_LDFLAGS = -no-undefined \ +ell_libell_la_LDFLAGS = -Wl,--no-undefined \ -Wl,--version-script=$(top_srcdir)/ell/ell.sym \ -version-info $(ELL_CURRENT):$(ELL_REVISION):$(ELL_AGE)
Signature · 1 line
2.28.0
PATCH 2/2 build: don't check for or use libdl
From: Ross Burton <[email protected]>
Commit e129cb4 removed the plugin interface entirely, so there's no need to look for dlopen() or pass -ldl when building.
--- configure.ac | 3 --- ell/ell.pc.in | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-)
configure.ac +0 -3
@@ -108,9 +108,6 @@ AC_CHECK_FUNC(timerfd_create, dummy=yes, AC_CHECK_FUNC(epoll_create, dummy=yes, AC_MSG_ERROR(epoll support is required)) -AC_CHECK_LIB(dl, dlopen, dummy=yes, - AC_MSG_ERROR(dynamic linking loader is required)) - AC_CHECK_HEADERS(linux/types.h linux/if_alg.h) AC_ARG_ENABLE(glib, AC_HELP_STRING([--enable-glib],
ell/ell.pc.in +1 -1
@@ -6,5 +6,5 @@ includedir=@includedir@ Name: ELL Description: Embedded Linux library Version: @VERSION@ -Libs: -L${libdir} -lell -ldl +Libs: -L${libdir} -lell Cflags: -I${includedir}
Signature · 1 line
2.28.0
Hi Ross,
Quoted 8 lines · Ross Burton
From: Ross Burton <[email protected]>
-no-undefined was added to the libell.la LDFLAGS in commit
8391d72d, back in 2012, as part of adding versioning. I believe there was some confusion here as passing -no-undefined to libtool is different to passing -no-undefined to the linker. The former changes libtool's behaviour on Windows hosts related to static libraries, the latter will warn if symbols are used but not defined.
Quoted 4 lines
--- Makefile.am | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Both applied, thanks.
Regards,
-Denis