Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] Capstone 5.0
@ 2023-07-10 15:18 motorto
  2023-07-10 17:09 ` [PR PATCH] [Updated] " motorto
                   ` (32 more replies)
  0 siblings, 33 replies; 34+ messages in thread
From: motorto @ 2023-07-10 15:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 556 bytes --]

There is a new pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc



A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 7761 bytes --]

From 1432af3edcc928082fd1aa8c8fbebe0c7304b120 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 1/9] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 4b2122d1b199..3bc4258061ad 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2129,7 +2129,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b..e4c157effe2c 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From e244a3423f1c4b1ba382d46b1e7f58eb5543316c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 2/9] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 226d2f30ffcd..2a79fb502f99 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=11
+revision=12
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 9eadfc301755d8ecae0c4e69378a328127d831c6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 3/9] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6a..d8829c693e85 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,7 +1,7 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"

From d28c28b928874ef582fd9db7944beeb0ebc38d48 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 4/9] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index 91e73f4574ee..0e47747c5cab 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.3.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From bc4b2e0e60231eb61ebb852b15f400041f6fa988 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 5/9] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35de..f88e96193947 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From 7a17d671e3fe5c7e285cf9fcca66a5f87f2eeab9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 6/9] qemu: rebuild for capstone-5.0.

---
 srcpkgs/qemu/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686..6f2c6ee51383 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie

From bd362458379a78a110b252acd3562f74e41ebcc9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 7/9] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae8918..f38c84efa1d2 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From d276762e14ccbc77df4de0b79eed595a73ade5b4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 8/9] rizin: rebuild for capstone-5.0.

---
 srcpkgs/rizin/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45..4888fc014d3b 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,7 +1,7 @@
 # Template file for 'rizin'
 pkgname=rizin
 version=0.5.2
-revision=1
+revision=2
 build_style=meson
 configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled

From 071ed10eb14fd5a56ae74b22fbff39d42b3d8d4f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 9/9] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f..3e7690e4ea90 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
@ 2023-07-10 17:09 ` motorto
  2023-07-12  0:13 ` [PR REVIEW] " classabbyamp
                   ` (31 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-07-10 17:09 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 561 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc



A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 10284 bytes --]

From 2f4b29b695bbefa8f024ac83bbecac039400bcde Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 1/9] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 4b2122d1b199..3bc4258061ad 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2129,7 +2129,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b..e4c157effe2c 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From b51bd63672fa8fdc41b6304f80c98d96b9ea1e69 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 2/9] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 226d2f30ffcd..2a79fb502f99 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=11
+revision=12
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 8fb4553c5b6e459ebec07535a0480908e203bb1d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 3/9] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6a..d8829c693e85 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,7 +1,7 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"

From 0bd7bf3faf7e792426ab9e97046c49d370401b06 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 4/9] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index 91e73f4574ee..0e47747c5cab 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.3.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 0bf8db1a374a2a76c8ab4f1ba7a2bf7a948be8c3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 5/9] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35de..f88e96193947 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From 0b74f67df48d7b4ab419b09ee252cdb61e7786fb Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 6/9] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae8918..f38c84efa1d2 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From 742c57e6c285a3cfcdcd2b8556a78be2853e4c18 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 7/9] rizin: rebuild for capstone-5.0.

---
 srcpkgs/rizin/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45..4888fc014d3b 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,7 +1,7 @@
 # Template file for 'rizin'
 pkgname=rizin
 version=0.5.2
-revision=1
+revision=2
 build_style=meson
 configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled

From 68644c25d3de158f914b568bca7a818cd52d46ae Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 8/9] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f..3e7690e4ea90 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From fe5c0ff5d690d5275e45268980f99e22f580810a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 9/9] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  2 +-
 2 files changed, 61 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 000000000000..f7f621f81170
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686..6f2c6ee51383 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR REVIEW] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
  2023-07-10 17:09 ` [PR PATCH] [Updated] " motorto
@ 2023-07-12  0:13 ` classabbyamp
  2023-07-12  0:21 ` classabbyamp
                   ` (30 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: classabbyamp @ 2023-07-12  0:13 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 234 bytes --]

New review comment by classabbyamp on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#discussion_r1260414487

Comment:
needs python3 in hostmakedepends (and can probably be removed from checkdepends?)

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
  2023-07-10 17:09 ` [PR PATCH] [Updated] " motorto
  2023-07-12  0:13 ` [PR REVIEW] " classabbyamp
@ 2023-07-12  0:21 ` classabbyamp
  2023-07-12 15:31 ` [PR PATCH] [Updated] " motorto
                   ` (29 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: classabbyamp @ 2023-07-12  0:21 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 1658 bytes --]

New comment by classabbyamp on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1631673381

Comment:
would you mind adding this patch to the PR? I've tested it and it works.

```patch
From 681f1c71fe0ffe780407365ebbd91efdfc3fb8b9 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH] imhex: use system capstone

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f475038..94a058c2b1 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"
-- 
2.41.0
```

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (2 preceding siblings ...)
  2023-07-12  0:21 ` classabbyamp
@ 2023-07-12 15:31 ` motorto
  2023-07-12 15:31 ` motorto
                   ` (28 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-07-12 15:31 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 646 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

Edit: makes one qemu test fail (checking now if with the updated qemu the test fails)

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 11956 bytes --]

From 879f71d16d5d85964415e5e6e23f62cc0dafe8e8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/10] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 4b2122d1b199..3bc4258061ad 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2129,7 +2129,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b..e4c157effe2c 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From cbc3fd6b0ad6bde78cbf17dc48fb9dbaec74ad01 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 02/10] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 226d2f30ffcd..2a79fb502f99 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=11
+revision=12
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 2edf26c3aba4c2fd6cda302754baa3ecd58eb2c1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 03/10] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6a..92cd85b4076a 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,13 +1,12 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"

From 94868b20bac52c3b7c0540cae4d86b6e90713fc7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 04/10] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index 91e73f4574ee..0e47747c5cab 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.3.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 2d668700e70d64c9ba79b11067a4e8ba45f6a757 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 05/10] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35de..f88e96193947 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From f3706441055a0e3b3ce4ecabf49ac4ecada56cb1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 06/10] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae8918..f38c84efa1d2 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From fa488cc3dc16a261fd01353592e8c11c756182c8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 07/10] rizin: rebuild for capstone-5.0.

---
 srcpkgs/rizin/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45..4888fc014d3b 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,7 +1,7 @@
 # Template file for 'rizin'
 pkgname=rizin
 version=0.5.2
-revision=1
+revision=2
 build_style=meson
 configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled

From 2028b32dea7bab2760800dc6df45850b9ef9bcf3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 08/10] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f..3e7690e4ea90 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From 6a9c2e42317ea6c696cdc4bedd60e160cdd494ea Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 09/10] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  2 +-
 2 files changed, 61 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 000000000000..f7f621f81170
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686..6f2c6ee51383 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie

From e688f5c50d52f148631431febe6ccf09a469402e Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 10/10] imhex: use system capstone

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389e..94a058c2b163 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (3 preceding siblings ...)
  2023-07-12 15:31 ` [PR PATCH] [Updated] " motorto
@ 2023-07-12 15:31 ` motorto
  2023-07-14  9:07 ` motorto
                   ` (27 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-07-12 15:31 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 646 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

Edit: makes one qemu test fail (checking now if with the updated qemu the test fails)

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 11956 bytes --]

From f10552cc6eb89a16b5b9bc0edea03d78b45d7760 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/10] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 4b2122d1b199..3bc4258061ad 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2129,7 +2129,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b..e4c157effe2c 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From e990a5daf713374c6947c9be51db68946e6ab381 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 02/10] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 226d2f30ffcd..2a79fb502f99 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=11
+revision=12
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From a6996bfc7895be00632a1c334738dd7bf073f33a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 03/10] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6a..92cd85b4076a 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,13 +1,12 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"

From bdbf9149cffc7e112a0f7329a19cffa9f5c9d5b1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 04/10] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index 91e73f4574ee..0e47747c5cab 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.3.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From a36e3f69243057488e6442787b91cac8972335a7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 05/10] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35de..f88e96193947 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From 0723b9e81972be07cdf8dcdf3436b8f873ca3b17 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 06/10] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae8918..f38c84efa1d2 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From bf8fb3670dadb80700b07b4e5d945af97f9349d0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 07/10] rizin: rebuild for capstone-5.0.

---
 srcpkgs/rizin/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45..4888fc014d3b 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,7 +1,7 @@
 # Template file for 'rizin'
 pkgname=rizin
 version=0.5.2
-revision=1
+revision=2
 build_style=meson
 configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled

From 1c9ba10d0a6791f49509527ce795e0216a487643 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 08/10] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f..3e7690e4ea90 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From e78dc248bc5b64dc6e17f3558ac76451f8789319 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 09/10] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  2 +-
 2 files changed, 61 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 000000000000..f7f621f81170
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686..6f2c6ee51383 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie

From dcc4ca9ae98f2e39aa9b6bf9da5b8053fbbdc5ca Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 10/10] imhex: use system capstone

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389e..94a058c2b163 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (4 preceding siblings ...)
  2023-07-12 15:31 ` motorto
@ 2023-07-14  9:07 ` motorto
  2023-07-15 13:17 ` motorto
                   ` (26 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-07-14  9:07 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 646 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

Edit: makes one qemu test fail (checking now if with the updated qemu the test fails)

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 12774 bytes --]

From 6783fc7eea907348a984bb577f36fa712504d306 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/10] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 4b2122d1b199..3bc4258061ad 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2129,7 +2129,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b..e4c157effe2c 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 8dffc4edf31a71b3f741043b3637e1c5bfc40072 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 02/10] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 226d2f30ffcd..2a79fb502f99 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=11
+revision=12
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From b30f686215bdc12df5b969f2623b7160b65fe842 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 03/10] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6a..92cd85b4076a 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,13 +1,12 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"

From fef925648c14fe495e3e86697f2b308a357bc7d6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 04/10] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index 91e73f4574ee..0e47747c5cab 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.3.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From db1f6c4ab83abee0e8a39d4ed25dee5bc47ac898 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 05/10] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35de..f88e96193947 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From 7a2987f5c6151ac7865c369e7f84b63d43fd755f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 06/10] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae8918..f38c84efa1d2 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From bbdb0bdc2ea2cce559116eb4ce4b872a48aae611 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 07/10] rizin: rebuild for capstone-5.0.

