From c8d629e7956397b1492423762bc95fc8236514c1 Mon Sep 17 00:00:00 2001 From: Jose Diaz de Grenu Date: Mon, 26 Feb 2018 11:41:36 +0100 Subject: [PATCH] qtwebengine: fix compilation when using 1 core From python 2.x to python 3.x, the '/' operator changed from integer division to float division. Hence, when using one core, 'makejobs' was being evaluated to 0.5. That caused the evaluation below (makejobs == 0) to return False (0), therefore PARALLEL_MAKE was evaluated to '-j 0' and the compilation failed because the 'j' parameter must be strictly postive. Replace the operator by the integer div operator in python 3.x '//'. https://jira.digi.com/browse/DEL-5769 Signed-off-by: Jose Diaz de Grenu --- meta-digi-dey/recipes-qt/qt5/qtwebengine_%.bbappend | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/meta-digi-dey/recipes-qt/qt5/qtwebengine_%.bbappend b/meta-digi-dey/recipes-qt/qt5/qtwebengine_%.bbappend index 00823ef42..44fc66554 100644 --- a/meta-digi-dey/recipes-qt/qt5/qtwebengine_%.bbappend +++ b/meta-digi-dey/recipes-qt/qt5/qtwebengine_%.bbappend @@ -6,7 +6,7 @@ LDFLAGS += "-Wl,--no-keep-memory" # To avoid the OOM killer, decrease parallel make jobs for this specific recipe. python __anonymous () { - makejobs = int(d.getVar('PARALLEL_MAKE', True).split()[1]) / 2 + makejobs = int(d.getVar('PARALLEL_MAKE', True).split()[1]) // 2 d.setVar("PARALLEL_MAKE", "-j %d" % (makejobs, 1)[makejobs == 0]) } export NINJAFLAGS = "${PARALLEL_MAKE}"