[arch-commits] Commit in npm/repos (2 files)
Felix Yan
fyan at archlinux.org
Fri May 1 09:32:06 UTC 2015
Date: Friday, May 1, 2015 @ 11:32:06
Author: fyan
Revision: 132579
archrelease: copy trunk to community-testing-any
Added:
npm/repos/community-testing-any/
npm/repos/community-testing-any/PKGBUILD
(from rev 132578, npm/trunk/PKGBUILD)
----------+
PKGBUILD | 44 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 44 insertions(+)
Copied: npm/repos/community-testing-any/PKGBUILD (from rev 132578, npm/trunk/PKGBUILD)
===================================================================
--- community-testing-any/PKGBUILD (rev 0)
+++ community-testing-any/PKGBUILD 2015-05-01 09:32:06 UTC (rev 132579)
@@ -0,0 +1,44 @@
+# $Id$
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgname=npm
+pkgver=2.9.0
+pkgrel=1
+pkgdesc='A package manager for javascript'
+arch=('any')
+url='https://www.npmjs.com/'
+license=('custom:Artistic')
+depends=('nodejs')
+provides=('nodejs-node-gyp')
+makedepends=('git' 'procps-ng')
+optdepends=('python2: for node-gyp')
+options=('!emptydirs')
+source=("git+https://github.com/npm/npm.git#tag=v$pkgver")
+md5sums=('SKIP')
+
+build() {
+ cd npm
+ make
+}
+
+package() {
+ cd npm
+ make NPMOPTS="--prefix=\"$pkgdir/usr\"" install
+
+ # Fix files owned by nobody:
+ chown -R root "$pkgdir/usr/lib/node_modules"
+
+ # Fix wrong symlinks
+ rm -f "$pkgdir"/usr/share/man/{man1,man3,man5,man7}/*
+ for _dir in man1 man3 man5 man7; do
+ cd "$pkgdir"/usr/lib/node_modules/npm/man/$_dir
+ for _file in *; do
+ ln -s /usr/lib/node_modules/npm/man/$_dir/$_file "$pkgdir"/usr/share/man/$_dir/
+ done
+ done
+
+ # Make symlink for node-gyp
+ ln -s /usr/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js "$pkgdir"/usr/bin/node-gyp
+
+ install -Dm644 "$srcdir/npm/LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE"
+}
More information about the arch-commits
mailing list