Opened 16 years ago
Closed 16 years ago
#3424 closed enhancement (fixed)
Configure : conditionally output HAIKU_ADD_ALTERNATIVE_GCC_LIBS = 1
Reported by: | mmadia | Owned by: | bonefish |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | Build System | Version: | R1/pre-alpha1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
Another build automation enhancement :
Similar to Changeset [29161], modify configure to conditionally output HAIKU_ADD_ALTERNATIVE_GCC_LIBS = 1 to a *BuildConfig file residing in HAIKU_OUTPUT_DIR
I'm willing to implement this. Please give me an idea of what would be acceptable.
Attachments (2)
Change History (7)
comment:1 by , 16 years ago
comment:2 by , 16 years ago
The attached configure.3424.diff was tested with
../haiku/configure
../haiku/configure --alternative-gcc-output-dir ../gcc4
both commands were tested with and without a pre-existing HAIKU_OUTPUT_DIR/build/UserBuildConfig
note: configure was being run outside of haiku's source directory
comment:3 by , 16 years ago
Generally I'm not very fond of editing user files programmatically. In this case I think the better alternative is to set the variable in the generated BuildConfig. That would still allow it to be unset in the UserBuildConfig.
follow-up: 5 comment:4 by , 16 years ago
configure.3424-rev2.diff creates a new variable , addAlternativeGCCLibs=0 and sets it =1 when --alternative-gcc-output-dir is detected.
This is added to ${outputDir}/build/BuildConfig: HAIKU_ADD_ALTERNATIVE_GCC_LIBS ?= "${addAlternativeGCCLibs}" ;
On a side note, is there any reason why ${alternativeGCCOutputDir} is not encapsulated in double quotes?
comment:5 by , 16 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Replying to mmadia:
configure.3424-rev2.diff creates a new variable , addAlternativeGCCLibs=0 and sets it =1 when --alternative-gcc-output-dir is detected.
This is added to ${outputDir}/build/BuildConfig: HAIKU_ADD_ALTERNATIVE_GCC_LIBS ?= "${addAlternativeGCCLibs}" ;
Applied in hrev29607, but adjusted a bit. Since HAIKU_ADD_ALTERNATIVE_GCC_LIBS is only tested for non-emptiness, setting it to 0 wouldn't work.
On a side note, is there any reason why ${alternativeGCCOutputDir} is not encapsulated in double quotes?
ATM path names with spaces aren't really supported anyway, so that doesn't really make a difference.
This script shows one method for adding HAIKU_ADD_ALTERNATIVE_GCC_LIBS = 1 to HAIKU_OUTPUT_DIR/UserBuildConfig.
I've yet to attempt integrating this into the build system.