2 Summary: Node.js native addon build tool
7 Group: Development/Libraries
8 URL: https://github.com/TooTallNate/node-gyp
9 Source0: http://registry.npmjs.org/node-gyp/-/node-gyp-%{version}.tgz
10 # Source0-md5: 3d8a5cf4b5b92457af68035bb0e0e96f
11 Patch0: jobs-alias.patch
12 Patch1: system-gyp.patch
13 Patch2: link-libnode.patch
14 BuildRequires: sed >= 4.0
18 Requires: nodejs-devel
19 Requires: nodejs-fstream
20 Requires: nodejs-glob < 4.0.0
21 Requires: nodejs-glob >= 3.0.0
22 Requires: nodejs-graceful-fs < 2.0.0
23 Requires: nodejs-graceful-fs >= 1.0.0
24 Requires: nodejs-minimatch
25 Requires: nodejs-mkdirp
26 Requires: nodejs-nopt < 3.0.0
27 Requires: nodejs-nopt >= 2.0.0
28 Requires: nodejs-npmlog < 1.0.0
29 Requires: nodejs-osenv < 1.0.0
30 Requires: nodejs-request < 3
31 Requires: nodejs-request >= 2
32 Requires: nodejs-rimraf < 3.0.0
33 Requires: nodejs-rimraf >= 2.0.0
34 Requires: nodejs-semver < 2.0.0
35 Requires: nodejs-semver >= 1.0.0
37 Requires: nodejs-which < 2.0.0
38 Requires: nodejs-which >= 1.0.0
40 Obsoletes: node-node-gyp
42 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
45 node-gyp is a cross-platform command-line tool written in Node.js for
46 compiling native addon modules for Node.js, which takes away the pain
47 of dealing with the various differences in build platforms. It is the
48 replacement to the node-waf program which is removed for node v0.8.
58 %{__sed} -i -e '1s,^#!.*node,#!/usr/bin/node,' \
62 rm -rf $RPM_BUILD_ROOT
64 install -d $RPM_BUILD_ROOT%{nodejs_libdir}/%{pkg}
65 cp -pr bin lib legacy package.json $RPM_BUILD_ROOT%{nodejs_libdir}/%{pkg}
66 cp -pr *.gyp* $RPM_BUILD_ROOT%{nodejs_libdir}/%{pkg}
68 install -d $RPM_BUILD_ROOT%{_bindir}
69 ln -s %{nodejs_libdir}/%{pkg}/bin/node-gyp.js $RPM_BUILD_ROOT%{_bindir}/node-gyp
72 rm -rf $RPM_BUILD_ROOT
75 %defattr(644,root,root,755)
76 %doc README.md LICENSE
77 %attr(755,root,root) %{_bindir}/node-gyp
78 %dir %{nodejs_libdir}/%{pkg}
79 %{nodejs_libdir}/%{pkg}/package.json
80 %{nodejs_libdir}/%{pkg}/addon.gypi
81 %{nodejs_libdir}/%{pkg}/lib
82 %dir %{nodejs_libdir}/%{pkg}/bin
83 %attr(755,root,root) %{nodejs_libdir}/%{pkg}/bin/node-gyp.js
86 %{nodejs_libdir}/%{pkg}/legacy