Re: [gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-22 Thread Luca Barbato
On 09/21/2012 06:06 PM, Zac Medico wrote: On 09/20/2012 10:34 AM, Ambroz Bizjak wrote: The question now is, how should this method for checking --crosscompile be implemented? In particular, we have two options: - Environment variable. If so, how to call it? Possible names are CROSSCOMPILE,

Re: [gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-22 Thread Ambroz Bizjak
Yes, I think this is a good idea, it would allow the dependencies to be expressed nicely as conditions. But I'm not sure how this would be a USE flag. It should behave like one during the build, but it would be best if it was not written into the VDB as such, at least in a way that would be

Re: [gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-22 Thread Zac Medico
On 09/22/2012 09:08 AM, Ambroz Bizjak wrote: Yes, I think this is a good idea, it would allow the dependencies to be expressed nicely as conditions. But I'm not sure how this would be a USE flag. It should behave like one during the build, but it would be best if it was not written into the

[gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-22 Thread Ambroz Bizjak
Zac, I think you misunderstood me here. Crosscompile-only HDEPEND is definitely necessary, I've seen many packages need this. But what I'm suggesting is that we also, and maybe only, need ROOT != / - only HDEPEND dependencies. This means that the dependency would only be required if the package is

Re: [gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-22 Thread Zac Medico
On 09/22/2012 09:48 AM, Ambroz Bizjak wrote: Zac, I think you misunderstood me here. Crosscompile-only HDEPEND is definitely necessary, I've seen many packages need this. But what I'm suggesting is that we also, and maybe only, need ROOT != / - only HDEPEND dependencies. This means that the

Re: [gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-22 Thread Ambroz Bizjak
Yes, sysroot is much better, thanks :) So, does anyone have any objections to just having a sysroot condition and no --crosscompile or FEATURES=crosscompile? Essentially, there's still tc-is-cross-compiler, if you want the real cross-compile semantic, and sysroot conditional dependencies cover

Re: [gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-22 Thread Zac Medico
On 09/22/2012 10:14 AM, Ambroz Bizjak wrote: Yes, sysroot is much better, thanks :) So, does anyone have any objections to just having a sysroot condition and no --crosscompile or FEATURES=crosscompile? Essentially, there's still tc-is-cross-compiler, if you want the real cross-compile

Re: [gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-21 Thread Zac Medico
On 09/20/2012 10:34 AM, Ambroz Bizjak wrote: The question now is, how should this method for checking --crosscompile be implemented? In particular, we have two options: - Environment variable. If so, how to call it? Possible names are CROSSCOMPILE, GENTOO_CROSSCOMPILE, PORTAGE_CROSSCOMPILE,

[gentoo-dev] RFC: method of checking for cross compilation from ebuild functions

2012-09-20 Thread Ambroz Bizjak
I'm working on some EAPI extensions with the goal of making Portage more powerful for cross-compilation. See https://bugs.gentoo.org/show_bug.cgi?id=317337 Currently, it's come down to the following: - A new dependency type HDEPEND for packages which must be installed in / at build time. With