Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 11 Apr 2023 20:13:31 +0000
From:      bugzilla-noreply@freebsd.org
To:        ports-bugs@FreeBSD.org
Subject:   [Bug 270769] databases/postgresql13-client fails to build WITH_LLVM_BINUTILS (LLVM strip)
Message-ID:  <bug-270769-7788@https.bugs.freebsd.org/bugzilla/>

next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D270769

            Bug ID: 270769
           Summary: databases/postgresql13-client fails to build
                    WITH_LLVM_BINUTILS (LLVM strip)
           Product: Ports & Packages
           Version: Latest
          Hardware: Any
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: Individual Port(s)
          Assignee: pgsql@FreeBSD.org
          Reporter: emaste@freebsd.org
            Blocks: 258872
             Flags: maintainer-feedback?(pgsql@FreeBSD.org)
          Assignee: pgsql@FreeBSD.org

>From the exp-run in PR258872
https://pkg-status.freebsd.org/gohan05/data/mainamd64PR258872-default/2023-=
04-05_14h36m44s/logs/errors/postgresql13-client-13.10.log

=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D
STRIPPROG=3D'strip -x' /bin/sh ../../../config/install-sh -c -m 644 -s libp=
q.a
'/wrkdirs/usr/ports/databases/postgresql13-client/work/stage/usr/local/lib/=
libpq.a'
strip: error:
'/wrkdirs/usr/ports/databases/postgresql13-client/work/stage/usr/local/lib/=
_inst.20299_':
not stripping symbol '.L.str' because it is named in a relocation
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D

pgsql's build has requested to strip all non-global symbols (strip -x), but
there is at least one non-global symbol that in fact cannot be stripped bec=
ause
it is referenced by a relocation.

Both GNU strip and ELF Tool Chain strip silently handle this case (and just
retain the local symbol), but LLVM strip is stricter and emits an error upon
request to strip a non-removable local symbol.

There is an LLVM ticket open for this at
https://github.com/llvm/llvm-project/issues/47468. It probably makes sense =
for
LLVM strip to behave the same as GNU and ELF Tool Chain strip, but I believe
pgsql should just not use strip -x when there are symbols that cannot be
stripped. My suggestion would be to consider just not stripping .a archives.


Referenced Bugs:

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D258872
[Bug 258872] [exp-run] WITH_LLVM_BINUTILS
--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-270769-7788>