Skip to contentSkip to conversation

Resending the patches that were missed in patchwork

PATCH In review Amarnath Valluri 2 participants 13 messages Feb 23, 2017 – Feb 24, 2017

lore
Share & tools
lore
#0 lore raw

cover Resending the patches that were missed in patchwork

This patch set replaces the hard-coded paths in recipes with appropriate bitbake variables, which makes recipe more portable.

Amarnath Valluri (9):
aufs-utils: Replace install paths with appropriate bitbake environment
inetutils: Move files only when src != dst.
ebtables: Move files only when src != dst.
netcf_git: Check if src != dst while moving files.
libgphoto: Replace 'lib' with ${nonarch_base_libdir}
xf86-input-tslib: Replace 'lib' with ${nonarch_base_libdir} for
placing udev rules.
lvm2: Replace 'lib' with ${nonarch_base_libdir} for placing udev
rules.
multipath-tools: Replace 'lib' with ${nonarch_base_libdir} for placing
udev rules.
openct: Replace /lib/udev with ${nonarch_base_libdir}/udev.

 meta-filesystems/recipes-utils/aufs-util/aufs-util_git.bb         | 7 +++++++
 meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb | 8 +++++---
 meta-networking/recipes-filter/ebtables/ebtables_2.0.10-4.bb      | 6 ++++--
 meta-networking/recipes-support/netcf/netcf_git.bb                | 8 +++++---
 meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.8.bb              | 2 +-
 meta-oe/recipes-graphics/xorg-driver/xf86-input-tslib_0.0.6.bb    | 6 +++---
 meta-oe/recipes-support/lvm2/lvm2.inc                             | 4 ++--
 meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb    | 7 ++++---
 meta-oe/recipes-support/openct/openct_0.6.20.bb                   | 6 +++---
 9 files changed, 34 insertions(+), 20 deletions(-)
Signature · 1 line
2.7.4
#1 lore raw

PATCH 1/9 aufs-utils: Replace install paths with appropriate bitbake environment

autf-utils Makefile is using hardcoded /bin, /sbin paths, instead we should respect the bitbake environment. This change makes the recipe portable to environments where ${base_bindir} != /bin or ${base_sbindir} != /sbin.

---
 meta-filesystems/recipes-utils/aufs-util/aufs-util_git.bb | 7 +++++++
 1 file changed, 7 insertions(+)
meta-filesystems/recipes-utils/aufs-util/aufs-util_git.bb +7 -0
index 8980980..3d59e50 100644
@@ -18,6 +18,13 @@ PV = "3.14+git${SRCPV}"
 
 S = "${WORKDIR}/git"
 
