[SCM] Samba Shared Repository - branch master updated

Andreas Schneider asn at samba.org
Tue Feb 15 12:32:01 UTC 2022


The branch, master has been updated
       via  3bc00dfdd6f bootstrap: Install mold linker on Fedora 35
       via  d409c23832c bootstrap: If the mold linker is available prefer it over gold
       via  2b9917d7a3c builtools: Make abi_gen.sh less prone to errors
      from  17d792e9aa3 ctdb-tests: Iterate protocol tests internally

https://git.samba.org/?p=samba.git;a=shortlog;h=master


- Log -----------------------------------------------------------------
commit 3bc00dfdd6f3541b02eeaa718db49c2838a27e53
Author: Andreas Schneider <asn at samba.org>
Date:   Sun Feb 13 12:08:57 2022 +0100

    bootstrap: Install mold linker on Fedora 35
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Alexander Bokovoy <ab at samba.org>
    
    Autobuild-User(master): Andreas Schneider <asn at cryptomilk.org>
    Autobuild-Date(master): Tue Feb 15 12:31:43 UTC 2022 on sn-devel-184

commit d409c23832c89e014e86f3f09a3601032b163d80
Author: Andreas Schneider <asn at samba.org>
Date:   Sun Feb 13 12:01:47 2022 +0100

    bootstrap: If the mold linker is available prefer it over gold
    
    The gold linker will be deprecated soon. However we got a new linker called
    mold:
    
    https://github.com/rui314/mold/
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Alexander Bokovoy <ab at samba.org>

commit 2b9917d7a3cb88cf48517e4a93a94fa3ca6ff3d9
Author: Andreas Schneider <asn at samba.org>
Date:   Mon Feb 14 07:59:52 2022 +0100

    builtools: Make abi_gen.sh less prone to errors
    
    The mold linker has more hidden symbols and we would need to filter them out
    with nm, where objdump tells us which symbols are actually hidden. So we just
    need to filter out whatever is hidden.
    
    The use of awk makes it also easier to get what we want.
    
    Signed-off-by: Andreas Schneider <asn at samba.org>
    Reviewed-by: Alexander Bokovoy <ab at samba.org>

-----------------------------------------------------------------------

Summary of changes:
 .gitlab-ci-main.yml                              | 2 +-
 bootstrap/config.py                              | 8 ++++++++
 bootstrap/generated-dists/centos7/Dockerfile     | 2 ++
 bootstrap/generated-dists/centos8s/Dockerfile    | 2 ++
 bootstrap/generated-dists/debian10/Dockerfile    | 2 ++
 bootstrap/generated-dists/debian11/Dockerfile    | 2 ++
 bootstrap/generated-dists/fedora34/Dockerfile    | 2 ++
 bootstrap/generated-dists/fedora35/Dockerfile    | 2 ++
 bootstrap/generated-dists/fedora35/bootstrap.sh  | 1 +
 bootstrap/generated-dists/fedora35/packages.yml  | 1 +
 bootstrap/generated-dists/opensuse151/Dockerfile | 2 ++
 bootstrap/generated-dists/opensuse152/Dockerfile | 2 ++
 bootstrap/generated-dists/ubuntu1804/Dockerfile  | 2 ++
 bootstrap/generated-dists/ubuntu2004/Dockerfile  | 2 ++
 bootstrap/sha1sum.txt                            | 2 +-
 buildtools/scripts/abi_gen.sh                    | 9 +++++++--
 16 files changed, 39 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/.gitlab-ci-main.yml b/.gitlab-ci-main.yml
index 8f5c0581cf9..441878df949 100644
--- a/.gitlab-ci-main.yml
+++ b/.gitlab-ci-main.yml
@@ -42,7 +42,7 @@ variables:
   # Set this to the contents of bootstrap/sha1sum.txt
   # which is generated by bootstrap/template.py --render
   #
-  SAMBA_CI_CONTAINER_TAG: 751901cf8356d45e7027b23a60e7a8179e014b98
+  SAMBA_CI_CONTAINER_TAG: bac18584d47ffc1acb5a697d83f2232598b6afbf
   #
   # We use the ubuntu1804 image as default as
   # it matches what we have on sn-devel-184.