---
 srcpkgs/rizin/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45..4888fc014d3b 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,7 +1,7 @@
 # Template file for 'rizin'
 pkgname=rizin
 version=0.5.2
-revision=1
+revision=2
 build_style=meson
 configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled

From 1d0e1f2ef0399c16dd9859568ce2e5116feff9c0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 08/10] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f..3e7690e4ea90 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From e3b8de01ec61ba98fdbb9eab5fc2517b764cba10 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 09/10] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 000000000000..f7f621f81170
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686..9793e2f6101a 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From 000296a965cfd3f119246cbd2d942c4683c78c8d Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 10/10] imhex: use system capstone

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389e..94a058c2b163 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (5 preceding siblings ...)
  2023-07-14  9:07 ` motorto
@ 2023-07-15 13:17 ` motorto
  2023-07-15 16:34 ` XVilka
                   ` (25 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-07-15 13:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 646 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

Edit: makes one qemu test fail (checking now if with the updated qemu the test fails)

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 14721 bytes --]

From 3ff41f043a3936462401c0ede6879b1a5ef7ee46 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/10] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 4b2122d1b199..3bc4258061ad 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2129,7 +2129,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b..e4c157effe2c 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 860ae5e0be7308c787bfd57d083d9c2ec4d3c213 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 02/10] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 226d2f30ffcd..2a79fb502f99 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=11
+revision=12
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From ac66e6b1f1a6cfdd3c819a0bba56f2a87b1d7a15 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 03/10] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6a..92cd85b4076a 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,13 +1,12 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"

From 486772dfca8a4c4408f464792f3b9e7a44806716 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 04/10] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/patches/capstone5.patch | 38 ++++++++++++++++++++
 srcpkgs/edb-debugger/template                |  2 +-
 2 files changed, 39 insertions(+), 1 deletion(-)
 create mode 100644 srcpkgs/edb-debugger/patches/capstone5.patch

diff --git a/srcpkgs/edb-debugger/patches/capstone5.patch b/srcpkgs/edb-debugger/patches/capstone5.patch
new file mode 100644
index 000000000000..0dc949f57adf
--- /dev/null
+++ b/srcpkgs/edb-debugger/patches/capstone5.patch
@@ -0,0 +1,38 @@
+From b1bc4d02bfc7ca9c871e7b518aeb795d83e7f88b Mon Sep 17 00:00:00 2001
+From: Sam James <sam@cmpct.info>
+Date: Tue, 13 Sep 2022 19:51:08 +0100
+Subject: [PATCH] Fix build with Capstone 5 (#824)
+
+Capstone 5 drops X86_INS_VCVTPD2DQX and X86_INS_VCVTPD2PSX from
+x86.h (happened in https://github.com/capstone-engine/capstone/commit/dd91f03fef5102492352756e2adb5972dd79a70f
+but no real explanation).
+
+Given:
+1. these instructions had no wiring up;
+2. other Capstone consumers have done the same
+let's drop them entirely as we have no idea what they are. They don't
+appear in any Intel documentation and there's very little reference
+to them online at all.
+
+Bug: https://bugs.gentoo.org/843755
+Closes: https://github.com/eteran/edb-debugger/issues/823
+Signed-off-by: Sam James <sam@gentoo.org>
+
+Signed-off-by: Sam James <sam@gentoo.org>
+---
+ src/capstone-edb/Instruction.cpp | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/src/capstone-edb/Instruction.cpp b/src/capstone-edb/Instruction.cpp
+index 7b2dfc8ae..e5fe0f1b0 100644
+--- a/src/capstone-edb/Instruction.cpp
++++ b/src/capstone-edb/Instruction.cpp
+@@ -880,8 +880,6 @@ bool is_SIMD_PD(const Operand &operand) {
+ 	case X86_INS_CVTPD2PI:
+ 	case X86_INS_CVTPD2PS:
+ 	case X86_INS_VCVTPD2PS:
+-	case X86_INS_VCVTPD2DQX: // FIXME: what's this?
+-	case X86_INS_VCVTPD2PSX: // FIXME: what's this?
+ 	// case X86_INS_VCVTPD2QQ: // FIXME: Capstone seems to not support it
+ 	case X86_INS_VCVTPD2UDQ:
+ 		// case X86_INS_VCVTPD2UQQ: // FIXME: Capstone seems to not support it
diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index 91e73f4574ee..0e47747c5cab 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.3.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 7534a785934d2c4d4be9761ee18100fa0baf2f24 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 05/10] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35de..f88e96193947 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From e73dffce807ae0310ed1c6b845052f122a54ec22 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 06/10] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae8918..f38c84efa1d2 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From 1c787d9c2342e6a17a1c419df255d64a25f88788 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 07/10] rizin: rebuild for capstone-5.0.

---
 srcpkgs/rizin/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45..4888fc014d3b 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,7 +1,7 @@
 # Template file for 'rizin'
 pkgname=rizin
 version=0.5.2
-revision=1
+revision=2
 build_style=meson
 configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled

From 13e0e07264fc7420edb9f2733ef34faffe0491ed Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 08/10] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f..3e7690e4ea90 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From bd9278ac378493ff69f67a4f78db1ecc47ddeaff Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 09/10] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 000000000000..f7f621f81170
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686..9793e2f6101a 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From 37d79ea08e94fccc4618a4034dfa8dca74b477dc Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 10/10] imhex: use system capstone

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389e..94a058c2b163 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (6 preceding siblings ...)
  2023-07-15 13:17 ` motorto
@ 2023-07-15 16:34 ` XVilka
  2023-07-15 19:35 ` motorto
                   ` (24 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: XVilka @ 2023-07-15 16:34 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 584 bytes --]

New comment by XVilka on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1636818288

Comment:
@motorto I see you updated Rizin to use capstone. It is not currently supported for all releases; it requires https://github.com/rizinorg/rizin/pull/3653 to be merged first to fix all tests and mitigate some capstone regressions.  We will support capstone starting the next release (0.6.0), which is planned soon (a few weeks or so). While it *might* compile, the results could sometimes be incorrect. It's better to wait for the next release.

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (7 preceding siblings ...)
  2023-07-15 16:34 ` XVilka
@ 2023-07-15 19:35 ` motorto
  2023-07-31 11:51 ` [PR PATCH] [Updated] " motorto
                   ` (23 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-07-15 19:35 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 678 bytes --]

New comment by motorto on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1636870582

Comment:
> @motorto I see you updated Rizin to use capstone. It is not currently supported for all releases; it requires [rizinorg/rizin#3653](https://github.com/rizinorg/rizin/pull/3653) to be merged first to fix all tests and mitigate some capstone regressions. We will support capstone starting the next release (0.6.0), which is planned soon (a few weeks or so). While it _might_ compile, the results could sometimes be incorrect. It's better to wait for the next release.

Appreciate your insight. We will wait for the rizin release then.

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (8 preceding siblings ...)
  2023-07-15 19:35 ` motorto
@ 2023-07-31 11:51 ` motorto
  2023-08-05  7:01 ` XVilka
                   ` (22 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-07-31 11:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 693 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277 (need rizin update)

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 17269 bytes --]

From 18f49cbda60cd7e3c030ddc92464aa323fe089ba Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/10] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index c71817b11b51f..474d196f38b18 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2130,7 +2130,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..e4c157effe2cd 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 5af11c52d6d82ae58212898d31447b41dfe34176 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:58:46 +0100
Subject: [PATCH 02/10] edb-debugger: update to 1.4.0.

---
 .../edb-debugger/patches/QPainterPath.patch   | 10 ------
 srcpkgs/edb-debugger/patches/fix-musl.patch   | 16 ---------
 srcpkgs/edb-debugger/patches/gcc12.patch      | 33 -------------------
 .../edb-debugger/patches/include-limits.patch | 10 ------
 srcpkgs/edb-debugger/template                 |  8 ++---
 5 files changed, 4 insertions(+), 73 deletions(-)
 delete mode 100644 srcpkgs/edb-debugger/patches/QPainterPath.patch
 delete mode 100644 srcpkgs/edb-debugger/patches/fix-musl.patch
 delete mode 100644 srcpkgs/edb-debugger/patches/gcc12.patch
 delete mode 100644 srcpkgs/edb-debugger/patches/include-limits.patch

diff --git a/srcpkgs/edb-debugger/patches/QPainterPath.patch b/srcpkgs/edb-debugger/patches/QPainterPath.patch
deleted file mode 100644
index 16d1e93fffca4..0000000000000
--- a/srcpkgs/edb-debugger/patches/QPainterPath.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/src/widgets/QDisassemblyView.cpp	2020-04-10 21:07:19.000000000 +0200
-+++ b/src/widgets/QDisassemblyView.cpp	2020-09-01 01:29:20.286597335 +0200
-@@ -40,6 +40,7 @@
- #include <QElapsedTimer>
- #include <QMouseEvent>
- #include <QPainter>
-+#include <QPainterPath>
- #include <QPixmap>
- #include <QScrollBar>
- #include <QSettings>
diff --git a/srcpkgs/edb-debugger/patches/fix-musl.patch b/srcpkgs/edb-debugger/patches/fix-musl.patch
deleted file mode 100644
index da7ec85f72e21..0000000000000
--- a/srcpkgs/edb-debugger/patches/fix-musl.patch
+++ /dev/null
@@ -1,16 +0,0 @@
-Source: maxice8
-Upstream: no
-Reason: fixes compilation by avoiding using __ptrace_request as an enum.
-
---- a/plugins/DebuggerCore/unix/linux/arch/x86-generic/PlatformThread.cpp
-+++ b/plugins/DebuggerCore/unix/linux/arch/x86-generic/PlatformThread.cpp
-@@ -33,6 +33,10 @@ along with this program.  If not, see <http://www.gnu.org/licenses/>.
- #include <sys/ptrace.h>
- #include <sys/user.h>
- 
-+#ifndef __GLIBC__
-+#define __ptrace_request int
-+#endif
-+
- // doesn't always seem to be defined in the headers
- #ifndef PTRACE_GET_THREAD_AREA
diff --git a/srcpkgs/edb-debugger/patches/gcc12.patch b/srcpkgs/edb-debugger/patches/gcc12.patch
deleted file mode 100644
index 931dc45943b6e..0000000000000
--- a/srcpkgs/edb-debugger/patches/gcc12.patch
+++ /dev/null
@@ -1,33 +0,0 @@
-diff --color -ruN 1/include/IState.h 2/include/IState.h
---- 1/include/IState.h	2020-12-14 02:09:07.000000000 +0100
-+++ 2/include/IState.h	2022-06-22 05:48:20.394258961 +0200
-@@ -19,6 +19,7 @@
- #ifndef ISTATE_H_20110315_
- #define ISTATE_H_20110315_
- 
-+#include <memory>
- #include "Register.h"
- #include "Types.h"
- 
-diff --color -ruN 1/include/RegisterViewModelBase.h 2/include/RegisterViewModelBase.h
---- 1/include/RegisterViewModelBase.h	2020-12-14 02:09:07.000000000 +0100
-+++ 2/include/RegisterViewModelBase.h	2022-06-22 05:49:05.600877962 +0200
-@@ -6,6 +6,7 @@
- #include "util/Integer.h"
- #include <QAbstractItemModel>
- #include <deque>
-+#include <memory>
- #include <vector>
- 
- Q_DECLARE_METATYPE(std::vector<NumberDisplayMode>)
-diff --color -ruN 1/include/State.h 2/include/State.h
---- 1/include/State.h	2020-12-14 02:09:07.000000000 +0100
-+++ 2/include/State.h	2022-06-22 05:49:27.911029610 +0200
-@@ -19,6 +19,7 @@
- #ifndef STATE_H_20060715_
- #define STATE_H_20060715_
- 
-+#include <memory>
- #include "API.h"
- #include "Types.h"
- 
diff --git a/srcpkgs/edb-debugger/patches/include-limits.patch b/srcpkgs/edb-debugger/patches/include-limits.patch
deleted file mode 100644
index e12cca124c3ce..0000000000000
--- a/srcpkgs/edb-debugger/patches/include-limits.patch
+++ /dev/null
@@ -1,10 +0,0 @@
---- a/include/ByteShiftArray.h	2019-08-16 23:27:51.186731499 +0200
-+++ b/include/ByteShiftArray.h	2019-08-16 23:28:15.909729902 +0200
-@@ -22,6 +22,7 @@
- #include "API.h"
- #include <QVector>
- #include <cstddef>
-+#include <limits.h>
- 
- class EDB_EXPORT ByteShiftArray {
- 	Q_DISABLE_COPY(ByteShiftArray)
diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index 91e73f4574eed..512698fcc984f 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,8 +1,8 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
-version=1.3.0
+version=1.4.0
 revision=1
-archs="x86_64* i686*"
+archs="x86_64* i686* aarch64*"
 build_style=cmake
 hostmakedepends='pkg-config'
 makedepends="capstone-devel graphviz-devel boost-devel qt5-devel qt5-xmlpatterns-devel qt5-svg-devel"
@@ -10,5 +10,5 @@ short_desc="Cross platform x86/x86-64 debugger"
 maintainer="DirectorX <void.directorx@protonmail.com>"
 license="GPL-2.0-or-later"
 homepage="https://github.com/eteran/edb-debugger"
-distfiles="${homepage}/releases/download/${version}/${pkgname}-${version}.tgz"
-checksum=86df4a0940a39c1480a6fc789f167f94e87a7a330f2d8163fe871f42c754afe8
+distfiles="https://github.com/eteran/edb-debugger/releases/download/${version}/${pkgname}-${version}.tgz"
+checksum=0eb2c5d17493ab0e7e0a0748eefa5733ec90329631cc8db87f2943e90f91b726

From 9fe03b8223f888a5b1330719ef6a6dcf98978dc2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:59:25 +0100
Subject: [PATCH 03/10] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 2a79fb502f99e..f3c694d36a248 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=12
+revision=13
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 70e381d659963e21ce326492da83f81080f36e6a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 04/10] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6ad..92cd85b4076ab 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,13 +1,12 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"

From ec7c618a1846f32919f45a56884d8b8bfeedb55a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 05/10] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35def..f88e961939472 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From 8aac032c5d5fde045ec2c997984b4966f74b4708 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 06/10] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae89186..f38c84efa1d21 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From 5cc78f2572a0eeb2a53651e98d7e00b663018603 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 07/10] rizin: rebuild for capstone-5.0.

---
 srcpkgs/rizin/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45b..4888fc014d3b4 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,7 +1,7 @@
 # Template file for 'rizin'
 pkgname=rizin
 version=0.5.2
-revision=1
+revision=2
 build_style=meson
 configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled

From 9d76a28c90b5f415da64f0cf206f1d9a8036d545 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 08/10] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From 30e34c268788edf646860db5707a00d3e70cec16 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 09/10] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From bfc34e7fca3741ab3573f319e852da33fdab1e91 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 10/10] imhex: use system capstone

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389ec..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (9 preceding siblings ...)
  2023-07-31 11:51 ` [PR PATCH] [Updated] " motorto
@ 2023-08-05  7:01 ` XVilka
  2023-08-05  7:03 ` XVilka
                   ` (21 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: XVilka @ 2023-08-05  7:01 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 291 bytes --]

New comment by XVilka on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1666418560