+do_configure_prepend() {
+   # Replace sbin,bin paths with bitbake environment
+   sed -i -e 's;install_sbin: Tgt = ${DESTDIR}/sbin;install_sbin: Tgt = ${DESTDIR}/${base_sbindir};' \
+          -e 's;install_ubin: Tgt = ${DESTDIR}/usr/sbin;install_sbin: Tgt = ${DESTDIR}/${bindir};' \
+	  ${S}/Makefile
+}
+
 do_configure_append () {
     install -d ${S}/include/linux/
     cp ${WORKDIR}/aufs_type.h ${S}/include/linux/
Signature · 1 line
2.7.4
#2 lore raw

PATCH 2/9 inetutils: Move files only when src != dst.

In reply to Amarnath Valluri

While moving files from ${bindir} to ${base_bindir} check if both are same.

---
 meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
meta-networking/recipes-connectivity/inetutils/inetutils_1.9.4.bb +5 -3
index e3f5aa3..fd5ff4d 100644
@@ -58,14 +58,16 @@ do_configure_prepend () {
 }
 
 do_install_append () {
-    install -m 0755 -d ${D}${base_bindir}
     install -m 0755 -d ${D}${base_sbindir}
     install -m 0755 -d ${D}${sbindir}
     install -m 0755 -d ${D}${sysconfdir}/xinetd.d
-    mv ${D}${bindir}/ping* ${D}${base_bindir}/
+    if [ "${base_bindir}" != "${bindir}" ] ; then
+         install -m 0755 -d ${D}${base_bindir}
+         mv ${D}${bindir}/ping* ${D}${base_bindir}/
+         mv ${D}${bindir}/hostname ${D}${base_bindir}/
+    fi
     mv ${D}${bindir}/ifconfig ${D}${base_sbindir}/
     mv ${D}${libexecdir}/syslogd ${D}${base_sbindir}/
-    mv ${D}${bindir}/hostname ${D}${base_bindir}/
     mv ${D}${libexecdir}/tftpd ${D}${sbindir}/in.tftpd
     mv ${D}${libexecdir}/telnetd ${D}${sbindir}/in.telnetd
     mv ${D}${libexecdir}/rexecd ${D}${sbindir}/in.rexecd
Signature · 1 line
2.7.4
#3 lore raw

PATCH 3/9 ebtables: Move files only when src != dst.

In reply to Amarnath Valluri

While moving files from ${base_sbindir} to ${sbindir} check if both are same.

---
 meta-networking/recipes-filter/ebtables/ebtables_2.0.10-4.bb | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
meta-networking/recipes-filter/ebtables/ebtables_2.0.10-4.bb +4 -2
index d24b81b..f5e2871 100644
@@ -70,8 +70,10 @@ do_install () {
 
     # The script ebtables-save refernces perl in exec_prefix, so
     # move it to sbindir to avoid QA issue
-    install -d ${D}/${sbindir}
-    mv ${D}/${base_sbindir}/ebtables-save ${D}/${sbindir}
+    if ${base_sbindir} != ${sbindir} ; then
+       install -d ${D}/${sbindir}
+       mv ${D}/${base_sbindir}/ebtables-save ${D}/${sbindir}
+    fi
 
     # Install systemd service files
     install -d ${D}${systemd_unitdir}/system
Signature · 1 line
2.7.4
#4 lore raw

PATCH 4/9 netcf_git: Check if src != dst while moving files.

In reply to Amarnath Valluri
---
 meta-networking/recipes-support/netcf/netcf_git.bb | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)
meta-networking/recipes-support/netcf/netcf_git.bb +5 -3
index ed713ac..4ffd3db 100644
@@ -47,9 +47,11 @@ do_install_append() {
     if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
        install -d ${D}${systemd_unitdir}/system
        if [ -d "${D}${libdir}/systemd/system" ]; then
-           mv ${D}${libdir}/systemd/system/* ${D}${systemd_unitdir}/system/
-           rm -rf ${D}${libdir}/systemd/
-       else
+           if [ "${systemd_unitdir}" != "${libdir}/systemd" ] ; then 
+               mv ${D}${libdir}/systemd/system/* ${D}${systemd_unitdir}/system/
+               rm -rf ${D}${libdir}/systemd/
+	   fi
+       elif [ "${systemd_unitdir}" != "${nonarch_libdir}/systemd" ] ; then 
            mv ${D}${nonarch_libdir}/systemd/system/* ${D}${systemd_unitdir}/system/
            rm -rf ${D}${nonarch_libdir}/systemd/
        fi
Signature · 1 line
2.7.4
#5 lore raw

PATCH 5/9 libgphoto: Replace 'lib' with ${nonarch_base_libdir}

In reply to Amarnath Valluri

Make use of bitbake variable for udev ruls folder. This change makes the recipe more portable.

---
 meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.8.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta-oe/recipes-graphics/gphoto2/libgphoto2_2.5.8.bb +1 -1
index e251567..5e798ef 100644
@@ -24,7 +24,7 @@ SRC_URI[libgphoto2.sha256sum] = "031a262e342fae43f724afe66787947ce1fb483277dfe5a
 
 inherit autotools pkgconfig gettext lib_package
 
-EXTRA_OECONF = " --with-drivers=all udevscriptdir=/lib/udev ac_cv_lib_ltdl_lt_dlcaller_register=yes"
+EXTRA_OECONF = " --with-drivers=all udevscriptdir=${nonarch_base_libdir}/udev ac_cv_lib_ltdl_lt_dlcaller_register=yes"
 
 PACKAGECONFIG ??= ""
 PACKAGECONFIG[gd] = ",--without-gdlib,gd"
Signature · 1 line
2.7.4
#6 lore raw

PATCH 6/9 xf86-input-tslib: Replace 'lib' with ${nonarch_base_libdir} for placing udev rules.

In reply to Amarnath Valluri
---
 meta-oe/recipes-graphics/xorg-driver/xf86-input-tslib_0.0.6.bb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
meta-oe/recipes-graphics/xorg-driver/xf86-input-tslib_0.0.6.bb +3 -3
index 082c771..6a3689a 100644
@@ -28,8 +28,8 @@ do_configure_prepend() {
 do_install_append() {
     install -d ${D}/${datadir}/hal/fdi/policy/20thirdparty
     install -m 0644 ${WORKDIR}/10-x11-input-tslib.fdi ${D}/${datadir}/hal/fdi/policy/20thirdparty
-    install -d ${D}/lib/udev/rules.d
-    install -m 0644 ${WORKDIR}/99-xf86-input-tslib.rules ${D}/lib/udev/rules.d/
+    install -d ${D}${nonarch_base_libdir}/udev/rules.d
+    install -m 0644 ${WORKDIR}/99-xf86-input-tslib.rules ${D}${nonarch_base_libdir}/udev/rules.d/
 }
 
-FILES_${PN} += "${datadir}/hal /lib/udev"
+FILES_${PN} += "${datadir}/hal ${nonarch_base_libdir}/udev"
Signature · 1 line
2.7.4
#7 lore raw

PATCH v2 7/9 lvm2: Replace 'lib' with ${nonarch_base_libdir} for placing udev rules.

In reply to Amarnath Valluri
---
 meta-oe/recipes-support/lvm2/lvm2.inc | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
meta-oe/recipes-support/lvm2/lvm2.inc +2 -2
index e0a126e..2bb0134 100644
@@ -38,7 +38,7 @@ PACKAGECONFIG[odirect] = "--enable-o_direct,--disable-o_direct"
 PACKAGECONFIG[readline] = "--enable-readline,--disable-readline,readline"
 PACKAGECONFIG[selinux] = "--enable-selinux,--disable-selinux,libselinux"
 PACKAGECONFIG[thin-provisioning-tools] = "--with-thin=internal,--with-thin=none,,thin-provisioning-tools"
-PACKAGECONFIG[udev] = "--enable-udev_sync --enable-udev_rules --with-udev-prefix=,--disable-udev_sync --disable-udev_rules,udev"
+PACKAGECONFIG[udev] = "--enable-udev_sync --enable-udev_rules --with-udevdir=${nonarch_base_libdir}/udev/rules.d,--disable-udev_sync --disable-udev_rules,udev"
 
 # Unset user/group to unbreak install.
 EXTRA_OECONF = "--with-user= \
@@ -83,7 +83,7 @@ SYSTEMD_AUTO_ENABLE = "disable"
 
 TARGET_CC_ARCH += "${LDFLAGS}"
 
-FILES_${PN} += "${libdir}/device-mapper/*.so ${base_libdir}/udev"
+FILES_${PN} += "${libdir}/device-mapper/*.so ${nonarch_base_libdir}/udev"
 FILES_${PN}-scripts = " \
     ${sbindir}/blkdeactivate \
     ${sbindir}/fsadm \
Signature · 1 line
2.7.4
#8 lore raw

PATCH 8/9 multipath-tools: Replace 'lib' with ${nonarch_base_libdir} for placing udev rules.

In reply to Amarnath Valluri
---
 meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb +4 -3
index effd92e..0cc53fb 100644
@@ -40,7 +40,7 @@ ARM_INSTRUCTION_SET_armv5 = "arm"
 EXTRA_OEMAKE = 'MULTIPATH_VERSION=${PV} DESTDIR=${D} syslibdir=${base_libdir} \
                 OPTFLAGS="${CFLAGS}" \
                 LIB=${base_libdir} libdir=${base_libdir}/multipath \
-                unitdir=/lib/systemd/system \
+                unitdir/=${systemd_system_unitdir} \
                 ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "SYSTEMD=216", "", d)} \
                '
 
@@ -59,11 +59,12 @@ FILES_${PN}-dbg += "${base_libdir}/multipath/.debug"
 # systemd and udev stuff always goes under /lib!
 #
 FILES_${PN} += "${base_libdir}/multipath \
-                /lib/systemd"
+                ${systemd_system_unitdir} \
+		"
 
 PACKAGES =+ "kpartx"
 FILES_kpartx = "${base_sbindir}/kpartx \
-                /usr/lib/udev/kpartx_id \
+                ${nonarch_libdir}/udev/kpartx_id \
                "
 
 RDEPENDS_${PN} += "kpartx"
Signature · 1 line
2.7.4
#9 lore raw

Re: [PATCH 8/9] multipath-tools: Replace 'lib' with ${nonarch_base_libdir} for placing udev rules.

Quoted 10 lines · Amarnath Valluri
---
 meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb +0 -0
index effd92e..0cc53fb 100644

meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb ARM_INSTRUCTION_SET_armv5 = "arm" · line 43

Quoted 5 lines
meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb +1 -1
@@ -40,7 +40,7 @@ ARM_INSTRUCTION_SET_armv5 = "arm"
 EXTRA_OEMAKE = 'MULTIPATH_VERSION=${PV} DESTDIR=${D} syslibdir=${base_libdir} \
                 OPTFLAGS="${CFLAGS}" \
                 LIB=${base_libdir} libdir=${base_libdir}/multipath \
-                unitdir=/lib/systemd/system \
+                unitdir/=${systemd_system_unitdir} \

is the / before = intentional?

Also causes:
multipath-tools-0.6.4+git922421cf79: multipath-tools: Files/directories were installed but not shipped in any package:
/usr/lib/systemd
/usr/lib/systemd/system
/usr/lib/systemd/system/multipathd.service
/usr/lib/systemd/system/multipathd.socket
Please set FILES such that these items are packaged. Alternatively if they are unneeded, avoid installing them or delete them within do_install.
multipath-tools: 4 installed and not shipped files. [installed-vs-shipped]
multipath-tools-0.6.4+git922421cf79: /etc/init.d/multipathd contained in package multipath-tools requires /bin/bash, but no providers found in RDEPENDS_multipath-tools? [file-rdeps]

Quoted 26 lines
meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb +3 -2
                 ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "SYSTEMD=216", "", d)} \
                '
 
@@ -59,11 +59,12 @@ FILES_${PN}-dbg += "${base_libdir}/multipath/.debug"
 # systemd and udev stuff always goes under /lib!
 #
 FILES_${PN} += "${base_libdir}/multipath \
-                /lib/systemd"
+                ${systemd_system_unitdir} \
+		"
 
 PACKAGES =+ "kpartx"
 FILES_kpartx = "${base_sbindir}/kpartx \
-                /usr/lib/udev/kpartx_id \
+                ${nonarch_libdir}/udev/kpartx_id \
                "
 
 RDEPENDS_${PN} += "kpartx"
Signature · 7 lines
2.7.4

-- 
_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-devel
Signature · 1 line
Martin 'JaMa' Jansa     jabber: [email protected]
#10 lore raw

Re: [PATCH 8/9] multipath-tools: Replace 'lib' with ${nonarch_base_libdir} for placing udev rules.

Quoted 6 lines · Martin Jansa
Quoted 5 lines · Amarnath Valluri
---
  meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb | 7 ++++---
  1 file changed, 4 insertions(+), 3 deletions(-)
Quoted 11 lines

meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb ARM_INSTRUCTION_SET_armv5 = "arm" · line 43

Quoted 10 lines
meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb +1 -1
index effd92e..0cc53fb 100644
@@ -40,7 +40,7 @@ ARM_INSTRUCTION_SET_armv5 = "arm"
  EXTRA_OEMAKE = 'MULTIPATH_VERSION=${PV} DESTDIR=${D} syslibdir=${base_libdir} \
                  OPTFLAGS="${CFLAGS}" \
                  LIB=${base_libdir} libdir=${base_libdir}/multipath \
-                unitdir=/lib/systemd/system \
+                unitdir/=${systemd_system_unitdir} \

is the / before = intentional?

No, it must be a typo, I will resubmit the patch. Thanks for reviewing.

- Amarnath

#11 lore raw

PATCH v2 8/9 multipath-tools: Replace 'lib' with ${nonarch_base_libdir} for placing udev rules.

In reply to Martin Jansa
---
 meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
meta-oe/recipes-support/multipath-tools/multipath-tools_git.bb +4 -3
index effd92e..a63982e 100644
@@ -40,7 +40,7 @@ ARM_INSTRUCTION_SET_armv5 = "arm"
 EXTRA_OEMAKE = 'MULTIPATH_VERSION=${PV} DESTDIR=${D} syslibdir=${base_libdir} \
                 OPTFLAGS="${CFLAGS}" \
                 LIB=${base_libdir} libdir=${base_libdir}/multipath \
-                unitdir=/lib/systemd/system \
+                unitdir=${systemd_system_unitdir} \
                 ${@bb.utils.contains("DISTRO_FEATURES", "systemd", "SYSTEMD=216", "", d)} \
                '
 
@@ -59,11 +59,12 @@ FILES_${PN}-dbg += "${base_libdir}/multipath/.debug"
 # systemd and udev stuff always goes under /lib!
 #
 FILES_${PN} += "${base_libdir}/multipath \
-                /lib/systemd"
+                ${systemd_system_unitdir} \
+		"
 
 PACKAGES =+ "kpartx"
 FILES_kpartx = "${base_sbindir}/kpartx \
-                /usr/lib/udev/kpartx_id \
+                ${nonarch_libdir}/udev/kpartx_id \
                "
 
 RDEPENDS_${PN} += "kpartx"
Signature · 1 line
2.7.4
#12 lore raw

PATCH 9/9 openct: Replace /lib/udev with ${nonarch_base_libdir}/udev.

In reply to Amarnath Valluri
---
 meta-oe/recipes-support/openct/openct_0.6.20.bb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
meta-oe/recipes-support/openct/openct_0.6.20.bb +3 -3
index d4ad9c1..85ca851 100644
@@ -34,7 +34,7 @@ EXTRA_OECONF=" \
     --enable-pcsc \
     --enable-doc \
     --enable-api-doc \
-    --with-udev=/lib/udev \
+    --with-udev=${nonarch_base_libdir}/udev \
     --with-bundle=${libdir}/pcsc/drivers \
 "
 
@@ -42,7 +42,7 @@ inherit autotools pkgconfig
 
 FILES_${PN} += " \
     ${libdir}/ctapi \
-    /lib/udev \
+    ${nonarch_base_libdir}/udev \
     ${libdir}/openct-ifd.so \
     ${libdir}/pcsc \
     /run/openct/status \
@@ -62,7 +62,7 @@ do_install_append() {
 do_install () {
     rm -rf ${D}
     install -d ${D}/etc
-    install -dm 755 ${D}/lib/udev
+    install -dm 755 ${D}${nonarch_base_libdir}/udev
     # fix up hardcoded paths
     sed -i -e 's,/etc/,${sysconfdir}/,' -e 's,/usr/sbin/,${sbindir}/,' \
         ${WORKDIR}/openct.service ${WORKDIR}/openct.init
Signature · 1 line
2.7.4