From 74d3b4a199bfeae99dfbe6f23f1c3cb4bf76abff Mon Sep 17 00:00:00 2001 From: Alejandro del Castillo Date: Wed, 26 Dec 2018 17:59:04 -0600 Subject: opkg: upgrade to version 0.4.0 - Drop 0001-remove_maintainer_scripts-use-strict-matching.patch Signed-off-by: Alejandro del Castillo Signed-off-by: Richard Purdie --- ...ve_maintainer_scripts-use-strict-matching.patch | 56 ------------------- meta/recipes-devtools/opkg/opkg_0.3.6.bb | 62 ---------------------- meta/recipes-devtools/opkg/opkg_0.4.0.bb | 61 +++++++++++++++++++++ 3 files changed, 61 insertions(+), 118 deletions(-) delete mode 100644 meta/recipes-devtools/opkg/opkg/0001-remove_maintainer_scripts-use-strict-matching.patch delete mode 100644 meta/recipes-devtools/opkg/opkg_0.3.6.bb create mode 100644 meta/recipes-devtools/opkg/opkg_0.4.0.bb (limited to 'meta/recipes-devtools') diff --git a/meta/recipes-devtools/opkg/opkg/0001-remove_maintainer_scripts-use-strict-matching.patch b/meta/recipes-devtools/opkg/opkg/0001-remove_maintainer_scripts-use-strict-matching.patch deleted file mode 100644 index ec160290be..0000000000 --- a/meta/recipes-devtools/opkg/opkg/0001-remove_maintainer_scripts-use-strict-matching.patch +++ /dev/null @@ -1,56 +0,0 @@ -From 55c4ad666e76281bdd0db55fa6f4ab2744fea7e4 Mon Sep 17 00:00:00 2001 -From: Alejandro del Castillo -Date: Tue, 4 Sep 2018 18:06:00 -0500 -Subject: [PATCH] remove_maintainer_scripts: use strict matching - -The function is using a glob to select which metadata files needs to be -deleted during package removal, on the info_dir. However, the glob may -match metadata files from packages with similar names. For example, -during removal of package glibc-binary-localedata-de-at, the current -logic was also removing the metadata for -glibc-binary-localedata-de-at.iso-8859-1. Add check for an exact match -before deletion. - -Fixes bugzilla: 12905 - -Upstream-Status: Submitted [https://groups.google.com/forum/#!topic/opkg-devel/Fr40Yt0NBno] -Signed-off-by: Alejandro del Castillo ---- - libopkg/opkg_remove.c | 14 +++++++++++--- - 1 file changed, 11 insertions(+), 3 deletions(-) - -diff --git a/libopkg/opkg_remove.c b/libopkg/opkg_remove.c -index 82125fa..3936628 100644 ---- a/libopkg/opkg_remove.c -+++ b/libopkg/opkg_remove.c -@@ -137,7 +137,7 @@ void remove_maintainer_scripts(pkg_t * pkg) - { - unsigned int i; - int err; -- char *globpattern; -+ char *globpattern, *filename, *lastdot; - glob_t globbuf; - - if (opkg_config->noaction) -@@ -151,8 +151,16 @@ void remove_maintainer_scripts(pkg_t * pkg) - return; - - for (i = 0; i < globbuf.gl_pathc; i++) { -- opkg_msg(INFO, "Deleting %s.\n", globbuf.gl_pathv[i]); -- unlink(globbuf.gl_pathv[i]); -+ filename = xstrdup(basename(globbuf.gl_pathv[i])); -+ lastdot = strrchr(filename, '.'); -+ *lastdot = '\0'; -+ // Only delete files that match the package name (the glob may match files -+ // with similar names) -+ if (!strcmp(filename, pkg->name)) { -+ opkg_msg(INFO, "Deleting %s.\n", globbuf.gl_pathv[i]); -+ unlink(globbuf.gl_pathv[i]); -+ } -+ free(filename); - } - globfree(&globbuf); - } --- -2.18.0 - diff --git a/meta/recipes-devtools/opkg/opkg_0.3.6.bb b/meta/recipes-devtools/opkg/opkg_0.3.6.bb deleted file mode 100644 index 6ebd58b967..0000000000 --- a/meta/recipes-devtools/opkg/opkg_0.3.6.bb +++ /dev/null @@ -1,62 +0,0 @@ -SUMMARY = "Open Package Manager" -SUMMARY_libopkg = "Open Package Manager library" -SECTION = "base" -HOMEPAGE = "http://code.google.com/p/opkg/" -BUGTRACKER = "http://code.google.com/p/opkg/issues/list" -LICENSE = "GPLv2+" -LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \ - file://src/opkg.c;beginline=2;endline=21;md5=90435a519c6ea69ef22e4a88bcc52fa0" - -DEPENDS = "libarchive" - -PE = "1" - -SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz \ - file://opkg.conf \ - file://0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch \ - file://0001-remove_maintainer_scripts-use-strict-matching.patch \ -" - -SRC_URI[md5sum] = "79e04307f6f54db431c251772d7d987c" -SRC_URI[sha256sum] = "f607f0e61be8cf8a3bbd0d2dccd9ec9e9b6c21dd4307b671c600d6eeaf84d30b" - -inherit autotools pkgconfig systemd - -target_localstatedir := "${localstatedir}" -OPKGLIBDIR = "${target_localstatedir}/lib" - -PACKAGECONFIG ??= "libsolv" - -PACKAGECONFIG[gpg] = "--enable-gpg,--disable-gpg,gpgme libgpg-error,gnupg" -PACKAGECONFIG[curl] = "--enable-curl,--disable-curl,curl" -PACKAGECONFIG[ssl-curl] = "--enable-ssl-curl,--disable-ssl-curl,curl openssl" -PACKAGECONFIG[openssl] = "--enable-openssl,--disable-openssl,openssl" -PACKAGECONFIG[sha256] = "--enable-sha256,--disable-sha256" -PACKAGECONFIG[pathfinder] = "--enable-pathfinder,--disable-pathfinder,pathfinder" -PACKAGECONFIG[libsolv] = "--with-libsolv,--without-libsolv,libsolv" - -EXTRA_OECONF_class-native = "--localstatedir=/${@os.path.relpath('${localstatedir}', '${STAGING_DIR_NATIVE}')} --sysconfdir=/${@os.path.relpath('${sysconfdir}', '${STAGING_DIR_NATIVE}')}" - -do_install_append () { - install -d ${D}${sysconfdir}/opkg - install -m 0644 ${WORKDIR}/opkg.conf ${D}${sysconfdir}/opkg/opkg.conf - echo "option lists_dir ${OPKGLIBDIR}/opkg/lists" >>${D}${sysconfdir}/opkg/opkg.conf - - # We need to create the lock directory - install -d ${D}${OPKGLIBDIR}/opkg -} - -RDEPENDS_${PN} = "${VIRTUAL-RUNTIME_update-alternatives} opkg-arch-config libarchive" -RDEPENDS_${PN}_class-native = "" -RDEPENDS_${PN}_class-nativesdk = "" -RREPLACES_${PN} = "opkg-nogpg opkg-collateral" -RCONFLICTS_${PN} = "opkg-collateral" -RPROVIDES_${PN} = "opkg-collateral" - -PACKAGES =+ "libopkg" - -FILES_libopkg = "${libdir}/*.so.* ${OPKGLIBDIR}/opkg/" - -BBCLASSEXTEND = "native nativesdk" - -CONFFILES_${PN} = "${sysconfdir}/opkg/opkg.conf" diff --git a/meta/recipes-devtools/opkg/opkg_0.4.0.bb b/meta/recipes-devtools/opkg/opkg_0.4.0.bb new file mode 100644 index 0000000000..9b7cf3f596 --- /dev/null +++ b/meta/recipes-devtools/opkg/opkg_0.4.0.bb @@ -0,0 +1,61 @@ +SUMMARY = "Open Package Manager" +SUMMARY_libopkg = "Open Package Manager library" +SECTION = "base" +HOMEPAGE = "http://code.google.com/p/opkg/" +BUGTRACKER = "http://code.google.com/p/opkg/issues/list" +LICENSE = "GPLv2+" +LIC_FILES_CHKSUM = "file://COPYING;md5=94d55d512a9ba36caa9b7df079bae19f \ + file://src/opkg.c;beginline=2;endline=21;md5=90435a519c6ea69ef22e4a88bcc52fa0" + +DEPENDS = "libarchive" + +PE = "1" + +SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz \ + file://opkg.conf \ + file://0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch \ +" + +SRC_URI[md5sum] = "ae51d95fee599bb4dce08453529158f5" +SRC_URI[sha256sum] = "f6c00515d8a2ad8f6742a8e73830315d1983ed0459cba77c4d656cfc9e7fe6fe" + +inherit autotools pkgconfig systemd + +target_localstatedir := "${localstatedir}" +OPKGLIBDIR = "${target_localstatedir}/lib" + +PACKAGECONFIG ??= "libsolv" + +PACKAGECONFIG[gpg] = "--enable-gpg,--disable-gpg,gpgme libgpg-error,gnupg" +PACKAGECONFIG[curl] = "--enable-curl,--disable-curl,curl" +PACKAGECONFIG[ssl-curl] = "--enable-ssl-curl,--disable-ssl-curl,curl openssl" +PACKAGECONFIG[openssl] = "--enable-openssl,--disable-openssl,openssl" +PACKAGECONFIG[sha256] = "--enable-sha256,--disable-sha256" +PACKAGECONFIG[pathfinder] = "--enable-pathfinder,--disable-pathfinder,pathfinder" +PACKAGECONFIG[libsolv] = "--with-libsolv,--without-libsolv,libsolv" + +EXTRA_OECONF_class-native = "--localstatedir=/${@os.path.relpath('${localstatedir}', '${STAGING_DIR_NATIVE}')} --sysconfdir=/${@os.path.relpath('${sysconfdir}', '${STAGING_DIR_NATIVE}')}" + +do_install_append () { + install -d ${D}${sysconfdir}/opkg + install -m 0644 ${WORKDIR}/opkg.conf ${D}${sysconfdir}/opkg/opkg.conf + echo "option lists_dir ${OPKGLIBDIR}/opkg/lists" >>${D}${sysconfdir}/opkg/opkg.conf + + # We need to create the lock directory + install -d ${D}${OPKGLIBDIR}/opkg +} + +RDEPENDS_${PN} = "${VIRTUAL-RUNTIME_update-alternatives} opkg-arch-config libarchive" +RDEPENDS_${PN}_class-native = "" +RDEPENDS_${PN}_class-nativesdk = "" +RREPLACES_${PN} = "opkg-nogpg opkg-collateral" +RCONFLICTS_${PN} = "opkg-collateral" +RPROVIDES_${PN} = "opkg-collateral" + +PACKAGES =+ "libopkg" + +FILES_libopkg = "${libdir}/*.so.* ${OPKGLIBDIR}/opkg/" + +BBCLASSEXTEND = "native nativesdk" + +CONFFILES_${PN} = "${sysconfdir}/opkg/opkg.conf" -- cgit 1.2.3-korg