3 %bcond_with apidocs # build and package API docs [nothing useful as of 0.9.2]
4 %bcond_without static_libs # don't build static libraries
5 %bcond_without tests # don't perform "make test"
7 Summary: Implementation of the bounds-checking C functions
8 Summary(pl.UTF-8): Implementacja funkcji C z kontrolą ograniczeń
14 #Source0Download: http://code.google.com/p/slibc/downloads/list
15 Source0: http://slibc.googlecode.com/files/%{name}-%{version}.tar.gz
16 # Source0-md5: 9400e134e714b1fb94234075e628e1b9
17 Patch0: %{name}-glibc.patch
18 Patch1: %{name}-make.patch
19 URL: http://code.google.com/p/slibc/
20 BuildRequires: libstdc++-devel
21 %{?with_apidocs:BuildRequires: doxygen}
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25 This library provides an implementation of the bounds-checking C
26 functions (as specified in Annex K of the current C standard, a.k.a.
27 C11) for use with the GNU C library.
29 %description -l pl.UTF-8
30 Ta biblioteka udostępnia implementacje funkcji C z kontrolą ograniczeń
31 (zgodnych z Annex K obecnego standardu C, tj. C11), przeznaczone do
32 używania z bibloteką GNU C.
35 Summary: Header files for slibc library
36 Summary(pl.UTF-8): Pliki nagłówkowe biblioteki slibc
37 Group: Development/Libraries
38 Requires: %{name} = %{version}-%{release}
41 Header files for slibc library.
43 %description devel -l pl.UTF-8
44 Pliki nagłówkowe biblioteki slibc.
47 Summary: Static slibc library
48 Summary(pl.UTF-8): Statyczna biblioteka slibc
49 Group: Development/Libraries
50 Requires: %{name}-devel = %{version}-%{release}
55 %description static -l pl.UTF-8
56 Statyczna biblioteka slibc.
59 Summary: %{name} API documentation
60 Summary(pl.UTF-8): Dokumentacja API biblioteki %{name}
64 API and internal documentation for %{name} library.
66 %description apidocs -l pl.UTF-8
67 Dokumentacja API biblioteki %{name}.
78 CFLAGS='%{rpmcflags} -Wall -pthread -fPIC $(INCLUDE_DIRS)' \
79 CXXFLAGS='%{rpmcxxflags} -Wall -pthread -fPIC $(INCLUDE_DIRS)' \
81 %if %{with static_libs}
82 %{__make} -C src libslibc.a libslibc++.a
89 %{?with_tests:%{__make} test}
92 rm -rf $RPM_BUILD_ROOT
94 # make install is broken (as of 0.9.2); do it manually
95 install -d $RPM_BUILD_ROOT{%{_libdir},%{_includedir}/slibc}
96 cp -p include/slibc/*.h* $RPM_BUILD_ROOT%{_includedir}/slibc
97 cp -dp src/libslibc*.so* $RPM_BUILD_ROOT%{_libdir}
98 %if %{with static_libs}
99 cp -p src/libslibc*.a $RPM_BUILD_ROOT%{_libdir}
103 rm -rf $RPM_BUILD_ROOT
105 %post -p /sbin/ldconfig
106 %postun -p /sbin/ldconfig
109 %defattr(644,root,root,755)
110 %doc LICENSES README TODO
111 %attr(755,root,root) %{_libdir}/libslibc.so.*.*.*
112 %attr(755,root,root) %ghost %{_libdir}/libslibc.so.0
113 %attr(755,root,root) %{_libdir}/libslibc++.so.*.*.*
114 %attr(755,root,root) %ghost %{_libdir}/libslibc++.so.0
117 %defattr(644,root,root,755)
118 %attr(755,root,root) %{_libdir}/libslibc.so
119 %attr(755,root,root) %{_libdir}/libslibc++.so
122 %if %{with static_libs}
124 %defattr(644,root,root,755)
125 %{_libdir}/libslibc.a
126 %{_libdir}/libslibc++.a
131 %defattr(644,root,root,755)