summaryrefslogtreecommitdiff
path: root/src/southbridge/amd/cimx
diff options
context:
space:
mode:
authorPatrick Georgi <patrick@georgi-clan.de>2014-11-12 19:11:50 +0100
committerPatrick Georgi <pgeorgi@google.com>2014-11-14 15:12:33 +0100
commit3eefeea9d58ab2896aec7ded7aa1a15e8e9fa72c (patch)
tree5d666431a83a9afae3f0db82ef7e5d1d3dd48ab1 /src/southbridge/amd/cimx
parent77c7ecf73e513d19375d808aee5663e7bb597dd4 (diff)
build system: improve portability
There are too many differences, and calculating relatively large integer using floats might not be the brightest idea anyway. Also avoid relying on ls(1) output format to determine file sizes. Change-Id: I5f96c036737b74e20f525c3dc9edc011ad403662 Signed-off-by: Patrick Georgi <pgeorgi@google.com> Reviewed-on: http://review.coreboot.org/7447 Tested-by: build bot (Jenkins) Reviewed-by: Edward O'Callaghan <eocallaghan@alterapraxis.com> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Diffstat (limited to 'src/southbridge/amd/cimx')
-rw-r--r--src/southbridge/amd/cimx/sb800/Makefile.inc5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/southbridge/amd/cimx/sb800/Makefile.inc b/src/southbridge/amd/cimx/sb800/Makefile.inc
index 95daf70d62..f4a84b7c22 100644
--- a/src/southbridge/amd/cimx/sb800/Makefile.inc
+++ b/src/southbridge/amd/cimx/sb800/Makefile.inc
@@ -72,10 +72,7 @@ SB800_FWM_POSITION=$(shell printf %u $(CONFIG_SB800_FWM_POSITION))
#assume the cbfs header is less than 128 bytes.
ROMSIG_SIZE=16
-SB800_IMC_POSITION_UNALIGN=$(shell echo $(SB800_FWM_POSITION) $(ROMSIG_SIZE) \
- 128 65535 | awk '{printf("%.0f", $$1 + $$2 + $$3 + $$4)}')
-SB800_IMC_POSITION=$(shell echo $(SB800_IMC_POSITION_UNALIGN) \
- | awk '{printf("%.0f", $$1 - $$1 % 65536)}')
+SB800_IMC_POSITION=$(call int-align,$(call add-int,$(SB800_FWM_POSITION) $(ROMSIG_SIZE) 128),65536)
$(obj)/coreboot_SB800_romsig.bin: \
$(call strip_quotes, $(CONFIG_SB800_IMC_FWM_FILE)) \