* [PR PATCH] opkg: update to 0.6.3, switch to libsolv
@ 2024-02-10 2:23 Piraty
2024-05-11 1:45 ` github-actions
0 siblings, 1 reply; 2+ messages in thread
From: Piraty @ 2024-02-10 2:23 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 1258 bytes --]
There is a new pull request by Piraty against master on the void-packages repository
https://github.com/Piraty/void-packages new-libsolv
https://github.com/void-linux/void-packages/pull/48635
opkg: update to 0.6.3, switch to libsolv
<!-- Uncomment relevant sections and delete options which are not applicable -->
#### Testing the changes
- I tested the changes in this PR: **briefly**
<!--
#### New package
- This new package conforms to the [package requirements](https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#package-requirements): **YES**|**NO**
-->
<!-- Note: If the build is likely to take more than 2 hours, please add ci skip tag as described in
https://github.com/void-linux/void-packages/blob/master/CONTRIBUTING.md#continuous-integration
and test at least one native build and, if supported, at least one cross build.
Ignore this section if this PR is not skipping CI.
-->
<!--
#### Local build testing
- I built this PR locally for my native architecture, (ARCH-LIBC)
- I built this PR locally for these architectures (if supported. mark crossbuilds):
- aarch64-musl
- armv7l
- armv6l-musl
-->
A patch file from https://github.com/void-linux/void-packages/pull/48635.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-new-libsolv-48635.patch --]
[-- Type: text/x-diff, Size: 6640 bytes --]
From 074b18dca06d9e8663747d182a48827496f02178 Mon Sep 17 00:00:00 2001
From: Piraty <mail@piraty.dev>
Date: Sat, 10 Feb 2024 02:43:19 +0100
Subject: [PATCH 1/2] New package: libsolv-0.7.28
---
common/shlibs | 1 +
srcpkgs/libsolv-devel | 1 +
srcpkgs/libsolv-tools | 1 +
srcpkgs/libsolv/template | 40 ++++++++++++++++++++++++++++++++++++++++
4 files changed, 43 insertions(+)
create mode 120000 srcpkgs/libsolv-devel
create mode 120000 srcpkgs/libsolv-tools
create mode 100644 srcpkgs/libsolv/template
diff --git a/common/shlibs b/common/shlibs
index bf79a52760b09..3459f7f2b7fd6 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -1002,6 +1002,7 @@ libnilfs.so.0 libnilfs-2.1.0_1
libnilfsgc.so.0 libnilfs-2.1.0_1
libnilfscleaner.so.0 libnilfs-2.1.0_1
libchicken.so.11 libchicken-5.1.0_1
+libsolv.so.1 libsolv-0.7.28_1
libmdb.so.0 libmdb-0.5_1
libmdbsql.so.0 libmdb-0.5_1
libkmod.so.2 libkmod-5_1
diff --git a/srcpkgs/libsolv-devel b/srcpkgs/libsolv-devel
new file mode 120000
index 0000000000000..bbfd1569051b4
--- /dev/null
+++ b/srcpkgs/libsolv-devel
@@ -0,0 +1 @@
+libsolv
\ No newline at end of file
diff --git a/srcpkgs/libsolv-tools b/srcpkgs/libsolv-tools
new file mode 120000
index 0000000000000..bbfd1569051b4
--- /dev/null
+++ b/srcpkgs/libsolv-tools
@@ -0,0 +1 @@
+libsolv
\ No newline at end of file
diff --git a/srcpkgs/libsolv/template b/srcpkgs/libsolv/template
new file mode 100644
index 0000000000000..d7ca79098d907
--- /dev/null
+++ b/srcpkgs/libsolv/template
@@ -0,0 +1,40 @@
+# Template file for 'libsolv'
+pkgname=libsolv
+version=0.7.28
+revision=1
+build_style=cmake
+configure_args="-DENABLE_STATIC=ON
+ -DENABLE_ZSTD_COMPRESSION=ON
+ -DENABLE_DEBIAN=ON"
+makedepends="liblzma-devel zlib-devel libzstd-devel"
+short_desc="Package dependency solver using a satisfiability algorithm"
+maintainer="Piraty <mail@piraty.dev>"
+license="BSD-3-Clause"
+homepage="https://en.opensuse.org/openSUSE:Libzypp_satsolver"
+distfiles="https://github.com/openSUSE/libsolv/archive/refs/tags/${version}.tar.gz"
+checksum=bd2406f498fea6086ae0eacbf8b188c98b380e59af2267170e6a7b7d715cb207
+
+post_install() {
+ vlicense LICENSE.BSD
+}
+
+libsolv-tools_package() {
+ short_desc+=" - tools"
+ depends="${sourcepkg}>=${version}_${revision}"
+ pkg_install() {
+ vmove usr/bin
+ vmove usr/share/man/man1
+ }
+}
+
+libsolv-devel_package() {
+ short_desc+=" - development files"
+ depends="${sourcepkg}>=${version}_${revision}"
+ pkg_install() {
+ vmove usr/include
+ vmove "usr/lib/*.a"
+ vmove "usr/lib/*.so"
+ vmove usr/lib/pkgconfig
+ vmove usr/share/man/man3
+ }
+}
From 97d024c8a07919d11a335f221f3d6648d397160d Mon Sep 17 00:00:00 2001
From: Piraty <mail@piraty.dev>
Date: Sat, 10 Feb 2024 03:00:58 +0100
Subject: [PATCH 2/2] opkg: update to 0.6.3, switch to libsolv
---
...Use-libgen.h-to-provide-basename-API.patch | 60 +++++++++++++++++++
srcpkgs/opkg/template | 12 ++--
2 files changed, 67 insertions(+), 5 deletions(-)
create mode 100644 srcpkgs/opkg/patches/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch
diff --git a/srcpkgs/opkg/patches/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch b/srcpkgs/opkg/patches/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch
new file mode 100644
index 0000000000000..73cfe3f463f13
--- /dev/null
+++ b/srcpkgs/opkg/patches/0001-libopkg-Use-libgen.h-to-provide-basename-API.patch
@@ -0,0 +1,60 @@
+From 74fc3a991f974095644897d18d43846b5f359dae Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Sun, 10 Dec 2023 19:49:27 -0800
+Subject: [PATCH] libopkg: Use libgen.h to provide basename API
+
+Also ensure that copy of filename is passed into archive_entry_set_pathname
+so it can be operated upon by posix basename which expect non-const
+character pointer as input.
+
+This became evident with latest musl where basename declaration was
+dropped from string.h [1]
+
+[1] https://git.musl-libc.org/cgit/musl/commit/?id=725e17ed6dff4d0cd22487bb64470881e86a92e7
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Signed-off-by: Alex Stewart <alex.stewart@ni.com>
+---
+ libopkg/opkg_archive.c | 6 ++++--
+ libopkg/opkg_remove.c | 1 +
+ 2 files changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/libopkg/opkg_archive.c b/libopkg/opkg_archive.c
+index 8dd902d..23575b1 100644
+--- a/libopkg/opkg_archive.c
++++ b/libopkg/opkg_archive.c
+@@ -20,6 +20,7 @@
+
+ #include <archive.h>
+ #include <archive_entry.h>
++#include <libgen.h>
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <string.h>
+@@ -797,8 +798,9 @@ int gz_write_archive(const char *filename, const char *gz_filename)
+ }
+
+ /* Remove path hierarchy, as we are only compressing a single file */
+- archive_entry_set_pathname(entry, basename(filename));
+-
++ char* tmp = xstrdup(filename);
++ archive_entry_set_pathname(entry, basename(tmp));
++ free(tmp);
+ r = archive_write_header(a, entry);
+ if (r != ARCHIVE_OK) {
+ opkg_msg(ERROR, "Failed to create compressed file: '%s' : %s (errno=%d)",
+diff --git a/libopkg/opkg_remove.c b/libopkg/opkg_remove.c
+index 889c672..5254388 100644
+--- a/libopkg/opkg_remove.c
++++ b/libopkg/opkg_remove.c
+@@ -20,6 +20,7 @@
+
+ #include "config.h"
+
++#include <libgen.h>
+ #include <stdio.h>
+ #include <glob.h>
+ #include <unistd.h>
+--
+2.43.0
+
diff --git a/srcpkgs/opkg/template b/srcpkgs/opkg/template
index 82f802fb0db1d..4c3751f8346f7 100644
--- a/srcpkgs/opkg/template
+++ b/srcpkgs/opkg/template
@@ -1,19 +1,21 @@
# Template file for 'opkg'
pkgname=opkg
-version=0.6.1
-revision=2
+version=0.6.3
+revision=1
build_style=gnu-configure
-configure_args="--enable-sha256 --enable-zstd --without-libsolv --with-static-libopkg
+configure_args="--enable-sha256 --enable-zstd --without-libsolv
+ --with-static-libopkg --with-libsolv
$(vopt_if ssl '--enable-ssl-curl') $(vopt_enable gpg)"
hostmakedepends="pkg-config libtool automake"
-makedepends="libarchive-devel libcurl-devel libzstd-devel $(vopt_if gpg gpgme-devel)"
+makedepends="libarchive-devel libcurl-devel libsolv-devel libzstd-devel
+ $(vopt_if gpg gpgme-devel)"
checkdepends="python3"
short_desc="Lightweight package management system, compatible with ipkg"
maintainer="Piraty <mail@piraty.dev>"
license="GPL-2.0-or-later"
homepage="http://code.google.com/p/opkg/"
distfiles="https://downloads.yoctoproject.org/releases/opkg/opkg-${version}.tar.gz"
-checksum=e87fccb575c64d3ac0559444016a2795f12125986a0da896bab97c4a1a2f1b2a
+checksum=f3938e359646b406c40d5d442a1467c7e72357f91ab822e442697529641e06de
build_options="gpg lz4 ssl"
build_options_default="ssl"
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: opkg: update to 0.6.3, switch to libsolv
2024-02-10 2:23 [PR PATCH] opkg: update to 0.6.3, switch to libsolv Piraty
@ 2024-05-11 1:45 ` github-actions
0 siblings, 0 replies; 2+ messages in thread
From: github-actions @ 2024-05-11 1:45 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 305 bytes --]
New comment by github-actions[bot] on void-packages repository
https://github.com/void-linux/void-packages/pull/48635#issuecomment-2105439861
Comment:
Pull Requests become stale 90 days after last activity and are closed 14 days after that. If this pull request is still relevant bump it or assign it.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2024-05-11 1:45 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-02-10 2:23 [PR PATCH] opkg: update to 0.6.3, switch to libsolv Piraty
2024-05-11 1:45 ` github-actions
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).