blob: 59d2f10188bb0d07a01e3af329ad13c2228339a5 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
# Merged with official ABS distorm PKGBUILD by João, 2023/05/14 (all respective contributors apply herein)
# Maintainer: João Figueiredo <islandc0der@chaotic.cx>
# Contributor: Levente Polyak <anthraxx[at]archlinux[dot]org>
# Contributor: Mike Sampson <mike at sambodata dot com>
# Contributor: Dmitry A. Ilyashevich <dmitry.ilyashevich@gmail.com>
pkgbase=distorm-git
pkgname=(distorm-git python-distorm-git)
pkgver=3.5.2b_r321.g7a02caa
pkgrel=1
pkgdesc='Powerful disassembler library for x86/AMD64'
url='https://github.com/gdabah/distorm'
arch=($CARCH)
license=(BSD)
makedepends=(git python python-setuptools glibc)
conflicts=(${pkgname%-git})
provides=(${pkgname%-git})
options=(staticlibs)
source=("git+https://github.com/gdabah/${pkgbase%-git}.git")
sha256sums=('SKIP')
pkgver() {
cd ${pkgbase%-git}
_ver="$(git describe --tags | sed 's/^v//;s/-.*//')"
echo "${_ver}_r$(git rev-list --count HEAD).g$(git rev-parse --short HEAD)"
}
build() {
cd ${pkgbase%-git}
make -C make/linux CFLAGS="${CFLAGS} ${CPPFLAGS} -fPIC"
python setup.py build
}
package_distorm-git() {
depends=('glibc')
provides=('libdistorm3.so')
cd ${pkgbase%-git}
make -C make/linux PREFIX=/usr DESTDIR="${pkgdir}" install
install -Dm 644 include/*.h -t "${pkgdir}/usr/include"
install -Dm 644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname%-git}"
ln -sf "/usr/lib/libdistorm3.so.$(grep 'LIB_R_VERSION =' make/linux/Makefile|cut -d' ' -f3)" "${pkgdir}/usr/lib/libdistorm3.so"
}
package_python-distorm-git() {
depends=('python')
cd ${pkgbase%-git}
python setup.py install --root="${pkgdir}" -O1 --skip-build
install -Dm 644 COPYING -t "${pkgdir}/usr/share/licenses/${pkgname%-git}"
}
|