diff --git a/bootstrap/config.py b/bootstrap/config.py
index 9abef5074d0..8bcb9ddbb26 100644
--- a/bootstrap/config.py
+++ b/bootstrap/config.py
@@ -131,6 +131,7 @@ PKGS = [
     ('', 'libtirpc-devel'),  # for <rpc/rpc.h> header on fedora
     ('', 'rpcsvc-proto-devel'), # for <rpcsvc/rquota.h> header
     ('mawk', 'gawk'),
+    ('', 'mold'),
 
     ('python3', 'python3'),
     ('python3-cryptography', 'python3-cryptography'), # for krb5 tests
@@ -354,6 +355,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
@@ -457,6 +460,7 @@ RPM_DISTS = {
             'liburing-devel': '',   # not available
             'python3-setproctitle': 'python36-setproctitle',
             'tracker-devel': '', # do not install
+            'mold': '',
         }
     },
     'centos8s': {
@@ -471,6 +475,7 @@ RPM_DISTS = {
             'perl-Test-Base': 'perl-Test-Simple',
             'perl-FindBin': '',
             'liburing-devel': '', # not available yet, Add me back, once available!
+            'mold': '',
         }
     },
     'fedora34': {
@@ -482,6 +487,7 @@ RPM_DISTS = {
             'perl-FindBin': '',
             'python3-iso8601': 'python3-dateutil',
             'libtracker-sparql-2.0-dev': '',  # only tracker 3.x is available
+            'mold': '',
         }
     },
     'fedora35': {
@@ -524,6 +530,7 @@ RPM_DISTS = {
             'libtasn1-tools': '', # asn1Parser is part of libtasn1
             'mingw64-gcc': '', # doesn't exist
             'liburing-devel': '',   # not available
+            'mold': '',
         }
     },
     'opensuse152': {
@@ -554,6 +561,7 @@ RPM_DISTS = {
             'quota-devel': '',
             'glusterfs-api-devel': '',
             'libtasn1-tools': '', # asn1Parser is part of libtasn1
+            'mold': '',
         }
     }
 }
diff --git a/bootstrap/generated-dists/centos7/Dockerfile b/bootstrap/generated-dists/centos7/Dockerfile
index 2f171ad1c62..3b43da9216d 100644
--- a/bootstrap/generated-dists/centos7/Dockerfile
+++ b/bootstrap/generated-dists/centos7/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/centos8s/Dockerfile b/bootstrap/generated-dists/centos8s/Dockerfile
index 1c932f58a94..80a2f099026 100644
--- a/bootstrap/generated-dists/centos8s/Dockerfile
+++ b/bootstrap/generated-dists/centos8s/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/debian10/Dockerfile b/bootstrap/generated-dists/debian10/Dockerfile
index a7141db7e17..c3ef8cef539 100644
--- a/bootstrap/generated-dists/debian10/Dockerfile
+++ b/bootstrap/generated-dists/debian10/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/debian11/Dockerfile b/bootstrap/generated-dists/debian11/Dockerfile
index 6a16324f201..cfd184a1d89 100644
--- a/bootstrap/generated-dists/debian11/Dockerfile
+++ b/bootstrap/generated-dists/debian11/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/fedora34/Dockerfile b/bootstrap/generated-dists/fedora34/Dockerfile
index 0ce89448a5f..6e28a7440bd 100644
--- a/bootstrap/generated-dists/fedora34/Dockerfile
+++ b/bootstrap/generated-dists/fedora34/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/fedora35/Dockerfile b/bootstrap/generated-dists/fedora35/Dockerfile
index c9aa524b831..e66eb84d9f3 100644
--- a/bootstrap/generated-dists/fedora35/Dockerfile
+++ b/bootstrap/generated-dists/fedora35/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/fedora35/bootstrap.sh b/bootstrap/generated-dists/fedora35/bootstrap.sh
index de5a9670601..0d8a3366ab9 100755
--- a/bootstrap/generated-dists/fedora35/bootstrap.sh
+++ b/bootstrap/generated-dists/fedora35/bootstrap.sh
@@ -67,6 +67,7 @@ dnf install -y \
     lmdb-devel \
     make \
     mingw64-gcc \
+    mold \
     ncurses-devel \
     openldap-devel \
     pam-devel \
