Prepare for EXTRA_OEMAKE = "" in bitbake.conf
cover Prepare for EXTRA_OEMAKE = "" in bitbake.conf
This series (sent only to openembedded-core) fixes various recipes that rely on the current default value ofEXTRA_OEMAKE = "-e MAKEFLAGS=" to explicitly set that value in the hope that bitbake.conf can set EXTRA_OEMAKE = "" in the future.
With these patches applied and bitbake.conf setting EXTRA_OEMAKE = "", I was able to build "bitbake world" for qemux86, qemuarm, qemuppc and qemumips successfully. I plan to do more build testing and some actual runtime testing before submitting the change to bitbake.conf.
It's highly likely that such a change will break recipes in meta-oe and other layers too. I hope to do some testing with meta-oe soon.
The affected recipes are:
meta/recipes-bsp/apmd/apmd_3.2.2-15.bb meta/recipes-bsp/libacpi/libacpi_0.2.bb meta/recipes-bsp/pciutils/pciutils_3.4.1.bb meta/recipes-connectivity/openssl/openssl.inc meta/recipes-devtools/dmidecode/dmidecode_3.0.bb meta/recipes-devtools/fdisk/gptfdisk_1.0.1.bb meta/recipes-devtools/perl/perl-native_5.22.1.bb meta/recipes-devtools/perl/perl_5.22.1.bb meta/recipes-extended/ed/ed_1.9.bb meta/recipes-extended/iputils/iputils_s20151218.bb meta/recipes-extended/pigz/pigz.inc meta/recipes-extended/stat/stat_3.3.bb meta/recipes-extended/sysklogd/sysklogd.inc meta/recipes-extended/unzip/unzip_6.0.bb meta/recipes-gnome/gtk-theme-torturer/gtk-theme-torturer_git.bb meta/recipes-support/ptest-runner/ptest-runner_2.0.bb
Mike.
PATCH 1/15 openssl: Explicitly set EXTRA_OEMAKE as required
The openssl recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-connectivity/openssl/openssl.inc | 1 + 1 file changed, 1 insertion(+)
meta/recipes-connectivity/openssl/openssl.inc +1 -0
@@ -32,6 +32,7 @@ CFLAG_mtx-2 := "${@'${CFLAG}'.replace('-O2', '')}" export DIRS = "crypto ssl apps" export EX_LIBS = "-lgcc -ldl" export AS = "${CC} -c" +EXTRA_OEMAKE = "-e MAKEFLAGS=" inherit pkgconfig siteinfo multilib_header ptest
Signature · 1 line
2.1.4
PATCH 2/15 pciutils: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThe openssl recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-bsp/pciutils/pciutils_3.4.1.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-bsp/pciutils/pciutils_3.4.1.bb +1 -1
@@ -38,7 +38,7 @@ export SBINDIR = "${sbindir}" export SHAREDIR = "${datadir}" export MANDIR = "${mandir}" -EXTRA_OEMAKE += "${PCI_CONF_FLAG}" +EXTRA_OEMAKE = "-e MAKEFLAGS= ${PCI_CONF_FLAG}" # The configure script breaks if the HOST variable is set HOST[unexport] = "1"
Signature · 1 line
2.1.4
PATCH 3/15 perl: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweFrom: Mike Crowe <[email protected]>
This recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-devtools/perl/perl-native_5.22.1.bb | 2 ++ meta/recipes-devtools/perl/perl_5.22.1.bb | 2 ++ 2 files changed, 4 insertions(+)
meta/recipes-devtools/perl/perl-native_5.22.1.bb +2 -0
@@ -1,5 +1,7 @@ require perl.inc +EXTRA_OEMAKE = "-e MAKEFLAGS=" + SRC_URI += "\ file://Configure-multilib.patch \ file://perl-configpm-switch.patch \
meta/recipes-devtools/perl/perl_5.22.1.bb +2 -0
@@ -87,6 +87,8 @@ export PERLHOSTLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/" export PERL_LIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/" export PERL_ARCHLIB = "${STAGING_LIBDIR_NATIVE}/perl-native/perl/${PV}/" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + # LDFLAGS for shared libraries export LDDLFLAGS = "${LDFLAGS} -shared"
Signature · 1 line
2.1.4
PATCH 4/15 apmd: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-bsp/apmd/apmd_3.2.2-15.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-bsp/apmd/apmd_3.2.2-15.bb +2 -0
@@ -37,6 +37,8 @@ INITSCRIPT_PARAMS = "defaults" SYSTEMD_SERVICE_${PN} = "apmd.service" SYSTEMD_AUTO_ENABLE = "disable" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + do_compile() { # apmd doesn't use whole autotools. Just libtool for installation oe_runmake "LIBTOOL=${STAGING_BINDIR_CROSS}/${HOST_SYS}-libtool" apm apmd
Signature · 1 line
2.1.4
PATCH 5/15 libacpi: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-bsp/libacpi/libacpi_0.2.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-bsp/libacpi/libacpi_0.2.bb +1 -1
@@ -23,7 +23,7 @@ inherit lib_package COMPATIBLE_HOST = '(x86_64|i.86).*-(linux|freebsd.*)' CFLAGS += "-fPIC" -EXTRA_OEMAKE += 'STRIP="echo"' +EXTRA_OEMAKE = '-e MAKEFLAGS= STRIP="echo"' TARGET_CC_ARCH += "${LDFLAGS}"
Signature · 1 line
2.1.4
PATCH 6/15 dmidecode: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-devtools/dmidecode/dmidecode_3.0.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-devtools/dmidecode/dmidecode_3.0.bb +2 -0
@@ -7,6 +7,8 @@ SRC_URI = "${SAVANNAH_NONGNU_MIRROR}/dmidecode/${BP}.tar.xz" COMPATIBLE_HOST = "(i.86|x86_64|aarch64|arm|powerpc|powerpc64).*-linux" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + do_install() { oe_runmake DESTDIR="${D}" install }
Signature · 1 line
2.1.4
PATCH 7/15 gptfdisk: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-devtools/fdisk/gptfdisk_1.0.1.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-devtools/fdisk/gptfdisk_1.0.1.bb +2 -0
@@ -13,6 +13,8 @@ SRC_URI[sha256sum] = "864c8aee2efdda50346804d7e6230407d5f42a8ae754df70404dd8b2fd UPSTREAM_CHECK_URI = "http://sourceforge.net/projects/gptfdisk/files/gptfdisk/" UPSTREAM_CHECK_REGEX = "/gptfdisk/(?P<pver>(\d+[\.\-_]*)+)/" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + do_install() { install -d ${D}${sbindir} install -m 0755 cgdisk ${D}${sbindir}
Signature · 1 line
2.1.4
PATCH 8/15 ed: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-extended/ed/ed_1.9.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-extended/ed/ed_1.9.bb +2 -0
@@ -16,6 +16,8 @@ SRC_URI = "${GNU_MIRROR}/ed/ed-${PV}.tar.gz" SRC_URI[md5sum] = "565b6d1d5a9a8816b9b304fc4ed9405d" SRC_URI[sha256sum] = "d5b372cfadf073001823772272fceac2cfa87552c5cd5a8efc1c8aae61f45a88" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + inherit texinfo do_configure() {
Signature · 1 line
2.1.4
PATCH 9/15 iputils: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-extended/iputils/iputils_s20151218.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-extended/iputils/iputils_s20151218.bb +2 -0
@@ -27,6 +27,8 @@ SRC_URI[sha256sum] = "549f58d71951e52b46595829134d4e330642f522f50026917fadc349a5 UPSTREAM_CHECK_REGEX = "iputils-(?P<pver>s\d+).tar" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + do_compile () { oe_runmake 'CC=${CC} -D_GNU_SOURCE' VPATH="${STAGING_LIBDIR}:${STAGING_DIR_HOST}/${base_libdir}" all man }
Signature · 1 line
2.1.4
PATCH 10/15 pigz: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-extended/pigz/pigz.inc | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-extended/pigz/pigz.inc +2 -0
@@ -13,6 +13,8 @@ PROVIDES_class-native += "gzip-native" DEPENDS = "zlib" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + inherit update-alternatives do_install_class-target() {
Signature · 1 line
2.1.4
PATCH 11/15 stat: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-extended/stat/stat_3.3.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-extended/stat/stat_3.3.bb +2 -0
@@ -11,6 +11,8 @@ SRC_URI = "http://www.ibiblio.org/pub/Linux/utils/file/${BP}.tar.gz \ SRC_URI[md5sum] = "37e247e8e400ad9205f1b0500b728fd3" SRC_URI[sha256sum] = "7071f0384a423a938dd542c1f08547a02824f6359acd3ef3f944b2c4c2d1ee09" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + do_install() { install -d ${D}${base_bindir} ${D}${mandir}/man1 install -m 755 stat ${D}${base_bindir}/stat.stat
Signature · 1 line
2.1.4
PATCH 12/15 sysklogd: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-extended/sysklogd/sysklogd.inc | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-extended/sysklogd/sysklogd.inc +2 -0
@@ -25,6 +25,8 @@ SRC_URI_append_e500v2 = " file://no-vectorization.patch" INITSCRIPT_NAME = "syslog" CONFFILES_${PN} = "${sysconfdir}/syslog.conf.${BPN}" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + CFLAGS_append = " -DSYSV" do_install () {
Signature · 1 line
2.1.4
PATCH 13/15 unzip: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-extended/unzip/unzip_6.0.bb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-extended/unzip/unzip_6.0.bb +1 -1
@@ -30,7 +30,7 @@ S = "${WORKDIR}/unzip60" # Makefile and add CFLAGS. Optimization will be overriden by unzip # configure to be -O3. # -EXTRA_OEMAKE += "STRIP=true LF2='' \ +EXTRA_OEMAKE = "-e MAKEFLAGS= STRIP=true LF2='' \ 'CF_NOOPT=-I. -Ibzip2 -DUNIX ${CFLAGS}'" export LD = "${CC}"
Signature · 1 line
2.1.4
PATCH 14/15 gtk-theme-torturer: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-gnome/gtk-theme-torturer/gtk-theme-torturer_git.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-gnome/gtk-theme-torturer/gtk-theme-torturer_git.bb +2 -0
@@ -16,6 +16,8 @@ CFLAGS += "-Wl,-rpath-link,${STAGING_LIBDIR}" inherit distro_features_check ANY_OF_DISTRO_FEATURES = "${GTK2DISTROFEATURES}" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + do_install() { install -d ${D}${bindir} install -m 0755 torturer ${D}${bindir}
Signature · 1 line
2.1.4
PATCH 15/15 ptest-runner: Explicitly set EXTRA_OEMAKE as required
In reply to Mike CroweThis recipe currently relies on EXTRA_OEMAKE having been set to "-e MAKEFLAGS=" in bitbake.conf to operate. It is necessary to make this explicit so that the default in bitbake.conf can be changed.
--- meta/recipes-support/ptest-runner/ptest-runner_2.0.bb | 2 ++ 1 file changed, 2 insertions(+)
meta/recipes-support/ptest-runner/ptest-runner_2.0.bb +2 -0
@@ -15,6 +15,8 @@ S = "${WORKDIR}/git" FILES_${PN} = "${bindir}/ptest-runner" +EXTRA_OEMAKE = "-e MAKEFLAGS=" + do_compile () { oe_runmake }
Signature · 1 line
2.1.4
Quoted 5 lines · Mike Crowe
This series (sent only to openembedded-core) fixes various recipes that rely on the current default value of
EXTRA_OEMAKE= "-e MAKEFLAGS=" to explicitly set that value in the hope that bitbake.conf can setEXTRA_OEMAKE= "" in the future.
We need to also vet all instances of EXTRA_OEMAKE in recipes. I did a build with the EXTRA_OEMAKE change in bitbake.conf and hdparm failed to pass QA because the binary was already stripped, as the recipe does EXTRA_OEMAKE += "STRIP=echo". That assignment isn't getting through to the makefiles without -e.
Ross
Quoted 8 lines · Ross
Quoted 5 lines · Mike Crowe
This series (sent only to openembedded-core) fixes various recipes that rely on the current default value of
EXTRA_OEMAKE= "-e MAKEFLAGS=" to explicitly set that value in the hope that bitbake.conf can setEXTRA_OEMAKE= "" in the future.
Quoted 5 lines
We need to also vet all instances of
EXTRA_OEMAKEin recipes. I did a build with theEXTRA_OEMAKEchange in bitbake.conf and hdparm failed to pass QA because the binary was already stripped, as the recipe doesEXTRA_OEMAKE+= "STRIP=echo". That assignment isn't getting through to the makefiles without -e.
It should though, since all -e does is to make the environment variables take precedence over make assignments. But in case of assignments in EXTRA_OEMAKE, they are make assignments, so they shouldn't be affected:
$ cat Makefile FOO = bar
all:
echo $(FOO)
.PHONY: all
$ make FOO=qux echo qux qux $ make -e FOO=qux echo qux qux $ FOO=qux make echo bar bar $ FOO=qux make -e echo qux qux
Signature · 1 line
olofjn
Quoted 8 lines · Ross
Quoted 5 lines · Mike Crowe
This series (sent only to openembedded-core) fixes various recipes that rely on the current default value of
EXTRA_OEMAKE= "-e MAKEFLAGS=" to explicitly set that value in the hope that bitbake.conf can setEXTRA_OEMAKE= "" in the future.
Quoted 5 lines
We need to also vet all instances of
EXTRA_OEMAKEin recipes. I did a build with theEXTRA_OEMAKEchange in bitbake.conf and hdparm failed to pass QA because the binary was already stripped, as the recipe doesEXTRA_OEMAKE+= "STRIP=echo". That assignment isn't getting through to the makefiles without -e.
It seems that such QA checks are warnings so I hadn't noticed them before. I can see this one in a build that I'm currently doing. I'd better search through my cooker logs looking for warnings.
But, as Olof says, I don't really see how changing the default value of EXTRA_OEMAKE would have the effect you describe. (It could have the opposite effect if submakes are involved; without "-e MAKEFLAGS=", STRIP=echo will make it into submakes whereas previously it would not have done.)
It seems possible that some other variable from the environment was previously disabling strip. I'll investigate further.
Thanks for testing.
Mike.