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