summaryrefslogtreecommitdiff
path: root/Makefile.mk
diff options
context:
space:
mode:
authorMaximilian Brune <maximilian.brune@9elements.com>2024-07-02 23:19:04 +0200
committerFelix Held <felix-coreboot@felixheld.de>2024-07-08 12:58:01 +0000
commit4a8d73d6a4af625f97af908911478d481b95b461 (patch)
treecb2dfbe41357b22a4f73366da8f52a361c348390 /Makefile.mk
parent75703772d1163701537e71c5b933465387e209e9 (diff)
Makefile.mk: Remove bc dependency
bc was added as dependency in commit 229e021110 ("Makefile.inc: Add left shift macro") bc is not stated as dependency in our docs (e.g. package installation). If you don't have bc installed you can easily get false positives on coreboot builds. For example you build a mainboard and coreboot tells you the build succeeded, even though you don't have bc installed. This patch is from julius comment on CB:21601. Signed-off-by: Maximilian Brune <maximilian.brune@9elements.com> Change-Id: I6ab4bc2bd7a45e84b923d4fe7ec473e6c7db2146 Reviewed-on: https://review.coreboot.org/c/coreboot/+/83313 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de>
Diffstat (limited to 'Makefile.mk')
-rw-r--r--Makefile.mk2
1 files changed, 1 insertions, 1 deletions
diff --git a/Makefile.mk b/Makefile.mk
index 68fc8c988e..592365e924 100644
--- a/Makefile.mk
+++ b/Makefile.mk
@@ -178,7 +178,7 @@ _int-multiply2=$(shell expr $(call _toint,$1) \* $(call _toint,$2))
int-multiply=$(if $(filter 1,$(words $1)),$(strip $1),$(call int-multiply,$(call _int-multiply2,$(word 1,$1),$(word 2,$1)) $(wordlist 3,$(words $1),$1)))
int-divide=$(if $(filter 1,$(words $1)),$(strip $1),$(shell expr $(call _toint,$(word 1,$1)) / $(call _toint,$(word 2,$1))))
int-remainder=$(if $(filter 1,$(words $1)),$(strip $1),$(shell expr $(call _toint,$(word 1,$1)) % $(call _toint,$(word 2,$1))))
-int-shift-left=$(shell echo "$(call _toint,$(word 1, $1)) * (2 ^ $(call _toint,$(word 2, $1)))" | bc)
+int-shift-left=$(shell expr $(call _toint,$(word 1, $1)) << $(call _toint,$(word 2, $1)))
int-lt=$(if $(filter 1,$(words $1)),$(strip $1),$(shell expr $(call _toint,$(word 1,$1)) \< $(call _toint,$(word 2,$1))))
int-gt=$(if $(filter 1,$(words $1)),$(strip $1),$(shell expr $(call _toint,$(word 1,$1)) \> $(call _toint,$(word 2,$1))))
int-eq=$(if $(filter 1,$(words $1)),$(strip $1),$(shell expr $(call _toint,$(word 1,$1)) = $(call _toint,$(word 2,$1))))