mirror of
https://github.com/archlinuxarm/PKGBUILDs.git
synced 2024-11-08 22:45:43 +00:00
63 lines
1.7 KiB
Bash
63 lines
1.7 KiB
Bash
# Maintainer: Felix Yan <felixonmars@archlinux.org>
|
|
# Contributor: Ionut Biru <ibiru@archlinux.org>
|
|
# Contributor: Hugo Doria <hugo@archlinux.org>
|
|
|
|
# ALARM: Kevin Mihelich <kevin@archlinuxarm.org>
|
|
# - explicitly link v5/v6 with libatomic
|
|
|
|
pkgname=libtorrent-rasterbar
|
|
pkgver=1.2.8
|
|
pkgrel=1
|
|
epoch=1
|
|
pkgdesc="A C++ BitTorrent library that aims to be a good alternative to all the other implementations around"
|
|
url="https://www.rasterbar.com/products/libtorrent/"
|
|
arch=('x86_64')
|
|
license=('BSD')
|
|
depends=('boost-libs')
|
|
makedepends=('boost' 'python2' 'python')
|
|
options=('!emptydirs')
|
|
source=(https://github.com/arvidn/libtorrent/releases/download/libtorrent-$pkgver/$pkgname-$pkgver.tar.gz)
|
|
sha512sums=('3669175763b1df96f1a2568b7a51df4e7fdf48033826484db8a5bf6525ec117423cdb23b4c357d7ea1d24ec47cf2ee4a0bbfe5f13e825418de9f8ac2dfee5971')
|
|
|
|
prepare() {
|
|
mkdir py2 py3
|
|
cd $pkgname-$pkgver
|
|
|
|
# Avoid depending on newer processors
|
|
sed -i 's/-msse4.2//' configure.ac
|
|
|
|
autoreconf -if
|
|
}
|
|
|
|
_build() (
|
|
cd py$1
|
|
|
|
# FS#50745
|
|
_boost="boost_python"
|
|
if [ $1 -eq 3 ]; then _boost="boost_python3"; fi
|
|
|
|
[[ $CARCH == "arm" || $CARCH == "armv6h" ]] && LIBS="-latomic"
|
|
LIBS=$LIBS PYTHON=/usr/bin/python$1 \
|
|
../$pkgname-$pkgver/configure \
|
|
--prefix=/usr \
|
|
--enable-python-binding \
|
|
--enable-examples \
|
|
--disable-static \
|
|
--with-libiconv \
|
|
--with-boost-python=$_boost
|
|
)
|
|
|
|
build() {
|
|
_build 2
|
|
_build 3
|
|
}
|
|
|
|
package() {
|
|
make -C py2 DESTDIR="$pkgdir" install
|
|
make -C py3 DESTDIR="$pkgdir" install
|
|
install -Dm644 $pkgname-$pkgver/COPYING \
|
|
"$pkgdir/usr/share/licenses/$pkgname/LICENSE"
|
|
|
|
# Remove most example binaries
|
|
rm "$pkgdir"/usr/bin/{*_test,*_tester,simple_client,stats_counters}
|
|
}
|