]>
Commit | Line | Data |
---|---|---|
ed65a017 ER |
1 | # |
2 | # Conditional build: | |
3 | %bcond_with tests # build with tests (require network access) | |
4 | ||
35f93c77 ER |
5 | Summary: Platform layer for node.js |
6 | Name: libuv | |
53aa5faf | 7 | Version: 1.6.1 |
d95c2c81 | 8 | Release: 1 |
9b353dfd ER |
9 | # the licensing breakdown is described in detail in the LICENSE file |
10 | License: MIT and BSD and ISC | |
35f93c77 | 11 | Group: Development/Tools |
d95c2c81 | 12 | Source0: http://dist.libuv.org/dist/v%{version}/%{name}-v%{version}.tar.gz |
53aa5faf | 13 | # Source0-md5: 51cfa3d8adc05852982e3c742ec3c039 |
351466ac ER |
14 | URL: http://libuv.org/ |
15 | BuildRequires: automake >= 1:1.12 | |
fcb1ba24 ER |
16 | BuildRequires: libstdc++-devel |
17 | BuildRequires: pkgconfig | |
2b5915b2 | 18 | BuildRequires: python-gyp |
35f93c77 ER |
19 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
20 | ||
35f93c77 ER |
21 | %description |
22 | libuv is a new platform layer for Node. Its purpose is to abstract | |
23 | IOCP on Windows and libev on Unix systems. We intend to eventually | |
24 | contain all platform differences in this library. | |
25 | ||
26 | %package devel | |
27 | Summary: Development libraries for libuv | |
28 | Group: Development/Tools | |
29 | Requires: %{name} = %{version}-%{release} | |
30 | ||
31 | %description devel | |
9b353dfd | 32 | Development libraries for libuv. |
35f93c77 ER |
33 | |
34 | %prep | |
35 | %setup -q -n %{name}-v%{version} | |
35f93c77 | 36 | |
351466ac ER |
37 | # serial-tests is available in v1.12 and newer. |
38 | echo "m4_define([UV_EXTRA_AUTOMAKE_FLAGS], [serial-tests])" > m4/libuv-extra-automake-flags.m4 | |
35f93c77 | 39 | |
351466ac ER |
40 | %build |
41 | %{__libtoolize} | |
42 | %{__aclocal} -I m4 | |
43 | %{__autoconf} | |
44 | %{__automake} | |
45 | %configure \ | |
46 | --disable-silent-rules \ | |
47 | --disable-static | |
48 | %{__make} | |
35f93c77 ER |
49 | |
50 | %if %{with tests} | |
ed65a017 ER |
51 | ./run-tests |
52 | ./run-benchmarks | |
35f93c77 ER |
53 | %endif |
54 | ||
55 | %install | |
56 | rm -rf $RPM_BUILD_ROOT | |
351466ac ER |
57 | %{__make} install \ |
58 | DESTDIR=$RPM_BUILD_ROOT | |
35f93c77 | 59 | |
351466ac ER |
60 | # obsoleted by .pc file |
61 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libuv.la | |
35f93c77 ER |
62 | |
63 | %clean | |
64 | rm -rf $RPM_BUILD_ROOT | |
65 | ||
66 | %post -p /sbin/ldconfig | |
67 | %postun -p /sbin/ldconfig | |
68 | ||
69 | %files | |
70 | %defattr(644,root,root,755) | |
71 | %doc README.md AUTHORS LICENSE | |
72 | %attr(755,root,root) %{_libdir}/libuv.so.*.*.* | |
351466ac | 73 | %ghost %{_libdir}/libuv.so.1 |
35f93c77 ER |
74 | |
75 | %files devel | |
76 | %defattr(644,root,root,755) | |
35f93c77 ER |
77 | %{_libdir}/libuv.so |
78 | %{_pkgconfigdir}/libuv.pc | |
79 | %{_includedir}/uv.h | |
351466ac ER |
80 | %{_includedir}/uv-errno.h |
81 | %{_includedir}/uv-linux.h | |
82 | %{_includedir}/uv-threadpool.h | |
83 | %{_includedir}/uv-unix.h | |
84 | %{_includedir}/uv-version.h |