Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 25 Feb 2021 16:21:58 -0800
From:      John Kennedy <warlock@phouka.net>
To:        "Greg 'groggy' Lehey" <grog@freebsd.org>
Cc:        Ed Maste <emaste@freebsd.org>, FreeBSD Current <freebsd-current@freebsd.org>
Subject:   Re: HEADS-UP: PIE enabled by default on main
Message-ID:  <YDg/JkvXdCXNa1Hk@phouka1.phouka.net>
In-Reply-To: <20210225231028.GB69550@eureka.lemis.com>
References:  <CAPyFy2CyxG=Bj8T22ixW3=E3dv6mPoZRwJ_VSN%2BTwky95rUYYw@mail.gmail.com> <20210225231028.GB69550@eureka.lemis.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Fri, Feb 26, 2021 at 10:10:28AM +1100, Greg 'groggy' Lehey wrote:
> On Thursday, 25 February 2021 at 15:58:07 -0500, Ed Maste wrote:
> > As of 9a227a2fd642 (main-n245052) base system binaries are now built
> > as position-independent executable (PIE) by default, for 64-bit
> > architectures. ...
> >
> > If you track -CURRENT and normally build WITHOUT_CLEAN you'll need to
> > do one initial clean build -- either run `make cleanworld` or set
> > WITH_CLEAN=yes.
> 
> This details worries me.  How compatible are PIE executables with
> non-PIE executables?  Can I run PIE executables on older systems?  Can
> I run older executables on a PIE system?

  Assuming we're basically talking about WITH_PIE=YES in /etc/src.conf, I've 
been doing this since 2020/08/04 (12.1 -> 12.2 -> 13/14).  I don't think
I've associated any problems with PIE.  I've certainly got lots of non-PIE
ports linked against base libraries (but ELF 64-bit LSB shared object, vs
ELF 64-bit LSB pie executable).  The E in PIE is executable.

  Not sure if Ed Maste just wants to make sure that all the executables
are rebuilt as PIE (vs hit-and-miss) or there is a sneaker corner-case that
he knows about.

  I can't say that I've had an opportunity to try the scenario I think you're
looking at.  My "older" crossovers are +/- a __FreeBSD_version bump.




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