summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: 7a6a3951d12c5613be1ddc11c55bced3f860dcb5 (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
# Maintainer: Tony Lambiris <tony@libpcap.net

pkgname=double-conversion-git
pkgver=3.3.0.r2.gd42b33c
pkgrel=1
pkgdesc='Efficient binary-decimal and decimal-binary conversion routines for IEEE doubles.'
arch=(i686 x86_64)
url='https://github.com/google/double-conversion'
license=(BSD)
conflicts=(double-conversion)
provides=(double-conversion)
depends=(gcc-libs)
makedepends=(git scons cmake)
source=("${pkgname}::git+https://github.com/google/double-conversion.git")
sha256sums=('SKIP')

pkgver() {
	cd "${srcdir}/${pkgname}"

	git describe --long --tags | sed 's/\([^-]*-g\)/r\1/;s/-/./g;s/^v//g'
}

prepare() {
	mkdir -p build
}

build() {
	cd build

	cmake ../${pkgname} \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DBUILD_SHARED_LIBS=ON
	make
}

package () {
	cd build

	make DESTDIR="${pkgdir}" install

	install -Dm644 "${srcdir}/${pkgname}/LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}