[haiku-development] Re: question on planned build system feature -- 'generated' folder naming scheme

  • From: Ingo Weinhold <ingo_weinhold@xxxxxx>
  • To: haiku-development@xxxxxxxxxxxxx
  • Date: Tue, 03 Feb 2009 02:04:36 +0100

On 2009-02-02 at 15:33:44 [+0100], Matt Madia <mattmadia@xxxxxxxxx> wrote:
> On Sat, Jan 31, 2009 at 1:30 PM, Ingo Weinhold <ingo_weinhold@xxxxxx> wrote:
> > I don't see why we can't add one or two sentences to the usage text
> > explaining how non-default output directories work.
> >
> I'll gladly concede to that.  How's the attached diff look?  Would you
> prefer this created as a ticket?

Thanks, applied in r29128 with minor changes (typo, added some quotation 
marks).

> > I'm fine with working on a more comfortable
> > solution for this use case,
> --snip--
> > After François mentioned that selecting the output directory by build 
> > profile
> > would be nice, I thought a bit about it, and it could be solved by
> > introducing an optional EarlyUserBuildConfig, which would be included 
> > very,
> > well, early. Early enough at least that it could changed HAIKU_OUTPUT_DIR.
> > Depending on what one personally prefers one could do that by build 
> > profile
> > or by some additional parameter (e.g. "x86gcc2").
> 
> Does this seem like what you mean?
> Note, I haven't tested this yet, so there might be some syntax or
> similar errors.
> haiku_src/Jamrules:
> # Main directories used by the build.
> ...
> # include EarlyUserBuildConfig
> {
>     local earlyUserBuildConfig
>         = [ GLOB $(HAIKU_BUILD_RULES_DIR) : EarlyUserBuildConfig ] ;
>     if $(earlyUserBuildConfig) {
>         include $(earlyUserBuildConfig) ;
>     }
> }
> 
> # Cache files for header scanning and jamfile caching
> ...

Yep, something like this, though I would do that before setting all variables 
that use the ouput directory location. I haven't had a closer look yet, but 
it might make sense to include some rules and do some build profile 
processing earlier, so they are already available in the EarlyUserBuildConfig.

> haiku_src/configure:
> remove the existng HAIKU_OUTPUT_DIR from the cat << EOF > $outputDir/Jamfile
> 
> cat << EOF > $(HAIKU_TOP)/build/EarlyUserBuildConfig
> HAIKU_OUTPUT_DIR = ${outputDir}
> EOF

I wouldn't do that. I would leave EarlyUserBuildConfig completely optional. 
Most people won't use it anyway, I guess. If one want to, one can just create 
it.

CU, Ingo

Other related posts: