From 4d62226da605870a7855f3d5fee05cd32c76466d Mon Sep 17 00:00:00 2001 From: Shahab Vahedi Date: Thu, 28 Nov 2019 12:00:36 +0100 Subject: [PATCH] Fix include path in pkgconfig for v4.0.1 This is fixed upstream but not _released_ yet: https://github.com/aquynh/capstone/issues/1339 This patch doesn't need to be applied if there is a newer version. Signed-off-by: Shahab Vahedi --- trunk/PKGBUILD | 16 ++++++++++++---- trunk/fix_include_path_in_pkgconfig.patch | 12 ++++++++++++ 2 files changed, 24 insertions(+), 4 deletions(-) create mode 100644 trunk/fix_include_path_in_pkgconfig.patch diff --git a/trunk/PKGBUILD b/trunk/PKGBUILD index 138c275..a79f912 100644 --- a/trunk/PKGBUILD +++ b/trunk/PKGBUILD @@ -4,16 +4,24 @@ pkgbase=capstone pkgname=('capstone' 'python-capstone') pkgver=4.0.1 -pkgrel=3 +pkgrel=4 pkgdesc='Lightweight multi-platform, multi-architecture disassembly framework' url='https://www.capstone-engine.org/index.html' arch=('x86_64') license=('BSD') makedepends=('glibc' 'python' 'python-setuptools') options=('staticlibs') -source=(${pkgname}-${pkgver}.tar.gz::https://github.com/aquynh/capstone/archive/${pkgver}.tar.gz) -sha256sums=('79bbea8dbe466bd7d051e037db5961fdb34f67c9fac5c3471dd105cfb1e05dc7') -sha512sums=('43c52024065b41b45eff9423341db3f3d5163fa7aa01b360faa30437786740c8f2c34c36faa04dced5308e09d8bd78df3bad0ab9c06f98612169edb176f83c36') +source=(${pkgname}-${pkgver}.tar.gz::https://github.com/aquynh/capstone/archive/${pkgver}.tar.gz + fix_include_path_in_pkgconfig.patch) +sha256sums=('79bbea8dbe466bd7d051e037db5961fdb34f67c9fac5c3471dd105cfb1e05dc7' + 'c72dcd28371e15654c11cf593456673f7d1c3e85535d622405d7ae1e753f3733') +sha512sums=('43c52024065b41b45eff9423341db3f3d5163fa7aa01b360faa30437786740c8f2c34c36faa04dced5308e09d8bd78df3bad0ab9c06f98612169edb176f83c36' + '3d9a24744a69579c7c61a0adbb44c5f4f765ca6b9d632891ad36e99166d2988e69cbf752344d1f2279b74a2bf0983ab6f0633528117299f3de3935be250c2716') + +prepare() { + cd ${pkgname}-${pkgver} + patch --forward --strip=1 --input="../fix_include_path_in_pkgconfig.patch" +} build() { cd ${pkgbase}-${pkgver} diff --git a/trunk/fix_include_path_in_pkgconfig.patch b/trunk/fix_include_path_in_pkgconfig.patch new file mode 100644 index 0000000..c44c52b --- /dev/null +++ b/trunk/fix_include_path_in_pkgconfig.patch @@ -0,0 +1,12 @@ +diff --unified --recursive --text a/Makefile b/Makefile +--- a/Makefile 2019-01-10 14:45:56.000000000 +0100 ++++ b/Makefile 2019-11-28 11:33:43.699065525 +0100 +@@ -514,7 +514,7 @@ + echo 'Description: Capstone disassembly engine' >> $(PKGCFGF) + echo 'Version: $(PKG_VERSION)' >> $(PKGCFGF) + echo 'libdir=$(LIBDIR)' >> $(PKGCFGF) +- echo 'includedir=$(INCDIR)' >> $(PKGCFGF) ++ echo 'includedir=$(INCDIR)/capstone' >> $(PKGCFGF) + echo 'archive=$${libdir}/libcapstone.a' >> $(PKGCFGF) + echo 'Libs: -L$${libdir} -lcapstone' >> $(PKGCFGF) + echo 'Cflags: -I$${includedir}' >> $(PKGCFGF) -- 2.24.0