diff --git a/node-gyp/lure.sh b/node-gyp/lure.sh index 93ecf31..6d2fd98 100644 --- a/node-gyp/lure.sh +++ b/node-gyp/lure.sh @@ -14,10 +14,13 @@ build_deps=('npm') sources=("https://registry.npmjs.org/node-gyp/-/node-gyp-${version}.tgz?~archive=false") checksums=('SKIP') -package() { - npm install -g --prefix "${pkgdir}/usr node-gyp-${version}.tgz" +prepare() { + cd "${srcdir}" + npm install -g --prefix "${pkgdir}/usr" "node-gyp-${version}.tgz" rm -r "${pkgdir}/usr/lib/node_modules/node-gyp/node_modules/{,.bin/}nopt" rm -r "${pkgdir}/usr/lib/node_modules/node-gyp/node_modules/{,.bin/}semver" +} +package() { install -d "${pkgdir}/usr/share/licenses/node-gyp" ln -s ../../../lib/node_modules/node-gyp/LICENSE "${pkgdir}/usr/share/licenses/node-gyp/LICENSE" }