summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Roth <gaumless@gmail.com>2015-06-21 12:38:42 -0600
committerMartin Roth <gaumless@gmail.com>2015-06-24 06:15:10 +0200
commit3950966e327c8420e6dffa2efcd9181bd7bc3527 (patch)
tree73bb817e4787ba541d3df15da57fc076b62fd4c7
parent32c965170512a62659f54fe46d53117a847f97f3 (diff)
downloadcoreboot-3950966e327c8420e6dffa2efcd9181bd7bc3527.tar.xz
crossgcc/Makefile: Allow making toolchains using multiple cores
I looked for a way to pass the 'make crossgcc -j8' on to buildgcc, but didn't find a way to get that value directly. MAKEFLAGS turns -j8 into a jobserver variable. Instead, this patch allows the number of CPUs to be set on the command line through a variable instead. Example: 'make crossgcc BUILDJOBS=8' Change-Id: I37608cdb4549226cb7ff8c3ff6d9f4773acf6b0b Signed-off-by: Martin Roth <gaumless@gmail.com> Reviewed-on: http://review.coreboot.org/10620 Tested-by: build bot (Jenkins) Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net> Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
-rw-r--r--util/crossgcc/Makefile24
1 files changed, 12 insertions, 12 deletions
diff --git a/util/crossgcc/Makefile b/util/crossgcc/Makefile
index 2104a8954a..ae9177c32b 100644
--- a/util/crossgcc/Makefile
+++ b/util/crossgcc/Makefile
@@ -1,46 +1,46 @@
all: build-i386 build-x64 build-armv7a build-aarch64 build-mips build-riscv
build-i386:
- bash ./buildgcc -G -p i386-elf
+ bash ./buildgcc -G -p i386-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
build-x64:
- bash ./buildgcc -G -p x86_64-elf
+ bash ./buildgcc -G -p x86_64-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
build-armv7a:
- bash ./buildgcc -G -p armv7a-eabi
+ bash ./buildgcc -G -p armv7a-eabi $(if $(BUILDJOBS),-j $(BUILDJOBS))
build-aarch64:
- bash ./buildgcc -G -p aarch64-elf
+ bash ./buildgcc -G -p aarch64-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
build-mips:
- bash ./buildgcc -G -p mipsel-elf
+ bash ./buildgcc -G -p mipsel-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
build-riscv:
- bash ./buildgcc -G -p riscv-elf
+ bash ./buildgcc -G -p riscv-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
.PHONY: build-i386-without-gdb
build-i386-without-gdb:
- bash ./buildgcc -p i386-elf
+ bash ./buildgcc -p i386-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
.PHONY: build-x64-without-gdb
build-x64-without-gdb:
- bash ./buildgcc -p x86_64-elf
+ bash ./buildgcc -p x86_64-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
.PHONY: build-armv7a-without-gdb
build-armv7a-without-gdb:
- bash ./buildgcc -p armv7a-eabi
+ bash ./buildgcc -p armv7a-eabi $(if $(BUILDJOBS),-j $(BUILDJOBS))
.PHONY: build-aarch64-without-gdb
build-aarch64-without-gdb:
- bash ./buildgcc -p aarch64-elf
+ bash ./buildgcc -p aarch64-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
.PHONY: build-mips-without-gdb
build-mips-without-gdb:
- bash ./buildgcc -p mipsel-elf
+ bash ./buildgcc -p mipsel-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
.PHONY: build-riscv-without-gdb
build-riscv-without-gdb:
- bash ./buildgcc -p riscv-elf
+ bash ./buildgcc -p riscv-elf $(if $(BUILDJOBS),-j $(BUILDJOBS))
clean:
rm -rf xgcc