summaryrefslogtreecommitdiff
path: root/toolchain
diff options
context:
space:
mode:
Diffstat (limited to 'toolchain')
-rw-r--r--toolchain/binutils/Makefile6
-rw-r--r--toolchain/gcc/Makefile10
-rw-r--r--toolchain/gdb/Makefile6
-rw-r--r--toolchain/glibc/Makefile8
-rw-r--r--toolchain/gmp/Makefile6
-rw-r--r--toolchain/mpfr/Makefile6
6 files changed, 33 insertions, 9 deletions
diff --git a/toolchain/binutils/Makefile b/toolchain/binutils/Makefile
index fb6beccab..c3dc45b07 100644
--- a/toolchain/binutils/Makefile
+++ b/toolchain/binutils/Makefile
@@ -10,6 +10,10 @@ ifeq ($(ADK_LINUX_64),y)
CONFOPTS+= --enable-64-bit-bfd
endif
+ifeq (${ADK_MAKE_PARALLEL},y)
+BINUTILS_MAKEOPTS+= -j${ADK_MAKE_JOBS}
+endif
+
$(WRKBUILD)/.headers:
$(WRKBUILD)/.configured:
(cd $(WRKBUILD); \
@@ -31,7 +35,7 @@ $(WRKBUILD)/.configured:
touch $@
$(WRKBUILD)/.compiled: $(WRKBUILD)/.configured
- $(MAKE) -C $(WRKBUILD) all
+ $(MAKE) ${BINUTILS_MAKEOPTS} -C $(WRKBUILD) all
touch $@
$(WRKBUILD)/.installed: $(WRKBUILD)/.compiled
diff --git a/toolchain/gcc/Makefile b/toolchain/gcc/Makefile
index 0fc5edc1d..1cf762810 100644
--- a/toolchain/gcc/Makefile
+++ b/toolchain/gcc/Makefile
@@ -36,6 +36,10 @@ ifeq ($(ADK_TARGET_LIB_UCLIBC),y)
GCC_CONFOPTS+= --disable-tls
endif
+ifeq (${ADK_MAKE_PARALLEL},y)
+GCC_MAKEOPTS+= -j${ADK_MAKE_JOBS}
+endif
+
include ${TOPDIR}/mk/buildhlp.mk
GCC_BUILD_DIR_MINIMAL:= $(WRKBUILD)-minimal
@@ -57,7 +61,7 @@ $(GCC_BUILD_DIR_MINIMAL)/.configured:
$(GCC_BUILD_DIR_MINIMAL)/.compiled: $(GCC_BUILD_DIR_MINIMAL)/.configured
PATH=$(TARGET_PATH) \
- $(MAKE) -C $(GCC_BUILD_DIR_MINIMAL) all-gcc
+ $(MAKE) ${GCC_MAKEOPTS} -C $(GCC_BUILD_DIR_MINIMAL) all-gcc
touch $@
$(WRKBUILD)/.headers: $(GCC_BUILD_DIR_MINIMAL)/.compiled
@@ -86,7 +90,7 @@ $(GCC_BUILD_DIR_INITIAL)/.configured:
$(GCC_BUILD_DIR_INITIAL)/.compiled: $(GCC_BUILD_DIR_INITIAL)/.configured
PATH=$(TARGET_PATH) \
- $(MAKE) -C $(GCC_BUILD_DIR_INITIAL) all-gcc all-target-libgcc
+ $(MAKE) ${GCC_MAKEOPTS} -C $(GCC_BUILD_DIR_INITIAL) all-gcc all-target-libgcc
touch $@
$(WRKBUILD)/.configured: $(GCC_BUILD_DIR_INITIAL)/.compiled
@@ -109,7 +113,7 @@ $(GCC_BUILD_DIR_FINAL)/.configured:
$(WRKBUILD)/.compiled: $(GCC_BUILD_DIR_FINAL)/.configured
PATH=$(TARGET_PATH) \
- $(MAKE) -C $(GCC_BUILD_DIR_FINAL) all
+ $(MAKE) ${GCC_MAKEOPTS} -C $(GCC_BUILD_DIR_FINAL) all
touch $@
$(WRKBUILD)/.installed: $(WRKBUILD)/.compiled
diff --git a/toolchain/gdb/Makefile b/toolchain/gdb/Makefile
index 0d6b7cb48..9571f2a9f 100644
--- a/toolchain/gdb/Makefile
+++ b/toolchain/gdb/Makefile
@@ -7,6 +7,10 @@ include Makefile.inc
include ${TOPDIR}/mk/buildhlp.mk
+ifeq (${ADK_MAKE_PARALLEL},y)
+GDB_MAKEOPTS+= -j${ADK_MAKE_JOBS}
+endif
+
$(WRKBUILD)/.headers:
$(WRKBUILD)/.configured:
(cd $(WRKBUILD); \
@@ -33,7 +37,7 @@ $(WRKBUILD)/.configured:
touch $@
$(WRKBUILD)/.compiled:
- $(MAKE) -C $(WRKBUILD) CFLAGS="-fPIC ${HOSTCFLAGS}"
+ $(MAKE) ${GDB_MAKEOPTS} -C $(WRKBUILD) CFLAGS="-fPIC ${HOSTCFLAGS}"
touch $@
$(WRKBUILD)/.installed:
diff --git a/toolchain/glibc/Makefile b/toolchain/glibc/Makefile
index 2058c41d4..a45fe6fb6 100644
--- a/toolchain/glibc/Makefile
+++ b/toolchain/glibc/Makefile
@@ -43,6 +43,10 @@ ifeq ($(ADK_TARGET_NO_FPU),y)
GLIBC_CONFOPTS+= --without-fp
endif
+ifeq (${ADK_MAKE_PARALLEL},y)
+GLIBC_MAKEOPTS+= PARALLELMFLAGS="-j${ADK_MAKE_JOBS}"
+endif
+
GLIBC_BUILD_DIR_INITIAL:= ${WRKDIR}/$(PKG_NAME)-$(PKG_VERSION)-headers
GLIBC_BUILD_DIR_FINAL:= ${WRKDIR}/$(PKG_NAME)-$(PKG_VERSION)-final
@@ -58,7 +62,7 @@ $(WRKBUILD)/.headers_configure:
$(WRKBUILD)/.headers: $(WRKBUILD)/.headers_configure
mkdir -p $(TOOLCHAIN_SYSROOT)/usr/lib
- $(MAKE) -C $(GLIBC_BUILD_DIR_INITIAL) \
+ $(MAKE) ${GLIBC_MAKEOPTS} -C $(GLIBC_BUILD_DIR_INITIAL) \
cross-compiling=yes \
install_root=$(TOOLCHAIN_SYSROOT) \
install-headers
@@ -78,7 +82,7 @@ $(WRKBUILD)/.configured:
touch $@
$(WRKBUILD)/.compiled:
- ${GLIBC_ENV} $(MAKE) -C $(GLIBC_BUILD_DIR_FINAL) all
+ ${GLIBC_ENV} $(MAKE) ${GLIBC_MAKEOPTS} -C $(GLIBC_BUILD_DIR_FINAL) all
touch $@
$(WRKBUILD)/.installed:
diff --git a/toolchain/gmp/Makefile b/toolchain/gmp/Makefile
index bbe26f14d..c31e76483 100644
--- a/toolchain/gmp/Makefile
+++ b/toolchain/gmp/Makefile
@@ -6,6 +6,10 @@ include ../rules.mk
include Makefile.inc
include ${TOPDIR}/mk/buildhlp.mk
+ifeq (${ADK_MAKE_PARALLEL},y)
+GMP_MAKEOPTS+= -j${ADK_MAKE_JOBS}
+endif
+
$(WRKBUILD)/.headers:
$(WRKBUILD)/.configured:
(cd $(WRKBUILD); \
@@ -20,7 +24,7 @@ $(WRKBUILD)/.configured:
touch $@
$(WRKBUILD)/.compiled: $(WRKBUILD)/.configured
- $(MAKE) -C $(WRKBUILD) all
+ $(MAKE) ${GMP_MAKEOPTS} -C $(WRKBUILD) all
touch $@
$(WRKBUILD)/.installed: $(WRKBUILD)/.compiled
diff --git a/toolchain/mpfr/Makefile b/toolchain/mpfr/Makefile
index f74f0199f..d16729a70 100644
--- a/toolchain/mpfr/Makefile
+++ b/toolchain/mpfr/Makefile
@@ -7,6 +7,10 @@ include $(TOPDIR)/toolchain/gmp/Makefile.inc
include Makefile.inc
include ${TOPDIR}/mk/buildhlp.mk
+ifeq (${ADK_MAKE_PARALLEL},y)
+MPFR_MAKEOPTS+= -j${ADK_MAKE_JOBS}
+endif
+
$(WRKBUILD)/.headers:
$(WRKBUILD)/.configured:
(cd $(WRKBUILD); \
@@ -21,7 +25,7 @@ $(WRKBUILD)/.configured:
touch $@
$(WRKBUILD)/.compiled: $(WRKBUILD)/.configured
- $(MAKE) -C $(WRKBUILD) all
+ $(MAKE) ${MPFR_MAKEOPTS} -C $(WRKBUILD) all
touch $@
$(WRKBUILD)/.installed: $(WRKBUILD)/.compiled