]>
Commit | Line | Data |
---|---|---|
210abff9 | 1 | |
210abff9 | 2 | Summary: Asynchronous JavaScript Engine |
3 | Name: nodejs | |
afb1c7e5 PZ |
4 | Version: 0.4.11 |
5 | Release: 1 | |
210abff9 | 6 | License: BSD |
7 | Group: Libraries | |
8 | URL: http://nodejs.org/ | |
9 | Source0: http://nodejs.org/dist/node-v%{version}.tar.gz | |
afb1c7e5 | 10 | # Source0-md5: ac4c3eaa0667d5e3eacf56fd26a4eadc |
a3293030 | 11 | Patch0: %{name}-ev-multiplicity.patch |
fb6f511a | 12 | Patch1: %{name}-soname.patch |
a3293030 | 13 | BuildRequires: c-ares-devel |
14 | BuildRequires: c-ares-devel >= 1.7.4 | |
12a49d35 | 15 | BuildRequires: gcc >= 5:4.0 |
210abff9 | 16 | BuildRequires: libeio-devel |
a3293030 | 17 | BuildRequires: libev-devel >= 4.0.0 |
210abff9 | 18 | BuildRequires: libstdc++-devel |
19 | BuildRequires: python | |
12a49d35 | 20 | BuildRequires: rpm >= 4.4.9-56 |
2bc97491 | 21 | BuildRequires: v8-devel >= 3.1.5 |
210abff9 | 22 | ExclusiveArch: %{ix86} %{x8664} arm |
23 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
24 | ||
e47cb1b9 | 25 | %define _plainlibdir %{_prefix}/lib |
26 | ||
210abff9 | 27 | %description |
28 | Node's goal is to provide an easy way to build scalable network | |
29 | programs. In the above example, the two second delay does not prevent | |
30 | the server from handling new requests. Node tells the operating system | |
31 | (through epoll, kqueue, /dev/poll, or select) that it should be | |
32 | notified when the 2 seconds are up or if a new connection is made -- | |
33 | then it goes to sleep. If someone new connects, then it executes the | |
34 | callback, if the timeout expires, it executes the inner callback. Each | |
35 | connection is only a small heap allocation. | |
36 | ||
210abff9 | 37 | %package devel |
12a49d35 | 38 | Summary: Development headers for nodejs |
210abff9 | 39 | Group: Development/Libraries |
a8f57a3f | 40 | Requires: %{name} = %{version}-%{release} |
210abff9 | 41 | |
42 | %description devel | |
12a49d35 | 43 | Development headers for nodejs. |
210abff9 | 44 | |
45 | %prep | |
46 | %setup -q -n node-v%{version} | |
a3293030 | 47 | %patch0 -p1 |
fb6f511a | 48 | %patch1 -p1 |
210abff9 | 49 | |
50 | %build | |
51 | # build library | |
210abff9 | 52 | CFLAGS="%{rpmcflags}" |
53 | CXXFLAGS="%{rpmcxxflags}" | |
54 | LDFLAGS="%{rpmcflags}" | |
55 | %if "%{pld_release}" == "ac" | |
56 | CC=%{__cc}4 | |
57 | CXX=%{__cxx}4 | |
58 | %else | |
59 | CC=%{__cc} | |
60 | CXX=%{__cxx} | |
61 | %endif | |
58494f0c | 62 | export CFLAGS LDFLAGS CXXFLAGS CC CXX |
210abff9 | 63 | |
afb1c7e5 | 64 | ./configure \ |
b52d635c | 65 | --shared-v8 \ |
66 | --shared-cares \ | |
67 | --shared-libev \ | |
a8f57a3f | 68 | --libdir=%{_libdir} \ |
210abff9 | 69 | --prefix=%{_prefix} |
70 | ||
afb1c7e5 | 71 | make |
210abff9 | 72 | |
73 | %install | |
74 | rm -rf $RPM_BUILD_ROOT | |
a8f57a3f | 75 | |
afb1c7e5 | 76 | DESTDIR=$RPM_BUILD_ROOT make install |
a752c1c0 | 77 | |
210abff9 | 78 | %clean |
79 | rm -rf $RPM_BUILD_ROOT | |
80 | ||
210abff9 | 81 | %files |
82 | %defattr(644,root,root,755) | |
83 | %doc AUTHORS ChangeLog LICENSE | |
84 | %attr(755,root,root) %{_bindir}/node | |
210abff9 | 85 | %dir %{_libdir}/node |
210abff9 | 86 | %{_mandir}/man1/node.1* |
87 | ||
210abff9 | 88 | %files devel |
89 | %defattr(644,root,root,755) | |
58494f0c | 90 | %{_includedir}/node |
c6be74cc | 91 | %attr(755,root,root) %{_bindir}/node-waf |
afb1c7e5 PZ |
92 | %dir %{_libdir}/node/wafadmin |
93 | %dir %{_libdir}/node/wafadmin/Tools | |
94 | %{_libdir}/node/wafadmin/*.py | |
95 | %{_libdir}/node/wafadmin/Tools/*.py | |
a8f57a3f | 96 | %{_libdir}/pkgconfig/nodejs.pc |