summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMilan P. Stanić <mps@arvanta.net>2024-04-06 10:37:10 +0000
committerNatanael Copa <ncopa@alpinelinux.org>2024-04-08 06:12:22 +0000
commitd1feea5c41b7e8ab88a3f46bb9a1defe7f6849a6 (patch)
treece76a3ecba514d4314e6259ec43d12744d24544f
parenta28da69bd6195cb1a4c6db7c2bf974f16bb47640 (diff)
downloadaports-d1feea5c41b7e8ab88a3f46bb9a1defe7f6849a6.zip
main/lxc: upgrade to 6.0.0
add dbus-dev to makedepends, with this version it is needed remove Add-loongarch64-support.patch, merged upstream
-rw-r--r--main/lxc/APKBUILD7
-rw-r--r--main/lxc/Add-loongarch64-support.patch303
2 files changed, 3 insertions, 307 deletions
diff --git a/main/lxc/APKBUILD b/main/lxc/APKBUILD
index 7f63f8198ac..3cdfbb6d280 100644
--- a/main/lxc/APKBUILD
+++ b/main/lxc/APKBUILD
@@ -2,7 +2,7 @@
# Contributor: Jakub Jirutka <jakub@jirutka.cz>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=lxc
-pkgver=5.0.3
+pkgver=6.0.0
_pkgver=${pkgver/_rc/.rc}
pkgrel=0
pkgdesc="Userspace interface for the Linux kernel containment features"
@@ -10,6 +10,7 @@ url="https://linuxcontainers.org/lxc/"
arch="all"
license="LGPL-2.1-or-later"
makedepends="
+ dbus-dev
docbook2x
libapparmor-dev
libcap-dev
@@ -35,7 +36,6 @@ subpackages="
$pkgname-templates::noarch
"
source="https://linuxcontainers.org/downloads/lxc/lxc-$_pkgver.tar.gz
- Add-loongarch64-support.patch
lxc.initd
lxc.confd
"
@@ -167,8 +167,7 @@ bridge() {
}
sha512sums="
-0553be317431ab7ec0c450c0f85724a53de1f251c39c9716168e17cda6a8daec70b8221228c4be64027df28a327e0f1fd508e6bb48348ab540bbfeaf2b9ac974 lxc-5.0.3.tar.gz
-86149baace39cd96ddd7c664639cbcd0aed31c5eb8b210892d2471bf49be07ef034e0eb4528666cd36e0653a1e1596daabf6393541f3d84846f8fbb0e0c43481 Add-loongarch64-support.patch
+acff2fc70cf2c65af37b70a21239482c3d845c408f7132558b54980e4400c23670c63178a3a3dfb239f047f529004df93cd829d728852a8c8647ce6babf7857f lxc-6.0.0.tar.gz
db71783366277a68a5c8116604cf845da4780fe4aebdb5820ae2c4fe028cfe52a9c94246db362476f2f195be6a9c2b835edbe521423f116fc66eb50023d6daab lxc.initd
91de43db5369a9e10102933514d674e9c875218a1ff2910dd882e5b9c308f9e430deacb13d1d7e0b2ed1ef682d0bb035aa6f8a6738f54fa2ca3a05acce04e467 lxc.confd
"
diff --git a/main/lxc/Add-loongarch64-support.patch b/main/lxc/Add-loongarch64-support.patch
deleted file mode 100644
index fb7fe891b80..00000000000
--- a/main/lxc/Add-loongarch64-support.patch
+++ /dev/null
@@ -1,303 +0,0 @@
-From df17ac417e7baa686e54e391ed4ef049cd7fb63c Mon Sep 17 00:00:00 2001
-From: zhaixiaojuan <zhaixiaojuan@loongson.cn>
-Date: Thu, 2 Nov 2023 16:14:45 +0800
-Subject: [PATCH] Add loongarch64 support
-
-Signed-off-by: zhaixiaojuan <zhaixiaojuan@loongson.cn>
----
- README.md | 1 +
- config/bash/_lxc.in | 2 +-
- src/lxc/confile.c | 57 ++++++++++++++++++++-------------------
- src/lxc/seccomp.c | 19 +++++++++++++
- src/lxc/syscall_numbers.h | 26 ++++++++++++++++++
- src/tests/arch_parse.c | 9 ++++---
- 6 files changed, 81 insertions(+), 33 deletions(-)
-
-diff --git a/README.md b/README.md
-index 4ddb1c5cd..dd02b3eae 100644
---- a/README.md
-+++ b/README.md
-@@ -110,6 +110,7 @@ features. This includes (but isn't limited to):
- - riscv64
- - s390x
- - armvl7, arm64
-+- loongarch64
-
- LXC also supports at least the following C standard libraries:
-
-diff --git a/config/bash/_lxc.in b/config/bash/_lxc.in
-index 6672bf02d..8a7ce16af 100644
---- a/config/bash/_lxc.in
-+++ b/config/bash/_lxc.in
-@@ -285,7 +285,7 @@ _lxc_attach() {
- ;;
- --arch | -a )
- # https://github.com/lxc/lxc/blob/stable-4.0/src/tests/arch_parse.c#L37
-- COMPREPLY=( $( compgen -W 'arm armel armhf armv7l athlon i386 i486 i586 i686 linux32 mips mipsel ppc powerpc x86 aarch64 amd64 arm64 linux64 mips64 mips64el ppc64 ppc64el ppc64le powerpc64 riscv64 s390x x86_64' -- "${cur}" ) )
-+ COMPREPLY=( $( compgen -W 'arm armel armhf armv7l athlon i386 i486 i586 i686 linux32 mips mipsel ppc powerpc x86 aarch64 amd64 arm64 linux64 loongarch64 mips64 mips64el ppc64 ppc64el ppc64le powerpc64 riscv64 s390x x86_64' -- "${cur}" ) )
- return
- ;;
- --elevated-privileges | -e )
-diff --git a/src/lxc/confile.c b/src/lxc/confile.c
-index 7a8a53418..bccc54f1a 100644
---- a/src/lxc/confile.c
-+++ b/src/lxc/confile.c
-@@ -3254,34 +3254,35 @@ int lxc_config_parse_arch(const char *arch, signed long *persona)
- char *name;
- unsigned long per;
- } pername[] = {
-- { "arm", PER_LINUX32 },
-- { "armel", PER_LINUX32 },
-- { "armhf", PER_LINUX32 },
-- { "armv7l", PER_LINUX32 },
-- { "athlon", PER_LINUX32 },
-- { "i386", PER_LINUX32 },
-- { "i486", PER_LINUX32 },
-- { "i586", PER_LINUX32 },
-- { "i686", PER_LINUX32 },
-- { "linux32", PER_LINUX32 },
-- { "mips", PER_LINUX32 },
-- { "mipsel", PER_LINUX32 },
-- { "ppc", PER_LINUX32 },
-- { "powerpc", PER_LINUX32 },
-- { "x86", PER_LINUX32 },
-- { "aarch64", PER_LINUX },
-- { "amd64", PER_LINUX },
-- { "arm64", PER_LINUX },
-- { "linux64", PER_LINUX },
-- { "mips64", PER_LINUX },
-- { "mips64el", PER_LINUX },
-- { "ppc64", PER_LINUX },
-- { "ppc64el", PER_LINUX },
-- { "ppc64le", PER_LINUX },
-- { "powerpc64", PER_LINUX },
-- { "riscv64", PER_LINUX },
-- { "s390x", PER_LINUX },
-- { "x86_64", PER_LINUX },
-+ { "arm", PER_LINUX32 },
-+ { "armel", PER_LINUX32 },
-+ { "armhf", PER_LINUX32 },
-+ { "armv7l", PER_LINUX32 },
-+ { "athlon", PER_LINUX32 },
-+ { "i386", PER_LINUX32 },
-+ { "i486", PER_LINUX32 },
-+ { "i586", PER_LINUX32 },
-+ { "i686", PER_LINUX32 },
-+ { "linux32", PER_LINUX32 },
-+ { "mips", PER_LINUX32 },
-+ { "mipsel", PER_LINUX32 },
-+ { "ppc", PER_LINUX32 },
-+ { "powerpc", PER_LINUX32 },
-+ { "x86", PER_LINUX32 },
-+ { "aarch64", PER_LINUX },
-+ { "amd64", PER_LINUX },
-+ { "arm64", PER_LINUX },
-+ { "linux64", PER_LINUX },
-+ { "loongarch64", PER_LINUX },
-+ { "mips64", PER_LINUX },
-+ { "mips64el", PER_LINUX },
-+ { "ppc64", PER_LINUX },
-+ { "ppc64el", PER_LINUX },
-+ { "ppc64le", PER_LINUX },
-+ { "powerpc64", PER_LINUX },
-+ { "riscv64", PER_LINUX },
-+ { "s390x", PER_LINUX },
-+ { "x86_64", PER_LINUX },
- };
-
- for (size_t i = 0; i < ARRAY_SIZE(pername); i++) {
-diff --git a/src/lxc/seccomp.c b/src/lxc/seccomp.c
-index cefa18d0a..3ba54331d 100644
---- a/src/lxc/seccomp.c
-+++ b/src/lxc/seccomp.c
-@@ -315,6 +315,7 @@ enum lxc_hostarch_t {
- lxc_seccomp_arch_mipsel64n32,
- lxc_seccomp_arch_s390x,
- lxc_seccomp_arch_s390,
-+ lxc_seccomp_arch_loongarch64,
- lxc_seccomp_arch_unknown = 999,
- };
-
-@@ -349,6 +350,8 @@ static int get_hostarch(void)
- return lxc_seccomp_arch_s390x;
- else if (strnequal(uts.machine, "s390", 4))
- return lxc_seccomp_arch_s390;
-+ else if (strnequal(uts.machine, "loongarch64", 11))
-+ return lxc_seccomp_arch_loongarch64;
- return lxc_seccomp_arch_unknown;
- }
-
-@@ -421,6 +424,11 @@ static scmp_filter_ctx get_new_ctx(enum lxc_hostarch_t n_arch, uint32_t default_
- case lxc_seccomp_arch_s390:
- arch = SCMP_ARCH_S390;
- break;
-+#endif
-+#ifdef SCMP_ARCH_LOONGARCH64
-+ case lxc_seccomp_arch_loongarch64:
-+ arch = SCMP_ARCH_LOONGARCH64;
-+ break;
- #endif
- default:
- return NULL;
-@@ -967,6 +975,17 @@ static int parse_config_v2(FILE *f, char *line, size_t *line_bufsz, struct lxc_c
-
- cur_rule_arch = lxc_seccomp_arch_s390;
- }
-+#endif
-+#ifdef SCMP_ARCH_LOONGARCH64
-+ else if (strequal(line, "[loongarch64]") ||
-+ strequal(line, "[LOONGARCH64]")) {
-+ if (native_arch != lxc_seccomp_arch_loongarch64) {
-+ cur_rule_arch = lxc_seccomp_arch_unknown;
-+ continue;
-+ }
-+
-+ cur_rule_arch = lxc_seccomp_arch_loongarch64;
-+ }
- #endif
- else {
- goto bad_arch;
-diff --git a/src/lxc/syscall_numbers.h b/src/lxc/syscall_numbers.h
-index ae5fdd064..58840a598 100644
---- a/src/lxc/syscall_numbers.h
-+++ b/src/lxc/syscall_numbers.h
-@@ -50,6 +50,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_keyctl 5241
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_keyctl 219
- #else
- #define -1
- #warning "__NR_keyctl not defined for your architecture"
-@@ -87,6 +89,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64
- #define __NR_memfd_create 5314
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_memfd_create 279
- #else
- #define -1
- #warning "__NR_memfd_create not defined for your architecture"
-@@ -122,6 +126,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_pivot_root 5151
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_pivot_root 41
- #else
- #define -1
- #warning "__NR_pivot_root not defined for your architecture"
-@@ -157,6 +163,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_setns 5303
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_setns 268
- #else
- #define -1
- #warning "__NR_setns not defined for your architecture"
-@@ -192,6 +200,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_sethostname 5165
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_sethostname 161
- #else
- #define -1
- #warning "__NR_sethostname not defined for your architecture"
-@@ -259,6 +269,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_signalfd4 5283
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_signalfd4 74
- #else
- #define -1
- #warning "__NR_signalfd4 not defined for your architecture"
-@@ -294,6 +306,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_unshare 5262
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_unshare 97
- #else
- #define -1
- #warning "__NR_unshare not defined for your architecture"
-@@ -329,6 +343,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_bpf 5315
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_bpf 280
- #else
- #define -1
- #warning "__NR_bpf not defined for your architecture"
-@@ -364,6 +380,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_faccessat 5259
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_faccessat 48
- #else
- #define -1
- #warning "__NR_faccessat not defined for your architecture"
-@@ -419,6 +437,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_seccomp 5312
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_seccomp 277
- #else
- #define -1
- #warning "__NR_seccomp not defined for your architecture"
-@@ -454,6 +474,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_gettid 5178
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_gettid 178
- #else
- #define -1
- #warning "__NR_gettid not defined for your architecture"
-@@ -493,6 +515,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_execveat 5316
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_execveat 281
- #else
- #define -1
- #warning "__NR_execveat not defined for your architecture"
-@@ -732,6 +756,8 @@
- #if _MIPS_SIM == _MIPS_SIM_ABI64 /* n64 */
- #define __NR_personality (132 + 5000)
- #endif
-+ #elif defined __loongarch64
-+ #define __NR_personality 92
- #else
- #define -1
- #warning "__NR_personality not defined for your architecture"
-diff --git a/src/tests/arch_parse.c b/src/tests/arch_parse.c
-index 6d72d664d..f8b4d8a0a 100644
---- a/src/tests/arch_parse.c
-+++ b/src/tests/arch_parse.c
-@@ -37,10 +37,11 @@
- #endif
-
- static const char *const arches[] = {
-- "arm", "armel", "armhf", "armv7l", "athlon", "i386", "i486",
-- "i586", "i686", "linux32", "mips", "mipsel", "ppc", "powerpc",
-- "x86", "aarch64", "amd64", "arm64", "linux64", "mips64", "mips64el",
-- "ppc64", "ppc64el", "ppc64le", "powerpc64", "riscv64", "s390x", "x86_64",
-+ "arm", "armel", "armhf", "armv7l", "athlon", "i386", "i486",
-+ "i586", "i686", "linux32", "mips", "mipsel", "ppc", "powerpc",
-+ "x86", "aarch64", "amd64", "arm64", "linux64", "loongarch64", "mips64",
-+ "mips64el", "ppc64", "ppc64el", "ppc64le", "powerpc64", "riscv64", "s390x",
-+ "x86_64",
- };
-
- static bool parse_valid_architectures(void)
---
-2.27.0
-