This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: --with-build-sysroot, et. al.

DJ Delorie wrote:
The logic looks OK.  But, thinking ahead, given that we currently
support this:

	./configure --prefix=...
	make prefix=...

Yet this:

	./configure --with-build-sysroot=...

It seems clumsy.  I wonder if SYSROOT_FOR_TARGET is a bettern choice,
or even just "sysroot" if this is going to become popular enough.

We already have a "--sysroot" configure option, so we can't use that. The reason I chose "build" is that this is a property of the build machine; it's the location of the (target) sysroot on the build machine. The "--sysroot" option is what I would call the host sysroot; it's the location of the (target) sysroot on the host machine. And, yes, I concede that all of thse sysroots actually contain target files, so it's confusing!

And if this sets the sysroot where gcc assumes things are installed,

It sets the location of the sysroot where gcc assumes things are installed *during the build process*; after that point, GCC uses whatever was provided with --sysroot.

Another thought is... can we specify sysroot as a relative directory
off prefix?  I mean, --with-sysroot='$(prefix)/...', so that changing
prefix also changes sysroot?  I expect the logic for that would be
more complex though.

Yes. That would be nice, but it's, as you say, another level of hair. And, it wouldn't particular help me, because the issue at hand is that $prefix isn't accurate; we're configuring with one prefix and installing with another.

I'm OK with you checking it in and changing the names later, though,
if this is blocking anyone.

Thanks! I'll give you a few hours to reply to this mail, in case I've clarified things in some scary way, and then check in. And, of course, if you want me to change something after that point, I will.

Mark Mitchell
CodeSourcery, LLC
(916) 791-8304

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]