aboutsummaryrefslogtreecommitdiffstats
path: root/main/libmtp/APKBUILD
blob: f690f42b8d15f0cbf5207268dc6c742e911bc6fb (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
# Contributor: Natanael Copa <ncopa@alpinelinux.org>
# Maintainer: Natanael Copa <ncopa@alpinelinux.org>
pkgname=libmtp
pkgver=1.1.14
pkgrel=0
pkgdesc="A software library for MTP media players"
url="http://libmtp.sourceforge.net/"
arch="all"
license="LGPL-2.0-or-later"
depends=""
depends_dev="libusb-compat-dev"
makedepends="$depends_dev eudev-dev"
install=""
subpackages="$pkgname-dev $pkgname-examples"
source="http://download.sourceforge.net/libmtp/$pkgname-$pkgver.tar.gz"
builddir="$srcdir"/$pkgname-$pkgver

check() {
	cd "$builddir"
	make check
}

build() {
	cd "$builddir"
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--mandir=/usr/share/man \
		--infodir=/usr/share/info \
		--localstatedir=/var \
		--with-udev=/lib/udev
	make
}

package() {
	cd "$builddir"
	make DESTDIR="$pkgdir" install
}

examples() {
	pkgdesc="Example programs for libmtp"
	mkdir -p "$subpkgdir"/usr
	mv "$pkgdir"/usr/bin "$subpkgdir"/usr/
}

sha512sums="337d259462cf9700fe5a5f09b38f4652045ee71249d54562661362e6d0ec7fe087ab77ec68d443e4fb84839a8ad9dc686c207d723ab47bc1a542dd0a71b294b1  libmtp-1.1.14.tar.gz"