diff --git a/aur/libuv/PKGBUILD b/aur/libuv/PKGBUILD new file mode 100644 index 000000000..26689e1b8 --- /dev/null +++ b/aur/libuv/PKGBUILD @@ -0,0 +1,49 @@ +# Maintainer: Massimiliano Torromeo + +pkgname=libuv +pkgver=0.10.0 +pkgrel=1 +pkgdesc="libuv is a new platform layer for Node.JS" +arch=('i686' 'x86_64') +url="https://github.com/joyent/libuv" +license=('custom') +depends=('glibc') +source=("https://github.com/joyent/libuv/archive/node-v$pkgver.tar.gz") + +build() { + cd "$srcdir" + _tardir=$(tar -tzf node-v$pkgver.tar.gz --exclude "*/*" | head -n 1) + cd "$_tardir" + + CFLAGS=-fPIC make +} + +check() { + cd "$srcdir" + _tardir=$(tar -tzf node-v$pkgver.tar.gz --exclude "*/*" | head -n 1) + cd "$_tardir" + + make test +} + +package() { + cd "$srcdir" + _tardir=$(tar -tzf node-v$pkgver.tar.gz --exclude "*/*" | head -n 1) + cd "$_tardir" + + install -Dm644 LICENSE \ + "$pkgdir/usr/share/licenses/$pkgname/LICENSE" + install -Dm644 AUTHORS \ + "$pkgdir/usr/share/doc/$pkgname/AUTHORS" + install -Dm644 README.md \ + "$pkgdir/usr/share/doc/$pkgname/README.md" + + install -Dm644 libuv.a "$pkgdir/usr/lib/libuv.a" + install -Dm644 libuv.so "$pkgdir/usr/lib/libuv.so" + + cd include + find -type f -exec \ + install -Dm644 {} "$pkgdir/usr/include/$pkgname/"{} \; +} + +sha256sums=('82bc2a53cf9bda76dce5b0523afafe4226baaa9654608c083c28dea814b8fd10')