This is an automated email from the git hooks/post-receive script.

guillem pushed a commit to branch main
in repository dpkg.

View the commit online:
https://git.dpkg.org/cgit/dpkg/dpkg.git/commit/?id=6cdeaa5c8f3bee847ff79c2d30e3cae70480c882

commit 6cdeaa5c8f3bee847ff79c2d30e3cae70480c882 (HEAD -> main)
Author: Guillem Jover <[email protected]>
AuthorDate: Sun Feb 12 23:54:45 2023 +0100

    build: Fix version script linker support detection
    
    When the linker uses --no-undefined-version either specified by the user
    or as the default behavior (such as with newer clang >= 16 releases),
    a missing symbol definition will cause a linker error if that symbol is
    listed in the version script.
---
 m4/dpkg-linker.m4 | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/m4/dpkg-linker.m4 b/m4/dpkg-linker.m4
index d3abb3087..8c62c21f4 100644
--- a/m4/dpkg-linker.m4
+++ b/m4/dpkg-linker.m4
@@ -51,7 +51,11 @@ AC_DEFUN([DPKG_LINKER_VERSION_SCRIPT], [
     save_LDFLAGS=$LDFLAGS
     LDFLAGS="$LDFLAGS -Wl,--version-script=conftest.map"
     AC_LINK_IFELSE([
-      AC_LANG_PROGRAM([], [])
+      AC_LANG_PROGRAM([[
+extern int symbol(void);
+int symbol(void) { return 0; }
+]], [[
+]])
     ], [
       dpkg_cv_version_script=yes
     ], [

-- 
Dpkg.Org's dpkg

Reply via email to