[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Gary E. Miller
Fri, 6 Jan 2023 15:53:10 -0800
On Fri, 6 Jan 2023 14:14:01 -0800 (PST)
Fred Wright <firstname.lastname@example.org> wrote:
> On Thu, 5 Jan 2023, Gary E. Miller wrote:
> > On Thu, 5 Jan 2023 19:49:50 -0800 (PST) Fred Wright
> > <email@example.com> wrote:
> >> On Thu, 5 Jan 2023, Gary E. Miller wrote:
> >>> As this only applies to OpenBSD 7, I'll make the test window
> >>> really short. Test now. If there is silence I'll release Friday.
> >> There are a number of puzzling things about this issue, though I
> >> guess with the narrow applicability they can wait until after the
> >> release to sort out.
> > Questions are always in order. What is puzzling?
> Position-independent code has always been required for shared-library
> code, on all platforms.
No, not always. And -fPIC is only a few years old.
> This is already handled by using
Except in Hal's case.
> In fact, I think the only difference between
> SharedObject() and StaticObject() is the use of the appropriate PIC
> option(s) in the former.
Maybe, maybe not. Your idea would be common to all platforms, but
this particular issue only shows up on Hal's OpenBSD7. Probably related
to the fact that scons fails to determine the cc version in use, so
can not decide what flags to us.
> Ordinarily, executable code doesn't need to be position-independent,
> but probably changes in the presence of aggressive ASLR (i.e., ASLR
> applied to code as well as data). And I wouldn't put it past OpenBSD
> to make aggressive ASLR mandatory.
Regardless, scons is supposed to just do the right thing, but it fails to.
Only in this one particular case.
> At least in GCC,
Let us not go yak shearing. The problem at hand is clang 13.0.0
on OpenBSD 7. Only. GCC woks fine. Other distros work fine.
> If it's necessary to get extra flags to the linker on a link-only
> command, then I believe that's supposed to be done via LINKFLAGS, not
When, at the last minute, a rifle shot 2 line patch works, I'll take it.
Feel free to some up with a better solution after release.
Gary E. Miller Rellim 109 NW Wilmington Ave., Suite E, Bend, OR 97703
firstname.lastname@example.org Tel:+1 541 382 8588
Veritas liberabit vos. -- Quid est veritas?
"If you can't measure it, you can't improve it." - Lord Kelvin
Description: OpenPGP digital signature