Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 20 Mar 2026 19:22:33 +0000
From:      Shawn Webb <shawn.webb@hardenedbsd.org>
To:        Jessica Clarke <jrtc27@freebsd.org>
Cc:        A FreeBSD User <freebsd@walstatt-de.de>,  Philip Paeps <philip@freebsd.org>, Enji Cooper <ngie@FreeBSD.org>,  "src-committers@freebsd.org" <src-committers@FreeBSD.org>,  "dev-commits-src-all@freebsd.org" <dev-commits-src-all@FreeBSD.org>,  "dev-commits-src-main@freebsd.org" <dev-commits-src-main@FreeBSD.org>
Subject:   Re: git: 14b9955e57cc - main - libcrypto: compile all PIC objects with -DOPENSSL_PIC
Message-ID:  <jw47xnedq4a7wsyu7oprav3sfwkpok5gavohpvlzddtzevrc6i@qraat5cd3vet>
In-Reply-To: <6E6DB2FA-3E78-40B6-BFDB-2BDD240C5CED@freebsd.org>
References:  <69bc9a33.3bd51.5811996c@gitrepo.freebsd.org> <61743F2C-2561-4BAC-81F2-02B8A85B8755@freebsd.org> <20260320201441.333c83c0@thor.sb211.local> <hpmgnwvygm5dvn5q6u7wu7xtqlocopdnoajr4mkou4q5yuypk7@yhn7cfwxc55k> <6E6DB2FA-3E78-40B6-BFDB-2BDD240C5CED@freebsd.org>

index | next in thread | previous in thread | raw e-mail

[-- Attachment #1 --]
On Fri, Mar 20, 2026 at 07:21:11PM +0000, Jessica Clarke wrote:
> On 20 Mar 2026, at 19:17, Shawn Webb <shawn.webb@hardenedbsd.org> wrote:
> 
> > On Fri, Mar 20, 2026 at 08:14:14PM +0100, A FreeBSD User wrote:
> >> Am Tage des Herren Fri, 20 Mar 2026 10:27:47 +0800
> >> Philip Paeps <philip@freebsd.org> schrieb:
> >> 
> >>> On 2026-03-20 08:52:03 (+0800), Enji Cooper wrote:
> >>> 
> >>>> The branch main has been updated by ngie:
> >>>> 
> >>>> URL: 
> >>>> https://cgit.FreeBSD.org/src/commit/?id=14b9955e57cc28b61e785165b9effcbe620edb46
> >>>> 
> >>>> commit 14b9955e57cc28b61e785165b9effcbe620edb46
> >>>> Author:     Enji Cooper <ngie@FreeBSD.org>
> >>>> AuthorDate: 2026-03-19 23:56:41 +0000
> >>>> Commit:     Enji Cooper <ngie@FreeBSD.org>
> >>>> CommitDate: 2026-03-20 00:51:51 +0000
> >>>> 
> >>>>    libcrypto: compile all PIC objects with -DOPENSSL_PIC
> >>>> 
> >>>>    This change modifies the libcrypto PIC objects to always compile 
> >>>> with
> >>>>    `-DOPENSSL_PIC` to restore parity with the upstream build process. 
> >>>> This
> >>>>    ensures that `-DOPENSSL_PIC` is used whenever building the 
> >>>> auxiliary
> >>>>    shared objects. In this case, just the legacy provider (we no 
> >>>> longer
> >>>>    distribute the fips provider).
> >>>> 
> >>>>    MFC after:              2 weeks
> >>>>    Differential Revision:  https://reviews.freebsd.org/D44896  
> >>> 
> >>> This one seems to break the build for me:
> >>> 
> >>> main philip@flatulus:~/freebsd/src % time make -j 16 buildworld |grep 
> >>> error:
> >>> ld: error: relocation R_X86_64_PC32 cannot be used against symbol 
> >>> '__stack_chk_guard'; recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_PC32 cannot be used against symbol 
> >>> '__stack_chk_guard'; recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_PC32 cannot be used against symbol 
> >>> '__stack_chk_guard'; recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_PC32 cannot be used against symbol 
> >>> '__stack_chk_guard'; recompile with -fPIC
> >>> ld: error: relocation R_X86_64_PC32 cannot be used against symbol 
> >>> '__stack_chk_guard'; recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32S cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32S cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: relocation R_X86_64_32 cannot be used against local symbol; 
> >>> recompile with -fPIC
> >>> ld: error: too many errors emitted, stopping now (use --error-limit=0 to 
> >>> see all errors)
> >>> cc: error: linker command failed with exit code 1 (use -v to see 
> >>> invocation)
> >>> make -j 16 buildworld  63.51s user 16.69s system 593% cpu 13.524 total
> >>> grep error:  0.01s user 0.01s system 0% cpu 13.524 total
> >>> 
> >>> Hm... as I type this I wonder if it's just META_MODE weirdness...
> >>> 
> >>> Philip
> >>> 
> >> 
> >> Same here
> > 
> > Appending to CFLAGS rather than PICFLAG resolves the issue. Commit in
> > HardenedBSD coming soon.
> 
> Yeah that’ll stop the PICFLAG?=-fpic from doing anything.
> 
> CFLAGS is wrong though, you want SHARED_CFLAGS, I imagine.

Good catch on the SHARED_CFLAGS. I'll give that a try.

-- 
Shawn Webb
Cofounder / Security Engineer
HardenedBSD

Signal Username:  shawn_webb.74
Tor-ified Signal: +1 303-901-1600 / shawn_webb_opsec.50
https://git.hardenedbsd.org/hardenedbsd/pubkeys/-/raw/master/Shawn_Webb/03A4CBEBB82EA5A67D9F3853FF2E67A277F8E1FA.pub.asc

[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----

iQIzBAABCAAdFiEEA6TL67gupaZ9nzhT/y5nonf44foFAmm9nnkACgkQ/y5nonf4
4fqtBw//fxF5XAUwijmNae5syt9cac8Db1IP68en3rA+bCP+55g6kHQo2czjIT3U
jGVeSaBEkNYOJ3wZUf0MC6YvI0TMY2AcQdxFCqaOUGUsD8AWT6vNDynvUyOOhmOp
C/0ssz+g74mXe6xFxtOThbHQjN7QcMHrEjhcgo0S9s3ZdZIvnFuQV64/XiVOsB60
W/d3PL3KIWxzDppAqsxY8E9hwODQKb+nplb4pG2kNAgDBPS+sGdQUqSO2/jbvGmN
lVIu6jXdmZZBZ3wzazZ7gvBAgU5ZF7h123Pg+sKJet94gWEpBuEow+N0bB/+rjib
PZIcyn5r+e5v19TswHBoKAw2/BDN0SoTy0k20nt3ZELTK1lizni7XexijloSgD+3
9DXDiCnjdo7lGsuHCkV1npJ7rVUD1e2saJawHyNwfK2cVEYHhlpyF1UQu11nDzFb
sbfkx7zjPVLbj5RlVjy6S1N5H5vjL/E3KmKvzYDftT5zTsHaH7u2tjEdJD6MVimH
i2PQKxXeISLnvPulUws+/Mbqg/1XLUvTgo2s7FDwGb+Eq/znywYnuTqzd3CRTcUZ
KYRvf26TgyPHl2h8k9t4qwvYePXdwtkd4RN10Ne5wnHtjWjhgxUH0qfPt2U9boYw
QxOfBNmbzQGSuCBV7fSbx/QIKNU+9eh0sj4HbDU95c57lnghmUY=
=kEWj
-----END PGP SIGNATURE-----
home | help

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