Raul Rangel has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/34240 )
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Makefile: Pass .xcompile into genbuild_h
I'm moving the .xcompile file into the $(obj) directory so we can leave the source pristine. We need to pass the location of .xcompile into genbuild_h.sh.
BUG=b:112267918 TEST=Ran genbuild_h with and without an .xcompile and verified it was passed.
Change-Id: I8b3a75b478fad92a0b09246f0a00b0580f8c4aef Signed-off-by: Raul E Rangel rrangel@chromium.org --- M Makefile.inc M util/genbuild_h/genbuild_h.sh 2 files changed, 9 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/40/34240/1
diff --git a/Makefile.inc b/Makefile.inc index 28f1363..b1553a2 100644 --- a/Makefile.inc +++ b/Makefile.inc @@ -497,7 +497,7 @@ # Report new `build.ht` as dependency if `build.h` differs. build_h_check := \ export $(foreach exp,$(build_h_exports),$(exp)="$($(exp))"); \ - util/genbuild_h/genbuild_h.sh >$(build_h)t 2>/dev/null; \ + util/genbuild_h/genbuild_h.sh .xcompile >$(build_h)t 2>/dev/null; \ cmp -s $(build_h)t $(build_h) >/dev/null 2>&1 || echo $(build_h)t
$(build_h): $$(shell $$(build_h_check)) diff --git a/util/genbuild_h/genbuild_h.sh b/util/genbuild_h/genbuild_h.sh index c264b74..bffdc01 100755 --- a/util/genbuild_h/genbuild_h.sh +++ b/util/genbuild_h/genbuild_h.sh @@ -22,6 +22,13 @@ export LC_ALL=C export TZ=UTC0
+XCOMPILE=$1 + +if [ -z "$XCOMPILE" ]; then + echo "usage: $0 <xcompile>" >&2 + exit 1 +fi + # $1: format string get_git_head_data() { LANG= git log --no-show-signature -1 --format="format:$1" 2>/dev/null || \ @@ -53,7 +60,7 @@ }
IASL=util/crossgcc/xgcc/bin/iasl -eval $(grep ^IASL:= .xcompile 2>/dev/null | sed s,:=,=,) +eval $(grep ^IASL:= "$XCOMPILE" 2>/dev/null | sed s,:=,=,)
#Print out the information that goes into build.h printf "/* build system definitions (autogenerated) */\n"
Patrick Georgi has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34240 )
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Patch Set 2: Code-Review+2
Paul Menzel has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34240 )
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Patch Set 2: Code-Review+1
Martin Roth has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34240 )
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Patch Set 3:
(2 comments)
https://review.coreboot.org/c/coreboot/+/34240/3//COMMIT_MSG Commit Message:
https://review.coreboot.org/c/coreboot/+/34240/3//COMMIT_MSG@9 PS3, Line 9: I'm moving the .xcompile file into the $(obj) directory Unrelated to this particular change, but please make sure that all of the payload makefiles know about this change as well please. I think several of those look for the .xcompile file in the root coreboot directory and might regenerate it there if it's not present.
https://review.coreboot.org/c/coreboot/+/34240/3/util/genbuild_h/genbuild_h.... File util/genbuild_h/genbuild_h.sh:
https://review.coreboot.org/c/coreboot/+/34240/3/util/genbuild_h/genbuild_h.... PS3, Line 27: if [ -z "$XCOMPILE" ]; then add a --help option?
if [ -z "$XCOMPILE" ] || [ "$1" = "--help" ]]; then
Hello Paul Menzel, build bot (Jenkins), Martin Roth, Patrick Georgi,
I'd like you to reexamine a change. Please visit
https://review.coreboot.org/c/coreboot/+/34240
to look at the new patch set (#4).
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Makefile: Pass .xcompile into genbuild_h
I'm moving the .xcompile file into the $(obj) directory so we can leave the source pristine. We need to pass the location of .xcompile into genbuild_h.sh.
BUG=b:112267918 TEST=Ran genbuild_h with and without an .xcompile and verified it was passed.
Change-Id: I8b3a75b478fad92a0b09246f0a00b0580f8c4aef Signed-off-by: Raul E Rangel rrangel@chromium.org --- M Makefile.inc M util/genbuild_h/genbuild_h.sh 2 files changed, 9 insertions(+), 2 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/40/34240/4
Raul Rangel has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34240 )
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Patch Set 4:
(2 comments)
https://review.coreboot.org/c/coreboot/+/34240/3//COMMIT_MSG Commit Message:
https://review.coreboot.org/c/coreboot/+/34240/3//COMMIT_MSG@9 PS3, Line 9: I'm moving the .xcompile file into the $(obj) directory
Unrelated to this particular change, but please make sure that all of the payload makefiles know abo […]
All of the payloads generate their own .xcompile file
https://review.coreboot.org/c/coreboot/+/34240/3/util/genbuild_h/genbuild_h.... File util/genbuild_h/genbuild_h.sh:
https://review.coreboot.org/c/coreboot/+/34240/3/util/genbuild_h/genbuild_h.... PS3, Line 27: if [ -z "$XCOMPILE" ]; then
add a --help option? […]
Done
Martin Roth has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/34240 )
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Patch Set 4: Code-Review+2
Martin Roth has submitted this change and it was merged. ( https://review.coreboot.org/c/coreboot/+/34240 )
Change subject: Makefile: Pass .xcompile into genbuild_h ......................................................................
Makefile: Pass .xcompile into genbuild_h
I'm moving the .xcompile file into the $(obj) directory so we can leave the source pristine. We need to pass the location of .xcompile into genbuild_h.sh.
BUG=b:112267918 TEST=Ran genbuild_h with and without an .xcompile and verified it was passed.
Change-Id: I8b3a75b478fad92a0b09246f0a00b0580f8c4aef Signed-off-by: Raul E Rangel rrangel@chromium.org Reviewed-on: https://review.coreboot.org/c/coreboot/+/34240 Tested-by: build bot (Jenkins) no-reply@coreboot.org Reviewed-by: Martin Roth martinroth@google.com --- M Makefile.inc M util/genbuild_h/genbuild_h.sh 2 files changed, 9 insertions(+), 2 deletions(-)
Approvals: build bot (Jenkins): Verified Martin Roth: Looks good to me, approved
diff --git a/Makefile.inc b/Makefile.inc index e560338..3c3088d 100644 --- a/Makefile.inc +++ b/Makefile.inc @@ -497,7 +497,7 @@ # Report new `build.ht` as dependency if `build.h` differs. build_h_check := \ export $(foreach exp,$(build_h_exports),$(exp)="$($(exp))"); \ - util/genbuild_h/genbuild_h.sh >$(build_h)t 2>/dev/null; \ + util/genbuild_h/genbuild_h.sh .xcompile >$(build_h)t 2>/dev/null; \ cmp -s $(build_h)t $(build_h) >/dev/null 2>&1 || echo $(build_h)t
$(build_h): $$(shell $$(build_h_check)) diff --git a/util/genbuild_h/genbuild_h.sh b/util/genbuild_h/genbuild_h.sh index c264b74..8da68ba 100755 --- a/util/genbuild_h/genbuild_h.sh +++ b/util/genbuild_h/genbuild_h.sh @@ -22,6 +22,13 @@ export LC_ALL=C export TZ=UTC0
+XCOMPILE=$1 + +if [ -z "$XCOMPILE" ] || [ "$1" = "--help" ]; then + echo "usage: $0 <xcompile>" >&2 + exit 1 +fi + # $1: format string get_git_head_data() { LANG= git log --no-show-signature -1 --format="format:$1" 2>/dev/null || \ @@ -53,7 +60,7 @@ }
IASL=util/crossgcc/xgcc/bin/iasl -eval $(grep ^IASL:= .xcompile 2>/dev/null | sed s,:=,=,) +eval $(grep ^IASL:= "$XCOMPILE" 2>/dev/null | sed s,:=,=,)
#Print out the information that goes into build.h printf "/* build system definitions (autogenerated) */\n"