Comment:
@motorto [Rizin 0.6.0](https://github.com/rizinorg/rizin/releases/tag/v0.6.0) and Cutter 2.3.0 that support capstone 5.0 are out, sorry for the delay.

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (10 preceding siblings ...)
  2023-08-05  7:01 ` XVilka
@ 2023-08-05  7:03 ` XVilka
  2023-08-07 15:34 ` [PR PATCH] [Updated] " motorto
                   ` (20 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: XVilka @ 2023-08-05  7:03 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 349 bytes --]

New comment by XVilka on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1666418560

Comment:
@motorto [Rizin 0.6.0](https://github.com/rizinorg/rizin/releases/tag/v0.6.0) and [Cutter 2.3.0](https://github.com/rizinorg/cutter/releases/tag/v2.3.0) that support capstone 5.0 are out, sorry for the delay.

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (11 preceding siblings ...)
  2023-08-05  7:03 ` XVilka
@ 2023-08-07 15:34 ` motorto
  2023-08-07 15:37 ` motorto
                   ` (19 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-07 15:34 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 693 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277 (need rizin update)

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 17449 bytes --]

From 88007a30f36abfe1883b2032416c5b3b23797d0e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index ddb0e8ab87091..73cc88939d95b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2132,7 +2132,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..e4c157effe2cd 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 33f5a1f521f379c95fc8b33fe11d620db61f65c4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.0.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  6 ++---
 2 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 73cc88939d95b..4b0d8a5fdf67f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4145,32 +4145,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45b..0d4cf4b1d96de 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
+version=0.6.0
 revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=6a924906efdf547ac50462767f5add53902436e7a4862d2c0e24ca91b7761508
 # requires some external files, not clear where they come from
 make_check=no
 

From ab82500e44aed3e3a07ef5b85559a7943a009acf Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.0.

---
 srcpkgs/cutter/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..433ced211594a 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.0
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins

From 01fe7165ab439236dc9918617a39ff9960be8ece Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From 704102abec9323c305f33d0a94330849b2d04b54 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389ec..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From e39c44e16662e3c10a5ce87e50606f4750c5f2d7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:59:25 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 2a79fb502f99e..f3c694d36a248 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=12
+revision=13
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 59e47584ee3f69a816d92ab936075c927962b4db Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6ad..92cd85b4076ab 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,13 +1,12 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"

From d5361e07f83a6bced171a0790dcb5f1642ce6f0b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 08/12] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35def..f88e961939472 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From b4d0c8a5095b81f53ed38ec56584d47c49323da0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 09/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae89186..f38c84efa1d21 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From 001495030d74925e48b4a368460c314bce9753d4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 10/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From 90fbbb9efe4da9503df50aec7fd7bbed0c322487 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 11/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From 9b957bd034115e41d51112e1c6a1874192be8346 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 12/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (12 preceding siblings ...)
  2023-08-07 15:34 ` [PR PATCH] [Updated] " motorto
@ 2023-08-07 15:37 ` motorto
  2023-08-07 15:56 ` [PR PATCH] [Updated] " motorto
                   ` (18 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-07 15:37 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 449 bytes --]

New comment by motorto on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1668106985

Comment:
> @motorto [Rizin 0.6.0](https://github.com/rizinorg/rizin/releases/tag/v0.6.0) and [Cutter 2.3.0](https://github.com/rizinorg/cutter/releases/tag/v2.3.0) that support capstone 5.0 are out, sorry for the delay.

Hey, thanks for the heads up. No need to apologize we are all doing this in our free time :) 

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (13 preceding siblings ...)
  2023-08-07 15:37 ` motorto
@ 2023-08-07 15:56 ` motorto
  2023-08-09 14:04 ` motorto
                   ` (17 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-07 15:56 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 693 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277 (need rizin update)

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 17923 bytes --]

From 88007a30f36abfe1883b2032416c5b3b23797d0e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index ddb0e8ab87091..73cc88939d95b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2132,7 +2132,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..e4c157effe2cd 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 33f5a1f521f379c95fc8b33fe11d620db61f65c4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.0.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  6 ++---
 2 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 73cc88939d95b..4b0d8a5fdf67f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4145,32 +4145,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45b..0d4cf4b1d96de 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
+version=0.6.0
 revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=6a924906efdf547ac50462767f5add53902436e7a4862d2c0e24ca91b7761508
 # requires some external files, not clear where they come from
 make_check=no
 

From 1523668c812de98b17ca62f83087e14d16f0794e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.0.

---
 srcpkgs/cutter/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..192df7be75ce3 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.0
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins
@@ -17,7 +17,7 @@ maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
 license="GPL-3.0-only"
 homepage="https://cutter.re"
 distfiles="https://github.com/rizinorg/cutter/releases/download/v${version}/Cutter-v${version}-src.tar.gz"
-checksum=883746c557f76ff336ce4efd42a81bc1052a5c06c3679aacae84d8bda3de1f58
+checksum=dd47e3680cdd5466495916db69fb40bb70fa04cdcb89d8a7de550c5bffccb79f
 
 cutter-devel_package() {
 	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"

From cc189988151e57f214a9dafad8509c5b3fd5f5d9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From 650df6bc77b9de05b2044fbb1d500c3a0f19e769 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389ec..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From ce08790bc0b4a9bfab5ca42b62138eebdcd08aac Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:59:25 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 2a79fb502f99e..f3c694d36a248 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=12
+revision=13
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 0e09fe8bcc96ba53c31e7d90a08427513a0283b6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6ad..92cd85b4076ab 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,13 +1,12 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"

From a1d32e4f659408bfaf7a2f3c3e1bcb7daf1eaf8a Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 08/12] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35def..f88e961939472 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From 41e2b2c7a2d013bc78f268890997c81f590729a1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 09/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae89186..f38c84efa1d21 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From b563f98878958f1a0c971e22b07742e6a6482313 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 10/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From e161e10243edadcd6ecaa9b02059358e73354e81 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 11/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From da2a6707794ac5f61f072f105c832cf39d70f0eb Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 12/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (14 preceding siblings ...)
  2023-08-07 15:56 ` [PR PATCH] [Updated] " motorto
@ 2023-08-09 14:04 ` motorto
  2023-08-20  2:52 ` XVilka
                   ` (16 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-09 14:04 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 673 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 18592 bytes --]

From 88007a30f36abfe1883b2032416c5b3b23797d0e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index ddb0e8ab87091..73cc88939d95b 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2132,7 +2132,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..e4c157effe2cd 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 33f5a1f521f379c95fc8b33fe11d620db61f65c4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.0.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  6 ++---
 2 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 73cc88939d95b..4b0d8a5fdf67f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4145,32 +4145,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45b..0d4cf4b1d96de 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
+version=0.6.0
 revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=6a924906efdf547ac50462767f5add53902436e7a4862d2c0e24ca91b7761508
 # requires some external files, not clear where they come from
 make_check=no
 

From 1523668c812de98b17ca62f83087e14d16f0794e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.0.

---
 srcpkgs/cutter/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..192df7be75ce3 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.0
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins
@@ -17,7 +17,7 @@ maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
 license="GPL-3.0-only"
 homepage="https://cutter.re"
 distfiles="https://github.com/rizinorg/cutter/releases/download/v${version}/Cutter-v${version}-src.tar.gz"
-checksum=883746c557f76ff336ce4efd42a81bc1052a5c06c3679aacae84d8bda3de1f58
+checksum=dd47e3680cdd5466495916db69fb40bb70fa04cdcb89d8a7de550c5bffccb79f
 
 cutter-devel_package() {
 	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"

From cc189988151e57f214a9dafad8509c5b3fd5f5d9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From 650df6bc77b9de05b2044fbb1d500c3a0f19e769 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389ec..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From ce08790bc0b4a9bfab5ca42b62138eebdcd08aac Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:59:25 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 2a79fb502f99e..f3c694d36a248 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=12
+revision=13
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From a9fae34735edac9e6057deea92c1a95403abe9f8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 13 ++++---------
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6ad..a303f7312e458 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,24 +1,19 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
-configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
+configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=FALSE" #https://github.com/BoomerangDecompiler/boomerang/issues/277
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/BoomerangDecompiler/boomerang"
 distfiles="https://github.com/BoomerangDecompiler/boomerang/archive/v${version}.tar.gz"
 checksum=1d2c9c2f5de1a3e1d5fe3879e82bca268d1c49e6ba3d0a7848695f18c594384d
-
-case "$XBPS_TARGET_MACHINE" in
-	ppc64*) ;;
-	ppc*) broken="BinaryFile.h:45:5: error: expected unqualified-id before numeric constant"
-esac
+make_check=no #https://github.com/BoomerangDecompiler/boomerang/issues/277
 
 pre_configure() {
 	# Fails to build w/ qt5-5.15.0 because of deprecated functions warnings

From 3f7552db10f85e552c1217650b249619d6d3d70d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:59 +0100
Subject: [PATCH 08/12] openocd: rebuild for capstone-5.0.

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 9309090c35def..f88e961939472 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=2
+revision=3
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.81

From 98327488de58989eed3ef4e572cc9310bd4d5edb Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 09/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae89186..f38c84efa1d21 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From f0379b6effdf7695abd689cb779001ada0b23bc9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 10/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From a60cf139555c5a0ceb0b77ce94b70519d59ec5a1 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 11/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From 68c61357ad8fd6ac5e8cac0d1496b3d9c448f0e6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 12/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (15 preceding siblings ...)
  2023-08-09 14:04 ` motorto
@ 2023-08-20  2:52 ` XVilka
  2023-08-20 22:14 ` [PR PATCH] [Updated] " motorto
                   ` (15 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: XVilka @ 2023-08-20  2:52 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 462 bytes --]

New comment by XVilka on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1685161332

Comment:
@motorto rizin bugfix release is out, fixing [CVE-2023-40022](https://github.com/rizinorg/rizin/security/advisories/GHSA-92h6-wwc2-53cq): https://github.com/rizinorg/rizin/releases/tag/v0.6.1

Corresponding Cutter release was also tagged with updated translations: https://github.com/rizinorg/cutter/releases/tag/v2.3.1

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (16 preceding siblings ...)
  2023-08-20  2:52 ` XVilka
@ 2023-08-20 22:14 ` motorto
  2023-08-20 22:17 ` motorto
                   ` (14 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-20 22:14 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 673 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 18591 bytes --]

From cc0963e943392c6ee83ac2590b92399ef9b32cd7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index eab94bb9b16d9..81b31de3d3062 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2131,7 +2131,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..e4c157effe2cd 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 1bf3b06c3ff0c4a622a63cb974eec0acfa79f17c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.1.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  6 ++---
 2 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 81b31de3d3062..64669a8ef2986 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4142,32 +4142,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45b..08698eab9605f 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
+version=0.6.1
 revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=760647caf8a78a638a0e040bf7b89c3ed064fabdfeac4fe44ff15d62baac6c91
 # requires some external files, not clear where they come from
 make_check=no
 

From 990825d9960a80778729f090793afc4cfc1bcb73 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.0.

---
 srcpkgs/cutter/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..4de3fc5e0ad6e 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.1
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins
@@ -17,7 +17,7 @@ maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
 license="GPL-3.0-only"
 homepage="https://cutter.re"
 distfiles="https://github.com/rizinorg/cutter/releases/download/v${version}/Cutter-v${version}-src.tar.gz"
-checksum=883746c557f76ff336ce4efd42a81bc1052a5c06c3679aacae84d8bda3de1f58
+checksum=6ded82c0709d8000f5df0e7e0f830042aab167e80a7116188634ec14182aee1a
 
 cutter-devel_package() {
 	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"

From 47f13c47cff2857b8c4d3124d74e26f05d86402f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From aae83ed3ce11af216a30ec94df36a5029fe7b7a3 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389ec..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From c066f1323a3cbd572603ff82ba4f40a5a5fe43f0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:59:25 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 2a79fb502f99e..f3c694d36a248 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=12
+revision=13
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From c019d7d6c39ad6b78b9609e54932902d7e3a4584 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 13 ++++---------
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6ad..a303f7312e458 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,24 +1,19 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
-configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
+configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=FALSE" #https://github.com/BoomerangDecompiler/boomerang/issues/277
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/BoomerangDecompiler/boomerang"
 distfiles="https://github.com/BoomerangDecompiler/boomerang/archive/v${version}.tar.gz"
 checksum=1d2c9c2f5de1a3e1d5fe3879e82bca268d1c49e6ba3d0a7848695f18c594384d
-
-case "$XBPS_TARGET_MACHINE" in
-	ppc64*) ;;
-	ppc*) broken="BinaryFile.h:45:5: error: expected unqualified-id before numeric constant"
-esac
+make_check=no #https://github.com/BoomerangDecompiler/boomerang/issues/277
 
 pre_configure() {
 	# Fails to build w/ qt5-5.15.0 because of deprecated functions warnings

From 4698304bc050f72b9e83451de4c41de52ab9fba4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 08/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae89186..f38c84efa1d21 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From f640d88acc8a9b76e704341169f609c2ef62a7b2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 09/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From 4ac5d52904dbc4dbb6fab874958649bedeb95614 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 10/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From 1a2dd5b06715d37d64299b2a9fd2d00fd84f3b1c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 11/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 14d6af96a78d2eb4451b92db219a77823ae052d0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Sun, 20 Aug 2023 23:14:30 +0100
Subject: [PATCH 12/12] openocd: rebuild por capstone-5.0

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 91f869ae6fb4f..da9d658b91d4a 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=3
+revision=4
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.82

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (17 preceding siblings ...)
  2023-08-20 22:14 ` [PR PATCH] [Updated] " motorto
@ 2023-08-20 22:17 ` motorto
  2023-08-22 10:50 ` [PR PATCH] [Updated] " motorto
                   ` (13 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-20 22:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 483 bytes --]

New comment by motorto on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1685410417

Comment:
> @motorto rizin bugfix release is out, fixing [CVE-2023-40022](https://github.com/rizinorg/rizin/security/advisories/GHSA-92h6-wwc2-53cq): https://github.com/rizinorg/rizin/releases/tag/v0.6.1
> 
> Corresponding Cutter release was also tagged with updated translations: https://github.com/rizinorg/cutter/releases/tag/v2.3.1

Thanks !!!

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (18 preceding siblings ...)
  2023-08-20 22:17 ` motorto
@ 2023-08-22 10:50 ` motorto
  2023-08-22 10:51 ` motorto
                   ` (12 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-22 10:50 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 673 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 18614 bytes --]

From cc0963e943392c6ee83ac2590b92399ef9b32cd7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index eab94bb9b16d9..81b31de3d3062 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2131,7 +2131,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..e4c157effe2cd 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=df24344407baa7415eeb006f742afc9b92cd33abf2c4c120a6e97cfb376882dc
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From 1bf3b06c3ff0c4a622a63cb974eec0acfa79f17c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.1.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  6 ++---
 2 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 81b31de3d3062..64669a8ef2986 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4142,32 +4142,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45b..08698eab9605f 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
+version=0.6.1
 revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=760647caf8a78a638a0e040bf7b89c3ed064fabdfeac4fe44ff15d62baac6c91
 # requires some external files, not clear where they come from
 make_check=no
 

From 990825d9960a80778729f090793afc4cfc1bcb73 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.0.

---
 srcpkgs/cutter/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..4de3fc5e0ad6e 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.1
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins
@@ -17,7 +17,7 @@ maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
 license="GPL-3.0-only"
 homepage="https://cutter.re"
 distfiles="https://github.com/rizinorg/cutter/releases/download/v${version}/Cutter-v${version}-src.tar.gz"
-checksum=883746c557f76ff336ce4efd42a81bc1052a5c06c3679aacae84d8bda3de1f58
+checksum=6ded82c0709d8000f5df0e7e0f830042aab167e80a7116188634ec14182aee1a
 
 cutter-devel_package() {
 	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"

From 47f13c47cff2857b8c4d3124d74e26f05d86402f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From 14dee39c7224baacd9c3662433e0278ea00e7d28 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389ec..a1cd699f3574b 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,18 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
+checkdepends="cmake"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From f2fbcaf0a0a7c446430f8e7d7d031a5676e9a3b6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:59:25 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 2a79fb502f99e..f3c694d36a248 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=12
+revision=13
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 27fc6e8fb4d5bf778e758ca9b619e3daf87db740 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 13 ++++---------
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6ad..a303f7312e458 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,24 +1,19 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
-configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
+configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=FALSE" #https://github.com/BoomerangDecompiler/boomerang/issues/277
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/BoomerangDecompiler/boomerang"
 distfiles="https://github.com/BoomerangDecompiler/boomerang/archive/v${version}.tar.gz"
 checksum=1d2c9c2f5de1a3e1d5fe3879e82bca268d1c49e6ba3d0a7848695f18c594384d
-
-case "$XBPS_TARGET_MACHINE" in
-	ppc64*) ;;
-	ppc*) broken="BinaryFile.h:45:5: error: expected unqualified-id before numeric constant"
-esac
+make_check=no #https://github.com/BoomerangDecompiler/boomerang/issues/277
 
 pre_configure() {
 	# Fails to build w/ qt5-5.15.0 because of deprecated functions warnings

From 877769a3332f393fb33f0538f70a4ea978369ae3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 08/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae89186..f38c84efa1d21 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From f383a1575331f0e7a45274c224e4bc178c4955e6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 09/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From e1a1b5e893bc2bf17e5d9a54268545561681bcb3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 10/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From 81b7a6ce4e098ec7e5518498ac2a581e4bdfb2fa Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 11/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 2a0896ecdb8cfc3b5ee289cb9281d9f5e7ee2ba4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Sun, 20 Aug 2023 23:14:30 +0100
Subject: [PATCH 12/12] openocd: rebuild por capstone-5.0

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 91f869ae6fb4f..da9d658b91d4a 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=3
+revision=4
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.82

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (19 preceding siblings ...)
  2023-08-22 10:50 ` [PR PATCH] [Updated] " motorto
@ 2023-08-22 10:51 ` motorto
  2023-08-22 16:18 ` classabbyamp
                   ` (11 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-22 10:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 252 bytes --]

New comment by motorto on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1687956546

Comment:
@classabbyamp: added `checkdepends=cmake` on the `imhex` template. It couldn't find the `ctest` without it ...

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (20 preceding siblings ...)
  2023-08-22 10:51 ` motorto
@ 2023-08-22 16:18 ` classabbyamp
  2023-08-23  1:04 ` sgn
                   ` (10 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: classabbyamp @ 2023-08-22 16:18 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 193 bytes --]

New comment by classabbyamp on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1688523048

Comment:
hm that should probably be reported in #45679 

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (21 preceding siblings ...)
  2023-08-22 16:18 ` classabbyamp
@ 2023-08-23  1:04 ` sgn
  2023-08-23  2:41 ` XVilka
                   ` (9 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: sgn @ 2023-08-23  1:04 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 187 bytes --]

New comment by sgn on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1689113895

Comment:
@motorto  Did you rebase on latest void-packages?

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (22 preceding siblings ...)
  2023-08-23  1:04 ` sgn
@ 2023-08-23  2:41 ` XVilka
  2023-08-23 14:05 ` motorto
                   ` (8 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: XVilka @ 2023-08-23  2:41 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 303 bytes --]

New comment by XVilka on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1689175485

Comment:
By the way, there is a bugfix release for capstone, you might want to try switching to it directly: https://github.com/capstone-engine/capstone/releases/tag/5.0.1

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (23 preceding siblings ...)
  2023-08-23  2:41 ` XVilka
@ 2023-08-23 14:05 ` motorto
  2023-08-23 14:05 ` motorto
                   ` (7 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-23 14:05 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 345 bytes --]

New comment by motorto on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1690028665

Comment:
> @motorto Did you rebase on latest void-packages?

Not the latest/latest I would say last week. But will rebase now, make a rebuild and push. Asking because of the cmake build style changes, correct ?

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (24 preceding siblings ...)
  2023-08-23 14:05 ` motorto
@ 2023-08-23 14:05 ` motorto
  2023-08-23 15:17 ` sgn
                   ` (6 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-23 14:05 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 336 bytes --]

New comment by motorto on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1690029263

Comment:
> By the way, there is a bugfix release for capstone, you might want to try switching to it directly: https://github.com/capstone-engine/capstone/releases/tag/5.0.1

Thanks, for the heads up! 

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (25 preceding siblings ...)
  2023-08-23 14:05 ` motorto
@ 2023-08-23 15:17 ` sgn
  2023-08-23 18:02 ` [PR PATCH] [Updated] " motorto
                   ` (5 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: sgn @ 2023-08-23 15:17 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 404 bytes --]

New comment by sgn on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1690154153

Comment:
> > @motorto Did you rebase on latest void-packages?
> 
> Not the latest/latest I would say last week. But will rebase now, make a rebuild and push. Asking because of the cmake build style changes, correct ?

Yes, the check run normally on top of current master.

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (26 preceding siblings ...)
  2023-08-23 15:17 ` sgn
@ 2023-08-23 18:02 ` motorto
  2023-08-23 18:03 ` motorto
                   ` (4 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-23 18:02 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 673 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-glibc

- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 18597 bytes --]

From 69a56c116b39bf9d56af2120e768ee23ae414796 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.1.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index f1ca9ce4870d1..ce3c5bc728295 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2131,7 +2131,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0.1_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..47bdda8f3669f 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0.1
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=2b9c66915923fdc42e0e32e2a9d7d83d3534a45bb235e163a70047951890c01a
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From e56b4307515a168df0546b8b45da230fb3c602d2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.1.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  6 ++---
 2 files changed, 29 insertions(+), 29 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index ce3c5bc728295..abf946c571ab7 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4142,32 +4142,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 8fe7acb2ff45b..08698eab9605f 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
+version=0.6.1
 revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=760647caf8a78a638a0e040bf7b89c3ed064fabdfeac4fe44ff15d62baac6c91
 # requires some external files, not clear where they come from
 make_check=no
 

From f0b249489eab75c39555938c7a0f07913f49683f Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.0.

---
 srcpkgs/cutter/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..4de3fc5e0ad6e 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.1
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins
@@ -17,7 +17,7 @@ maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
 license="GPL-3.0-only"
 homepage="https://cutter.re"
 distfiles="https://github.com/rizinorg/cutter/releases/download/v${version}/Cutter-v${version}-src.tar.gz"
-checksum=883746c557f76ff336ce4efd42a81bc1052a5c06c3679aacae84d8bda3de1f58
+checksum=6ded82c0709d8000f5df0e7e0f830042aab167e80a7116188634ec14182aee1a
 
 cutter-devel_package() {
 	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"

From cd956d9c4401060c39666a7f2dad01e0e5901c01 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From f78bafd5f761f028d159d7c27b3ccc792c4af3eb Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 3f7f4750389ec..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=1
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From 97f7a39294769f887fc67bfe3ddb1f75d8a3d3c0 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 31 Jul 2023 10:59:25 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index 2a79fb502f99e..f3c694d36a248 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=12
+revision=13
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 7306b74ffc150a3bd0535fb258d8a86206750ca2 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:06:58 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 13 ++++---------
 1 file changed, 4 insertions(+), 9 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4c64c6ba3d6ad..a303f7312e458 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,24 +1,19 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
-configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
+configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=FALSE" #https://github.com/BoomerangDecompiler/boomerang/issues/277
 make_check_target="check"
-hostmakedepends="flex qt5-devel"
+hostmakedepends="flex python3 qt5-devel"
 makedepends="qt5-devel capstone-devel"
-checkdepends="python3"
 short_desc="General, open source machine code decompiler"
 maintainer="Piraty <mail@piraty.dev>"
 license="BSD-3-Clause"
 homepage="https://github.com/BoomerangDecompiler/boomerang"
 distfiles="https://github.com/BoomerangDecompiler/boomerang/archive/v${version}.tar.gz"
 checksum=1d2c9c2f5de1a3e1d5fe3879e82bca268d1c49e6ba3d0a7848695f18c594384d
-
-case "$XBPS_TARGET_MACHINE" in
-	ppc64*) ;;
-	ppc*) broken="BinaryFile.h:45:5: error: expected unqualified-id before numeric constant"
-esac
+make_check=no #https://github.com/BoomerangDecompiler/boomerang/issues/277
 
 pre_configure() {
 	# Fails to build w/ qt5-5.15.0 because of deprecated functions warnings

From d61b105d266d8708bd8eaaff3d994c673cbff127 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:00 +0100
Subject: [PATCH 08/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index 7ccf26ae89186..f38c84efa1d21 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.7.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From 8fbebd975e5bb4eeadfc10d8ebb8c949b20c1a61 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 09/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From 9fa9589d7c717db947f2404e77bb33d8534b9ab8 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 10/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From da82f66134ae6d0f9882e7f1a21cd0fe7a81cc32 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 11/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 8631475843bf49f9f495aa88541567bf76f1a62e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Sun, 20 Aug 2023 23:14:30 +0100
Subject: [PATCH 12/12] openocd: rebuild por capstone-5.0

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 91f869ae6fb4f..da9d658b91d4a 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=3
+revision=4
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.82

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (27 preceding siblings ...)
  2023-08-23 18:02 ` [PR PATCH] [Updated] " motorto
@ 2023-08-23 18:03 ` motorto
  2023-09-14  9:51 ` XVilka
                   ` (3 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-08-23 18:03 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 284 bytes --]

New comment by motorto on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1690403265

Comment:
> Yes, the check run normally on top of current master.

Yes, can confirm that, removed the `checkdepends=` line. Thanks for the attention. 

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (28 preceding siblings ...)
  2023-08-23 18:03 ` motorto
@ 2023-09-14  9:51 ` XVilka
  2023-09-15 18:10 ` [PR PATCH] [Updated] " motorto
                   ` (2 subsequent siblings)
  32 siblings, 0 replies; 34+ messages in thread
From: XVilka @ 2023-09-14  9:51 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 355 bytes --]

New comment by XVilka on void-packages repository

https://github.com/void-linux/void-packages/pull/44967#issuecomment-1719135198

Comment:
Meanwhile we updated Cutter and Rizin with new bugfix releases, you could pick them in the same PR:
- https://github.com/rizinorg/rizin/releases/tag/v0.6.2
- https://github.com/rizinorg/cutter/releases/tag/v2.3.2

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (29 preceding siblings ...)
  2023-09-14  9:51 ` XVilka
@ 2023-09-15 18:10 ` motorto
  2023-09-15 19:54 ` motorto
  2023-09-15 22:00 ` [PR PATCH] [Merged]: " classabbyamp
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-09-15 18:10 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 707 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-{glibc,musl}
  - aarch64-musl: cross


- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 17673 bytes --]

From a03fd6253ea8874c57747591b10aed8d302fa76c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.1.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 9a57cda25562b..c3cfbf5ac1c4f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2099,7 +2099,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0.1_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..47bdda8f3669f 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0.1
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=2b9c66915923fdc42e0e32e2a9d7d83d3534a45bb235e163a70047951890c01a
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From eb494da71b79eaa80863d4cd4e22dea20ebd8ce3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.2.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  8 +++----
 2 files changed, 30 insertions(+), 30 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index c3cfbf5ac1c4f..ba5c117df3e5f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4096,32 +4096,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 4888fc014d3b4..16c7230d04d57 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
-revision=2
+version=0.6.2
+revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=e29a00a3e22004bdd10146d286b1cce0e06196d41aae4729aafc9d78321ff86b
 # requires some external files, not clear where they come from
 make_check=no
 

From 297f281806db93679a76a6b274a3aa3a85310067 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.2.

---
 srcpkgs/cutter/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..762e1a4eb32d4 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.2
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins
@@ -17,7 +17,7 @@ maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
 license="GPL-3.0-only"
 homepage="https://cutter.re"
 distfiles="https://github.com/rizinorg/cutter/releases/download/v${version}/Cutter-v${version}-src.tar.gz"
-checksum=883746c557f76ff336ce4efd42a81bc1052a5c06c3679aacae84d8bda3de1f58
+checksum=6c63652f6d959a44ce282f4abf7b86dfb86e60c9b0cf00dbd75278ab8cc64d5d
 
 cutter-devel_package() {
 	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"

From e86e3b7431c9c7cb258933027dd2364c6909aa69 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From 3e0b087085a4a785863aa5440e3f570a67bfca55 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 8f6d18d9ea179..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=4
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From 8959121eae2153dda5d15c50b4576a0b58bdaa54 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Fri, 15 Sep 2023 17:17:49 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index f3c694d36a248..71632e102b923 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=13
+revision=14
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 7d5d46b65142c9c6331b485f2ace572e769df689 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Fri, 15 Sep 2023 17:18:22 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4abda158a0635..eb28a07724196 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,7 +1,7 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
 configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
 make_check_target="check"

From 464a67507fc7c631995c12741b7acc87f143c86b Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Fri, 15 Sep 2023 17:18:52 +0100
Subject: [PATCH 08/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index cc16a637c3104..a950fbdf4e708 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.8.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From 06242aef6f15eb97a1030585cc8d78effef436b9 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 09/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From b70789cdbb657feca6772a4376dfa4c752f93685 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 10/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From 5c7980405c8c2b9fd203214281dc4bd6e0bc5b4d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 11/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 858e03b249d9be52df8298896cab66eb23ed9a84 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Sun, 20 Aug 2023 23:14:30 +0100
Subject: [PATCH 12/12] openocd: rebuild por capstone-5.0

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 91f869ae6fb4f..da9d658b91d4a 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=3
+revision=4
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.82

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Updated] Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (30 preceding siblings ...)
  2023-09-15 18:10 ` [PR PATCH] [Updated] " motorto
@ 2023-09-15 19:54 ` motorto
  2023-09-15 22:00 ` [PR PATCH] [Merged]: " classabbyamp
  32 siblings, 0 replies; 34+ messages in thread
From: motorto @ 2023-09-15 19:54 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 707 bytes --]

There is an updated pull request by motorto against master on the void-packages repository

https://github.com/motorto/void-packages capstone-5.0
https://github.com/void-linux/void-packages/pull/44967

Capstone 5.0
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-{glibc,musl}
  - aarch64-musl: cross


- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277

A patch file from https://github.com/void-linux/void-packages/pull/44967.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-capstone-5.0-44967.patch --]
[-- Type: text/x-diff, Size: 18407 bytes --]

From a03fd6253ea8874c57747591b10aed8d302fa76c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:15:54 +0100
Subject: [PATCH 01/12] capstone: update to 5.0.1.

---
 common/shlibs             |  2 +-
 srcpkgs/capstone/template | 11 ++++++-----
 2 files changed, 7 insertions(+), 6 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index 9a57cda25562b..c3cfbf5ac1c4f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -2099,7 +2099,7 @@ libopenjpeg.so.5 libopenjpeg-1.5.2_1
 liboping.so.0 liboping-1.8.0_1
 libloudmouth-1.so.0 loudmouth-1.5.3_12
 libtorrent-rasterbar.so.10 libtorrent-rasterbar-1.2.18_1
-libcapstone.so.4 capstone-4.0_1
+libcapstone.so.5 capstone-5.0.1_1
 libhavege.so.2 libhaveged-1.9.11_1
 libnih.so.1 libnih-1.0.3_1
 libnih-dbus.so.1 libnih-1.0.3_1
diff --git a/srcpkgs/capstone/template b/srcpkgs/capstone/template
index 99c20894520b7..47bdda8f3669f 100644
--- a/srcpkgs/capstone/template
+++ b/srcpkgs/capstone/template
@@ -1,16 +1,17 @@
 # Template file for 'capstone'
 pkgname=capstone
-version=4.0.2
-revision=5
+version=5.0.1
+revision=1
 build_style=gnu-makefile
 make_use_env=yes
 hostmakedepends="python3-setuptools"
 short_desc="Lightweight multi-platform, multi-architecture disassembly framework"
-maintainer="Orphaned <orphan@voidlinux.org>"
+maintainer="André Cerqueira <acerqueira021@gmail.com>"
 license="BSD-2-Clause"
 homepage="https://www.capstone-engine.org/"
-distfiles="https://github.com/aquynh/${pkgname}/archive/${version}.tar.gz"
-checksum=7c81d798022f81e7507f1a60d6817f63aa76e489aa4e7055255f21a22f5e526a
+changelog="https://raw.githubusercontent.com/capstone-engine/capstone/next/ChangeLog"
+distfiles="https://github.com/aquynh/capstone/archive/${version}.tar.gz"
+checksum=2b9c66915923fdc42e0e32e2a9d7d83d3534a45bb235e163a70047951890c01a
 
 post_install() {
 	make -C bindings/python PREFIX=/usr DESTDIR=${DESTDIR} install3

From eb494da71b79eaa80863d4cd4e22dea20ebd8ce3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:03:17 +0100
Subject: [PATCH 02/12] rizin: update to 0.6.2.

---
 common/shlibs          | 52 +++++++++++++++++++++---------------------
 srcpkgs/rizin/template |  8 +++----
 2 files changed, 30 insertions(+), 30 deletions(-)

diff --git a/common/shlibs b/common/shlibs
index c3cfbf5ac1c4f..ba5c117df3e5f 100644
--- a/common/shlibs
+++ b/common/shlibs
@@ -4096,32 +4096,32 @@ libreadosm.so.1 readosm-1.1.0a_1
 libSvtAv1Enc.so.1 libsvt-av1-1.3.0_1
 libSvtAv1Dec.so.0 libsvt-av1-0.9.0_1
 libyascreen.so.0 yascreen-1.96_1
-librz_analysis.so.0.5 rizin-0.5.1_1
-librz_asm.so.0.5 rizin-0.5.1_1
-librz_bin.so.0.5 rizin-0.5.1_1
-librz_bp.so.0.5 rizin-0.5.1_1
-librz_config.so.0.5 rizin-0.5.1_1
-librz_cons.so.0.5 rizin-0.5.1_1
-librz_core.so.0.5 rizin-0.5.1_1
-librz_crypto.so.0.5 rizin-0.5.1_1
-librz_debug.so.0.5 rizin-0.5.1_1
-librz_demangler.so.0.5 rizin-0.5.1_1
-librz_diff.so.0.5 rizin-0.5.1_1
-librz_egg.so.0.5 rizin-0.5.1_1
-librz_flag.so.0.5 rizin-0.5.1_1
-librz_hash.so.0.5 rizin-0.5.1_1
-librz_io.so.0.5 rizin-0.5.1_1
-librz_lang.so.0.5 rizin-0.5.1_1
-librz_magic.so.0.5 rizin-0.5.1_1
-librz_main.so.0.5 rizin-0.5.1_1
-librz_parse.so.0.5 rizin-0.5.1_1
-librz_reg.so.0.5 rizin-0.5.1_1
-librz_search.so.0.5 rizin-0.5.1_1
-librz_sign.so.0.5 rizin-0.5.1_1
-librz_socket.so.0.5 rizin-0.5.1_1
-librz_syscall.so.0.5 rizin-0.5.1_1
-librz_type.so.0.5 rizin-0.5.1_1
-librz_util.so.0.5 rizin-0.5.1_1
+librz_analysis.so.0.6 rizin-0.6.0_1
+librz_asm.so.0.6 rizin-0.6.0_1
+librz_bin.so.0.6 rizin-0.6.0_1
+librz_bp.so.0.6 rizin-0.6.0_1
+librz_config.so.0.6 rizin-0.6.0_1
+librz_cons.so.0.6 rizin-0.6.0_1
+librz_core.so.0.6 rizin-0.6.0_1
+librz_crypto.so.0.6 rizin-0.6.0_1
+librz_debug.so.0.6 rizin-0.6.0_1
+librz_demangler.so.0.6 rizin-0.6.0_1
+librz_diff.so.0.6 rizin-0.6.0_1
+librz_egg.so.0.6 rizin-0.6.0_1
+librz_flag.so.0.6 rizin-0.6.0_1
+librz_hash.so.0.6 rizin-0.6.0_1
+librz_io.so.0.6 rizin-0.6.0_1
+librz_lang.so.0.6 rizin-0.6.0_1
+librz_magic.so.0.6 rizin-0.6.0_1
+librz_main.so.0.6 rizin-0.6.0_1
+librz_parse.so.0.6 rizin-0.6.0_1
+librz_reg.so.0.6 rizin-0.6.0_1
+librz_search.so.0.6 rizin-0.6.0_1
+librz_sign.so.0.6 rizin-0.6.0_1
+librz_socket.so.0.6 rizin-0.6.0_1
+librz_syscall.so.0.6 rizin-0.6.0_1
+librz_type.so.0.6 rizin-0.6.0_1
+librz_util.so.0.6 rizin-0.6.0_1
 libaravis-0.8.so.0 libaravis-0.8.21_1
 libLimeSuite.so.22.09-1 LimeSuite-22.09.0_1
 libnvme.so.1 libnvme-1.0_1
diff --git a/srcpkgs/rizin/template b/srcpkgs/rizin/template
index 4888fc014d3b4..16c7230d04d57 100644
--- a/srcpkgs/rizin/template
+++ b/srcpkgs/rizin/template
@@ -1,9 +1,9 @@
 # Template file for 'rizin'
 pkgname=rizin
-version=0.5.2
-revision=2
+version=0.6.2
+revision=1
 build_style=meson
-configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v4
+configure_args="-D use_sys_capstone=enabled -D use_capstone_version=v5
  -D use_sys_magic=enabled -D use_sys_libzip=enabled -D use_sys_zlib=enabled
  -D use_sys_lz4=enabled -D use_sys_xxhash=enabled -D use_sys_openssl=enabled
  -D use_sys_tree_sitter=enabled -D use_sys_lzma=enabled -D use_sys_libmspack=enabled
@@ -17,7 +17,7 @@ license="LGPL-3.0-only"
 homepage="https://rizin.re"
 changelog="https://github.com/rizinorg/rizin/releases"
 distfiles="https://github.com/rizinorg/rizin/releases/download/v${version}/rizin-src-v${version}.tar.xz"
-checksum=71ab80fc3c8ac9c80a10000d838128af28a05d31a0ee183900c2c5c6e350eca3
+checksum=e29a00a3e22004bdd10146d286b1cce0e06196d41aae4729aafc9d78321ff86b
 # requires some external files, not clear where they come from
 make_check=no
 

From 297f281806db93679a76a6b274a3aa3a85310067 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:05:24 +0100
Subject: [PATCH 03/12] cutter: update to 2.3.2.

---
 srcpkgs/cutter/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/cutter/template b/srcpkgs/cutter/template
index c79e28b9d689a..762e1a4eb32d4 100644
--- a/srcpkgs/cutter/template
+++ b/srcpkgs/cutter/template
@@ -1,6 +1,6 @@
 # Template file for 'cutter'
 pkgname=cutter
-version=2.2.1
+version=2.3.2
 revision=1
 build_style=cmake
 configure_args="-DCUTTER_EXTRA_PLUGIN_DIRS=/usr/lib/rizin/cutter/plugins
@@ -17,7 +17,7 @@ maintainer="Urs Schulz <voidpkgs@ursschulz.de>"
 license="GPL-3.0-only"
 homepage="https://cutter.re"
 distfiles="https://github.com/rizinorg/cutter/releases/download/v${version}/Cutter-v${version}-src.tar.gz"
-checksum=883746c557f76ff336ce4efd42a81bc1052a5c06c3679aacae84d8bda3de1f58
+checksum=6c63652f6d959a44ce282f4abf7b86dfb86e60c9b0cf00dbd75278ab8cc64d5d
 
 cutter-devel_package() {
 	depends="${makedepends} ${sourcepkg}>=${version}_${revision}"

From e86e3b7431c9c7cb258933027dd2364c6909aa69 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:17:17 +0100
Subject: [PATCH 04/12] rz-ghidra: update to 0.6.0.

---
 srcpkgs/rz-ghidra/template | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/srcpkgs/rz-ghidra/template b/srcpkgs/rz-ghidra/template
index d0db71bbd5a1e..d285d12120f90 100644
--- a/srcpkgs/rz-ghidra/template
+++ b/srcpkgs/rz-ghidra/template
@@ -1,6 +1,6 @@
 # Template file for 'rz-ghidra'
 pkgname=rz-ghidra
-version=0.5.0
+version=0.6.0
 revision=1
 build_style=cmake
 build_helper=qemu
@@ -13,4 +13,4 @@ maintainer="classabbyamp <void@placeviolette.net>"
 license="LGPL-3.0-or-later"
 homepage="https://github.com/rizinorg/rz-ghidra"
 distfiles="https://github.com/rizinorg/rz-ghidra/releases/download/v${version}/rz-ghidra-src-v${version}.tar.gz"
-checksum=cb3da4b7d21324062ab94eff9e892dbb69de2be1133275c7ae9aff37b91404c7
+checksum=574eb52dda80c8ef1e24c166cfdc8a462ef01da7930556604d65d86c2a8051e4

From 3e0b087085a4a785863aa5440e3f570a67bfca55 Mon Sep 17 00:00:00 2001
From: classabbyamp <void@placeviolette.net>
Date: Tue, 11 Jul 2023 20:19:36 -0400
Subject: [PATCH 05/12] imhex: use system capstone.

---
 srcpkgs/imhex/template | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/srcpkgs/imhex/template b/srcpkgs/imhex/template
index 8f6d18d9ea179..94a058c2b1639 100644
--- a/srcpkgs/imhex/template
+++ b/srcpkgs/imhex/template
@@ -1,18 +1,17 @@
 # Template file for 'imhex'
 pkgname=imhex
 version=1.30.1
-revision=4
+revision=2
 build_wrksrc="ImHex"
 build_style=cmake
 build_helper=qemu
-# XXX: when capstone v5 is out, -DUSE_SYSTEM_CAPSTONE=ON
 configure_args="-DIMHEX_OFFLINE_BUILD=ON -DIMHEX_STRIP_RELEASE=OFF
- -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON
+ -DUSE_SYSTEM_CURL=ON -DUSE_SYSTEM_FMT=ON -DUSE_SYSTEM_LLVM=ON -DUSE_SYSTEM_CAPSTONE=ON
  -DUSE_SYSTEM_YARA=ON -DUSE_SYSTEM_NLOHMANN_JSON=ON -DIMHEX_DISABLE_UPDATE_CHECK=ON"
 hostmakedepends="pkg-config clang-tools-extra"
 makedepends="libcurl-devel fmt-devel llvm jansson-devel yara-devel json-c++
  freetype-devel glfw-devel gtk+3-devel python3-devel file-devel mbedtls-devel
- clang-tools-extra"
+ clang-tools-extra capstone-devel"
 short_desc="Hex editor for reverse engineers and programmers"
 maintainer="classabbyamp <void@placeviolette.net>"
 license="GPL-2.0-or-later"

From 8959121eae2153dda5d15c50b4576a0b58bdaa54 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Fri, 15 Sep 2023 17:17:49 +0100
Subject: [PATCH 06/12] bloaty: rebuild for capstone-5.0.

---
 srcpkgs/bloaty/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/bloaty/template b/srcpkgs/bloaty/template
index f3c694d36a248..71632e102b923 100644
--- a/srcpkgs/bloaty/template
+++ b/srcpkgs/bloaty/template
@@ -1,7 +1,7 @@
 # Template file for 'bloaty'
 pkgname=bloaty
 version=1.1
-revision=13
+revision=14
 build_style=cmake
 hostmakedepends="pkg-config protobuf"
 makedepends="capstone-devel protobuf-devel re2-devel zlib-devel"

From 43306f069a53c6bf6317113a68651df94a9d60ec Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Fri, 15 Sep 2023 17:18:22 +0100
Subject: [PATCH 07/12] boomerang: rebuild for capstone-5.0.

---
 srcpkgs/boomerang/template | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

diff --git a/srcpkgs/boomerang/template b/srcpkgs/boomerang/template
index 4abda158a0635..51b32aa97519c 100644
--- a/srcpkgs/boomerang/template
+++ b/srcpkgs/boomerang/template
@@ -1,9 +1,9 @@
 # Template file for 'boomerang'
 pkgname=boomerang
 version=0.5.2
-revision=1
+revision=2
 build_style=cmake
-configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=TRUE"
+configure_args="-DBOOMERANG_BUILD_REGRESSION_TESTS=FALSE"
 make_check_target="check"
 hostmakedepends="flex qt5-devel python3"
 makedepends="qt5-devel capstone-devel"
@@ -13,11 +13,7 @@ license="BSD-3-Clause"
 homepage="https://github.com/BoomerangDecompiler/boomerang"
 distfiles="https://github.com/BoomerangDecompiler/boomerang/archive/v${version}.tar.gz"
 checksum=1d2c9c2f5de1a3e1d5fe3879e82bca268d1c49e6ba3d0a7848695f18c594384d
-
-case "$XBPS_TARGET_MACHINE" in
-	ppc64*) ;;
-	ppc*) broken="BinaryFile.h:45:5: error: expected unqualified-id before numeric constant"
-esac
+make_check=no #https://github.com/BoomerangDecompiler/boomerang/issues/277
 
 pre_configure() {
 	# Fails to build w/ qt5-5.15.0 because of deprecated functions warnings

From a25698d402ccce40cbba3da082de44b3252edba6 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Fri, 15 Sep 2023 17:18:52 +0100
Subject: [PATCH 08/12] radare2: rebuild for capstone-5.0.

---
 srcpkgs/radare2/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/radare2/template b/srcpkgs/radare2/template
index cc16a637c3104..a950fbdf4e708 100644
--- a/srcpkgs/radare2/template
+++ b/srcpkgs/radare2/template
@@ -1,7 +1,7 @@
 # Template file for 'radare2'
 pkgname=radare2
 version=5.8.8
-revision=1
+revision=2
 build_style=meson
 configure_args="-Denable_tests=false -Duse_sys_capstone=true
  -Duse_sys_magic=true -Duse_sys_xxhash=true

From fc22948f88123b80ac64a71bfcfbebdd7e646752 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 16:07:01 +0100
Subject: [PATCH 09/12] uftrace: rebuild for capstone-5.0.

---
 srcpkgs/uftrace/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/uftrace/template b/srcpkgs/uftrace/template
index 8f703e0a812f6..3e7690e4ea901 100644
--- a/srcpkgs/uftrace/template
+++ b/srcpkgs/uftrace/template
@@ -1,7 +1,7 @@
 # Template file for 'uftrace'
 pkgname=uftrace
 version=0.14
-revision=1
+revision=2
 archs="x86_64* i686* aarch64* arm*"
 build_style=configure
 configure_args="--prefix=/usr --libdir=/usr/lib${XBPS_TARGET_WORDSIZE}"

From 77df9098d4566b96a55e88ccacb75afed73ae256 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 10 Jul 2023 18:09:08 +0100
Subject: [PATCH 10/12] qemu: rebuild for capstone-5.0

---
 srcpkgs/qemu/patches/tricore_feature.patch | 60 ++++++++++++++++++++++
 srcpkgs/qemu/template                      |  7 +--
 2 files changed, 62 insertions(+), 5 deletions(-)
 create mode 100644 srcpkgs/qemu/patches/tricore_feature.patch

diff --git a/srcpkgs/qemu/patches/tricore_feature.patch b/srcpkgs/qemu/patches/tricore_feature.patch
new file mode 100644
index 0000000000000..f7f621f81170b
--- /dev/null
+++ b/srcpkgs/qemu/patches/tricore_feature.patch
@@ -0,0 +1,60 @@
+capstone 5 declares this struct, so we need a different name
+--
+diff --git a/target/tricore/cpu.c b/target/tricore/cpu.c
+index d0a9272..6297af9 100644
+--- a/target/tricore/cpu.c
++++ b/target/tricore/cpu.c
+@@ -103,14 +103,14 @@ static void tricore_cpu_realizefn(DeviceState *dev, Error **errp)
+     }
+ 
+     /* Some features automatically imply others */
+-    if (tricore_feature(env, TRICORE_FEATURE_161)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_161)) {
+         set_feature(env, TRICORE_FEATURE_16);
+     }
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_16)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_16)) {
+         set_feature(env, TRICORE_FEATURE_131);
+     }
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         set_feature(env, TRICORE_FEATURE_13);
+     }
+     cpu_reset(cs);
+diff --git a/target/tricore/cpu.h b/target/tricore/cpu.h
+index 47d0ffb..6fd447c 100644
+--- a/target/tricore/cpu.h
++++ b/target/tricore/cpu.h
+@@ -258,7 +258,7 @@ enum tricore_features {
+     TRICORE_FEATURE_161,
+ };
+ 
+-static inline int tricore_feature(CPUTriCoreState *env, int feature)
++static inline int tricore_feature_x(CPUTriCoreState *env, int feature)
+ {
+     return (env->features & (1ULL << feature)) != 0;
+ }
+diff --git a/target/tricore/op_helper.c b/target/tricore/op_helper.c
+index 532ae6b..6a71b5b 100644
+--- a/target/tricore/op_helper.c
++++ b/target/tricore/op_helper.c
+@@ -2528,7 +2528,7 @@ void helper_ret(CPUTriCoreState *env)
+     /* PCXI = new_PCXI; */
+     env->PCXI = new_PCXI;
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_13)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_13)) {
+         /* PSW = new_PSW */
+         psw_write(env, new_PSW);
+     } else {
+@@ -2639,7 +2639,7 @@ void helper_rfm(CPUTriCoreState *env)
+     env->gpr_a[10] = cpu_ldl_data(env, env->DCX+8);
+     env->gpr_a[11] = cpu_ldl_data(env, env->DCX+12);
+ 
+-    if (tricore_feature(env, TRICORE_FEATURE_131)) {
++    if (tricore_feature_x(env, TRICORE_FEATURE_131)) {
+         env->DBGTCR = 0;
+     }
+ }
+
diff --git a/srcpkgs/qemu/template b/srcpkgs/qemu/template
index 48ab199e5686b..9793e2f6101a7 100644
--- a/srcpkgs/qemu/template
+++ b/srcpkgs/qemu/template
@@ -2,7 +2,7 @@
 # This package should be updated together with qemu-user-static
 pkgname=qemu
 version=7.1.0
-revision=2
+revision=3
 build_style=configure
 configure_args="--prefix=/usr --sysconfdir=/etc --libexecdir=/usr/libexec --localstatedir=/var
  --disable-glusterfs --disable-xen --enable-docs --enable-kvm --enable-libusb --enable-pie
@@ -33,6 +33,7 @@ ignore_elf_dirs="/usr/share/qemu"
 nostrip_files="hppa-firmware.img openbios-ppc openbios-sparc32 openbios-sparc64
  palcode-clipper s390-ccw.img s390-netboot.img u-boot.e500 opensbi-riscv32-generic-fw_dynamic.elf
  opensbi-riscv64-generic-fw_dynamic.elf"
+make_check=no # capstone5.0: fails 90/95 qemu:unit / test-vmstate (when updating the qemu package this should go away)
 
 build_options="gtk3 opengl sdl2 spice virgl smartcard numa iscsi jack pulseaudio"
 build_options_default="opengl gtk3 virgl sdl2 numa iscsi jack pulseaudio"
@@ -57,10 +58,6 @@ else
 	build_options_default+=" smartcard"
 fi
 
-if [ "$XBPS_CHECK_PKGS" != full ]; then
-	make_check_target=check-unit
-fi
-
 post_extract() {
 	if [ "$XBPS_TARGET_LIBC" = "musl" ]; then
 		grep -rl 'Input/output error' tests/qemu-iotests |

From c2097f1f615e7b0e3b45bfa341e9b37cd4acf181 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Mon, 7 Aug 2023 14:01:32 +0100
Subject: [PATCH 11/12] edb-debugger: rebuild for capstone-5.0.

---
 srcpkgs/edb-debugger/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/edb-debugger/template b/srcpkgs/edb-debugger/template
index e3fa3a69574bf..f78ab91dc0a52 100644
--- a/srcpkgs/edb-debugger/template
+++ b/srcpkgs/edb-debugger/template
@@ -1,7 +1,7 @@
 # Template file for 'edb-debugger'
 pkgname=edb-debugger
 version=1.4.0
-revision=1
+revision=2
 archs="x86_64* i686*"
 build_style=cmake
 hostmakedepends='pkg-config'

From 4953baba16f377a8156dd6b271b21969a28b9da7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Andr=C3=A9=20Cerqueira?= <acerqueira021@gmail.com>
Date: Sun, 20 Aug 2023 23:14:30 +0100
Subject: [PATCH 12/12] openocd: rebuild por capstone-5.0

---
 srcpkgs/openocd/template | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/srcpkgs/openocd/template b/srcpkgs/openocd/template
index 91f869ae6fb4f..da9d658b91d4a 100644
--- a/srcpkgs/openocd/template
+++ b/srcpkgs/openocd/template
@@ -1,7 +1,7 @@
 # Template file for 'openocd'
 pkgname=openocd
 version=0.11.0+1
-revision=3
+revision=4
 # update to a commit that has a compatible jimtcl version
 _commit=830d70bfc66ada2a68c73283b9e4fa4770d408ee
 _jimtcl_version=0.82

^ permalink raw reply	[flat|nested] 34+ messages in thread

* Re: [PR PATCH] [Merged]: Capstone 5.0
  2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
                   ` (31 preceding siblings ...)
  2023-09-15 19:54 ` motorto
@ 2023-09-15 22:00 ` classabbyamp
  32 siblings, 0 replies; 34+ messages in thread
From: classabbyamp @ 2023-09-15 22:00 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 546 bytes --]

There's a merged pull request on the void-packages repository

Capstone 5.0
https://github.com/void-linux/void-packages/pull/44967

Description:
<!-- Uncomment relevant sections and delete options which are not applicable -->

#### Testing the changes
- I tested the changes in this PR: **YES**


#### Local build testing
- I built this PR locally for my native architecture, x86_64-{glibc,musl}
  - aarch64-musl: cross


- makes one qemu test fail
- Boomerang Regressions: https://github.com/BoomerangDecompiler/boomerang/issues/277

^ permalink raw reply	[flat|nested] 34+ messages in thread

end of thread, other threads:[~2023-09-15 22:00 UTC | newest]

Thread overview: 34+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-07-10 15:18 [PR PATCH] Capstone 5.0 motorto
2023-07-10 17:09 ` [PR PATCH] [Updated] " motorto
2023-07-12  0:13 ` [PR REVIEW] " classabbyamp
2023-07-12  0:21 ` classabbyamp
2023-07-12 15:31 ` [PR PATCH] [Updated] " motorto
2023-07-12 15:31 ` motorto
2023-07-14  9:07 ` motorto
2023-07-15 13:17 ` motorto
2023-07-15 16:34 ` XVilka
2023-07-15 19:35 ` motorto
2023-07-31 11:51 ` [PR PATCH] [Updated] " motorto
2023-08-05  7:01 ` XVilka
2023-08-05  7:03 ` XVilka
2023-08-07 15:34 ` [PR PATCH] [Updated] " motorto
2023-08-07 15:37 ` motorto
2023-08-07 15:56 ` [PR PATCH] [Updated] " motorto
2023-08-09 14:04 ` motorto
2023-08-20  2:52 ` XVilka
2023-08-20 22:14 ` [PR PATCH] [Updated] " motorto
2023-08-20 22:17 ` motorto
2023-08-22 10:50 ` [PR PATCH] [Updated] " motorto
2023-08-22 10:51 ` motorto
2023-08-22 16:18 ` classabbyamp
2023-08-23  1:04 ` sgn
2023-08-23  2:41 ` XVilka
2023-08-23 14:05 ` motorto
2023-08-23 14:05 ` motorto
2023-08-23 15:17 ` sgn
2023-08-23 18:02 ` [PR PATCH] [Updated] " motorto
2023-08-23 18:03 ` motorto
2023-09-14  9:51 ` XVilka
2023-09-15 18:10 ` [PR PATCH] [Updated] " motorto
2023-09-15 19:54 ` motorto
2023-09-15 22:00 ` [PR PATCH] [Merged]: " classabbyamp

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).