diff options
| author | Wang Mingyu <wangmy@fujitsu.com> | 2024-07-10 17:43:43 +0800 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2024-07-16 11:25:29 +0100 |
| commit | 507cc5f96a4f12070bc3be733380cd3281bd0e60 (patch) | |
| tree | 52f751bb6b47e80bcf1aac454a832994b664061c | |
| parent | 78f30270f335fd54d823c246c385dc2d3086fc65 (diff) | |
| download | poky-507cc5f96a4f12070bc3be733380cd3281bd0e60.tar.gz | |
opkg: upgrade 0.6.3 -> 0.7.0
0001-libopkg-Use-libgen.h-to-provide-basename-API.patch
removed since it's included in 0.7.0
0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch
refreshed for 0.7.0
(From OE-Core rev: ce1ec6ea48df3592a8251bf0c25525a400bb8d23)
Signed-off-by: Wang Mingyu <wangmy@fujitsu.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/recipes-devtools/opkg/opkg/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch | 62 | ||||
| -rw-r--r-- | meta/recipes-devtools/opkg/opkg/0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch | 9 | ||||
| -rw-r--r-- | meta/recipes-devtools/opkg/opkg_0.7.0.bb (renamed from meta/recipes-devtools/opkg/opkg_0.6.3.bb) | 3 |
3 files changed, 4 insertions, 70 deletions
diff --git a/meta/recipes-devtools/opkg/opkg/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch b/meta/recipes-devtools/opkg/opkg/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch deleted file mode 100644 index 61581e752b..0000000000 --- a/meta/recipes-devtools/opkg/opkg/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch +++ /dev/null | |||
| @@ -1,62 +0,0 @@ | |||
| 1 | From 7a1c13a48cf020c40dda1721d5c2ffd95e8e669a Mon Sep 17 00:00:00 2001 | ||
| 2 | From: Khem Raj <raj.khem@gmail.com> | ||
| 3 | Date: Sun, 10 Dec 2023 19:39:29 -0800 | ||
| 4 | Subject: [PATCH v2] libopkg: Use libgen.h to provide basename API | ||
| 5 | |||
| 6 | Also ensure that copy of filename is passed into archive_entry_set_pathname | ||
| 7 | so it can be operated upon by posix basename which expect non-const | ||
| 8 | character pointer as input. | ||
| 9 | |||
| 10 | This became evident with latest musl where basename declaration was | ||
| 11 | dropped from string.h [1] | ||
| 12 | |||
| 13 | [1] https://git.musl-libc.org/cgit/musl/commit/?id=725e17ed6dff4d0cd22487bb64470881e86a92e7 | ||
| 14 | |||
| 15 | Upstream-Status: Backport [74fc3a991f974095644897d18d43846b5f359dae] | ||
| 16 | Signed-off-by: Khem Raj <raj.khem@gmail.com> | ||
| 17 | --- | ||
| 18 | v2: Do not override basename wholesale | ||
| 19 | |||
| 20 | libopkg/opkg_archive.c | 6 ++++-- | ||
| 21 | libopkg/opkg_remove.c | 1 + | ||
| 22 | 2 files changed, 5 insertions(+), 2 deletions(-) | ||
| 23 | |||
| 24 | diff --git a/libopkg/opkg_archive.c b/libopkg/opkg_archive.c | ||
| 25 | index 03a4afb..b099f5b 100644 | ||
| 26 | --- a/libopkg/opkg_archive.c | ||
| 27 | +++ b/libopkg/opkg_archive.c | ||
| 28 | @@ -20,6 +20,7 @@ | ||
| 29 | |||
| 30 | #include <archive.h> | ||
| 31 | #include <archive_entry.h> | ||
| 32 | +#include <libgen.h> | ||
| 33 | #include <stdlib.h> | ||
| 34 | #include <stdio.h> | ||
| 35 | #include <string.h> | ||
| 36 | @@ -797,8 +798,9 @@ int gz_write_archive(const char *filename, const char *gz_filename) | ||
| 37 | } | ||
| 38 | |||
| 39 | /* Remove path hierarchy, as we are only compressing a single file */ | ||
| 40 | - archive_entry_set_pathname(entry, basename(filename)); | ||
| 41 | - | ||
| 42 | + char* tmp = xstrdup(filename); | ||
| 43 | + archive_entry_set_pathname(entry, basename(tmp)); | ||
| 44 | + free(tmp); | ||
| 45 | r = archive_write_header(a, entry); | ||
| 46 | if (r != ARCHIVE_OK) { | ||
| 47 | opkg_msg(ERROR, "Failed to create compressed file: '%s' : %s (errno=%d)", | ||
| 48 | diff --git a/libopkg/opkg_remove.c b/libopkg/opkg_remove.c | ||
| 49 | index 889c672..5254388 100644 | ||
| 50 | --- a/libopkg/opkg_remove.c | ||
| 51 | +++ b/libopkg/opkg_remove.c | ||
| 52 | @@ -20,6 +20,7 @@ | ||
| 53 | |||
| 54 | #include "config.h" | ||
| 55 | |||
| 56 | +#include <libgen.h> | ||
| 57 | #include <stdio.h> | ||
| 58 | #include <glob.h> | ||
| 59 | #include <unistd.h> | ||
| 60 | -- | ||
| 61 | 2.43.0 | ||
| 62 | |||
diff --git a/meta/recipes-devtools/opkg/opkg/0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch b/meta/recipes-devtools/opkg/opkg/0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch index e94a4123dd..98daf746ec 100644 --- a/meta/recipes-devtools/opkg/opkg/0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch +++ b/meta/recipes-devtools/opkg/opkg/0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | From a4628a6171f393add9a2b287483ca39bb72b4dd6 Mon Sep 17 00:00:00 2001 | 1 | From 82b29dcfe3033d8285890bf46e58f464d9944196 Mon Sep 17 00:00:00 2001 |
| 2 | From: Jonathan Liu <net147@gmail.com> | 2 | From: Jonathan Liu <net147@gmail.com> |
| 3 | Date: Mon, 21 Sep 2015 20:23:23 +1000 | 3 | Date: Mon, 21 Sep 2015 20:23:23 +1000 |
| 4 | Subject: [PATCH] opkg_conf: create opkg.lock in /run instead of /var/run | 4 | Subject: [PATCH] opkg_conf: create opkg.lock in /run instead of /var/run |
| @@ -17,10 +17,10 @@ Signed-off-by: Jonathan Liu <net147@gmail.com> | |||
| 17 | 1 file changed, 1 insertion(+), 1 deletion(-) | 17 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 18 | 18 | ||
| 19 | diff --git a/libopkg/opkg_conf.h b/libopkg/opkg_conf.h | 19 | diff --git a/libopkg/opkg_conf.h b/libopkg/opkg_conf.h |
| 20 | index 7bca948..5a1bc44 100644 | 20 | index 3fa6ca9..b12672e 100644 |
| 21 | --- a/libopkg/opkg_conf.h | 21 | --- a/libopkg/opkg_conf.h |
| 22 | +++ b/libopkg/opkg_conf.h | 22 | +++ b/libopkg/opkg_conf.h |
| 23 | @@ -40,7 +40,7 @@ extern "C" { | 23 | @@ -42,7 +42,7 @@ extern "C" { |
| 24 | #define OPKG_CONF_DEFAULT_STATUS_FILE VARDIR "/lib/opkg/status" | 24 | #define OPKG_CONF_DEFAULT_STATUS_FILE VARDIR "/lib/opkg/status" |
| 25 | #define OPKG_CONF_DEFAULT_CACHE_DIR VARDIR "/cache/opkg" | 25 | #define OPKG_CONF_DEFAULT_CACHE_DIR VARDIR "/cache/opkg" |
| 26 | #define OPKG_CONF_DEFAULT_CONF_FILE_DIR SYSCONFDIR "/opkg" | 26 | #define OPKG_CONF_DEFAULT_CONF_FILE_DIR SYSCONFDIR "/opkg" |
| @@ -29,6 +29,3 @@ index 7bca948..5a1bc44 100644 | |||
| 29 | 29 | ||
| 30 | /* In case the config file defines no dest */ | 30 | /* In case the config file defines no dest */ |
| 31 | #define OPKG_CONF_DEFAULT_DEST_NAME "root" | 31 | #define OPKG_CONF_DEFAULT_DEST_NAME "root" |
| 32 | -- | ||
| 33 | 2.5.0 | ||
| 34 | |||
diff --git a/meta/recipes-devtools/opkg/opkg_0.6.3.bb b/meta/recipes-devtools/opkg/opkg_0.7.0.bb index ef7c4f3a72..6b2b13024d 100644 --- a/meta/recipes-devtools/opkg/opkg_0.6.3.bb +++ b/meta/recipes-devtools/opkg/opkg_0.7.0.bb | |||
| @@ -15,11 +15,10 @@ PE = "1" | |||
| 15 | SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz \ | 15 | SRC_URI = "http://downloads.yoctoproject.org/releases/${BPN}/${BPN}-${PV}.tar.gz \ |
| 16 | file://opkg.conf \ | 16 | file://opkg.conf \ |
| 17 | file://0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch \ | 17 | file://0001-opkg_conf-create-opkg.lock-in-run-instead-of-var-run.patch \ |
| 18 | file://0001-libopkg-Use-libgen.h-to-provide-basename-API.patch \ | ||
| 19 | file://run-ptest \ | 18 | file://run-ptest \ |
| 20 | " | 19 | " |
| 21 | 20 | ||
| 22 | SRC_URI[sha256sum] = "f3938e359646b406c40d5d442a1467c7e72357f91ab822e442697529641e06de" | 21 | SRC_URI[sha256sum] = "d973fd0f1568f58f87d6aecd9aa95e3e1f60214a45cee26704bf8fe757c54567" |
| 23 | 22 | ||
| 24 | # This needs to be before ptest inherit, otherwise all ptest files end packaged | 23 | # This needs to be before ptest inherit, otherwise all ptest files end packaged |
| 25 | # in libopkg package if OPKGLIBDIR == libdir, because default | 24 | # in libopkg package if OPKGLIBDIR == libdir, because default |