diff --git a/bootstrap/generated-dists/fedora35/packages.yml b/bootstrap/generated-dists/fedora35/packages.yml
index 749f30dfc0e..b4a5ec40ab9 100644
--- a/bootstrap/generated-dists/fedora35/packages.yml
+++ b/bootstrap/generated-dists/fedora35/packages.yml
@@ -56,6 +56,7 @@ packages:
   - lmdb-devel
   - make
   - mingw64-gcc
+  - mold
   - ncurses-devel
   - openldap-devel
   - pam-devel
diff --git a/bootstrap/generated-dists/opensuse151/Dockerfile b/bootstrap/generated-dists/opensuse151/Dockerfile
index 5a5fd645700..fa3745b5802 100644
--- a/bootstrap/generated-dists/opensuse151/Dockerfile
+++ b/bootstrap/generated-dists/opensuse151/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/opensuse152/Dockerfile b/bootstrap/generated-dists/opensuse152/Dockerfile
index 3d79adcb07d..65de9438e5b 100644
--- a/bootstrap/generated-dists/opensuse152/Dockerfile
+++ b/bootstrap/generated-dists/opensuse152/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/ubuntu1804/Dockerfile b/bootstrap/generated-dists/ubuntu1804/Dockerfile
index 21686560ad9..a66dc3f2324 100644
--- a/bootstrap/generated-dists/ubuntu1804/Dockerfile
+++ b/bootstrap/generated-dists/ubuntu1804/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/generated-dists/ubuntu2004/Dockerfile b/bootstrap/generated-dists/ubuntu2004/Dockerfile
index f94e8801aad..7ae6a93143f 100644
--- a/bootstrap/generated-dists/ubuntu2004/Dockerfile
+++ b/bootstrap/generated-dists/ubuntu2004/Dockerfile
@@ -15,6 +15,8 @@ RUN /tmp/bootstrap.sh && /tmp/locale.sh
 
 # if ld.gold exists, force link it to ld
 RUN set -x; LD=$(which ld); LD_GOLD=$(which ld.gold); test -x $LD_GOLD && ln -sf $LD_GOLD $LD && test -x $LD && echo "$LD is now $LD_GOLD"
+# if ld.mold exists, force link it to ld (prefer mold over gold! ;-)
+RUN set -x; LD=$(which ld); LD_MOLD=$(which ld.mold); test -x $LD_MOLD && ln -sf $LD_MOLD $LD && test -x $LD && echo "$LD is now $LD_MOLD"
 
 # make test can not work with root, so we have to create a new user
 RUN useradd -m -U -s /bin/bash samba && \
diff --git a/bootstrap/sha1sum.txt b/bootstrap/sha1sum.txt
index ba31d4aff3c..aa96502dd76 100644
--- a/bootstrap/sha1sum.txt
+++ b/bootstrap/sha1sum.txt
@@ -1 +1 @@
-751901cf8356d45e7027b23a60e7a8179e014b98
+bac18584d47ffc1acb5a697d83f2232598b6afbf
diff --git a/buildtools/scripts/abi_gen.sh b/buildtools/scripts/abi_gen.sh
index 6dd6d321f77..ddb0a7cc36f 100755
--- a/buildtools/scripts/abi_gen.sh
+++ b/buildtools/scripts/abi_gen.sh
@@ -10,9 +10,14 @@ cat <<EOF
 set height 0
 set width 0
 EOF
-nm "$SHAREDLIB" | cut -d' ' -f2- | egrep '^[BDGTRVWS]' | grep -v @ | egrep -v ' (__bss_start|_edata|_init|_fini|_end)' | cut -c3- | sort | while read s; do
+
+# On older linker versions _init|_fini symbols are not hidden.
+objdump --dynamic-syms "${SHAREDLIB}" | \
+    awk '$0 !~ /.hidden/ {if ($2 == "g" && $3 ~ /D(F|O)/ && $4 ~ /(.bss|.rodata|.text)/) print $NF}' | \
+    sort | \
+    while read -r s; do
     echo "echo $s: "
-    echo p $s
+    echo p "${s}"
 done
 ) > $GDBSCRIPT
 


-- 
Samba Shared Repository



More information about the samba-cvs mailing list