[OE-core] [PATCH] perl: use parallel build where possible
Alexander Kanavin
alexander.kanavin at linux.intel.com
Fri Mar 2 15:32:20 UTC 2018
While the upstream just runs a number of make tasks hardcoded to a single thread
in succession, we can add '-j n_threads' to a few of them. The benefit
is real: on my machine the do_compile() time goes from 250 seconds to about 90.
Signed-off-by: Alexander Kanavin <alexander.kanavin at linux.intel.com>
---
meta/recipes-devtools/perl/perl_5.24.1.bb | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/meta/recipes-devtools/perl/perl_5.24.1.bb b/meta/recipes-devtools/perl/perl_5.24.1.bb
index f13a63a80a3..67cc8d668db 100644
--- a/meta/recipes-devtools/perl/perl_5.24.1.bb
+++ b/meta/recipes-devtools/perl/perl_5.24.1.bb
@@ -184,6 +184,11 @@ do_compile() {
# Fix to avoid recursive substitution of path
sed -i -e 's|(@libpath, ".*"|(@libpath, "${STAGING_LIBDIR}"|g' cpan/ExtUtils-MakeMaker/lib/ExtUtils/Liblist/Kid.pm
+ # Build auxillary make targets (more/more2/more3/more4) in parallel.
+ # Unfortunately the core target will race, and so remains single-threaded.
+ # Still, this cuts do_compile() time from 250 seconds to about 90.
+ sed -i -e 's, more, ${PARALLEL_MAKE} more,g' Cross/Makefile
+
cd Cross
oe_runmake perl LD="${CCLD}"
}
--
2.15.1
More information about the Openembedded-core
mailing list