3 %bcond_with tests # perform make test
5 Summary: Apache Portable Runtime
6 Summary(pl.UTF-8): Apache Portable Runtime - przenośna biblioteka uruchomieniowa
13 Source0: http://www.apache.org/dist/apr/%{name}-%{version}.tar.bz2
14 # Source0-md5: f8a62f3984898ba0ea8b6f26b851cb99
15 Patch0: %{name}-link.patch
17 # disable some things that require recent kernel
18 Patch2: %{name}-disable-features.patch
19 URL: http://apr.apache.org/
20 BuildRequires: autoconf >= 2.59
21 BuildRequires: automake
22 %if "%{pld_release}" != "ac"
23 BuildRequires: glibc-devel >= 6:2.9
24 BuildRequires: libtool >= 2:2.2
26 BuildRequires: libtool
28 %ifarch armv3l %{armv4} %{armv5} %{armv6}
29 BuildRequires: libatomic-devel
31 BuildRequires: libuuid-devel
33 BuildRequires: rpm >= 4.4.9-56
34 BuildRequires: rpm-pythonprov
35 BuildRequires: rpmbuild(macros) >= 2.007
36 BuildRequires: sed >= 4.0
37 %if "%{pld_release}" != "ac"
38 BuildRequires: uname(release) >= 2.6
39 Requires: uname(release) >= 2.6.28
41 # uuid.h misdetected from this one instead of libuuid-devel
42 BuildConflicts: ossp-uuid-devel < 1.6.2-6
44 Conflicts: kernel24-smp
45 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
47 %define _includedir /usr/include/apr
48 %define _datadir /usr/share/apr
51 The mission of the Apache Portable Runtime (APR) project is to create
52 and maintain software libraries that provide a predictable and
53 consistent interface to underlying platform-specific implementations.
54 The primary goal is to provide an API to which software developers may
55 code and be assured of predictable if not identical behaviour
56 regardless of the platform on which their software is built, relieving
57 them of the need to code special-case conditions to work around or
58 take advantage of platform-specific deficiencies or features.
60 %description -l pl.UTF-8
61 Celem projektu APR (Apache Portable Runtime) jest stworzenie i
62 utrzymywanie bibliotek dostarczających przewidywalnego i spójnego
63 interfejsu do leżących u podstaw implementacji zależnych od platformy.
64 Głównym celem jest dostarczenie API, którego mogą używać programiści
65 mając pewność, że zachowuje się w sposób przewidywalny, jeśli nie
66 identyczny, niezależnie od platformy na jakiej oprogramowanie jest
67 budowane oraz bez potrzeby kodowania specjalnych warunków do
68 obchodzenia lub wykorzystywania specyficznych dla platform różnic lub
72 Summary: Header files and development documentation for apr
73 Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja programisty do apr
74 Group: Development/Libraries
75 Requires: %{name} = %{epoch}:%{version}-%{release}
77 %if "%{pld_release}" != "ac"
78 Requires: libtool >= 2:2.2
82 Requires: libuuid-devel
83 Requires: python-modules
86 Header files and development documentation for apr.
88 %description devel -l pl.UTF-8
89 Pliki nagłówkowe i dokumentacja programisty do apr.
92 Summary: Static apr library
93 Summary(pl.UTF-8): Statyczna biblioteka apr
94 Group: Development/Libraries
95 Requires: %{name}-devel = %{epoch}:%{version}-%{release}
100 %description static -l pl.UTF-8
101 Statyczna biblioteka apr.
109 cat >> config.layout <<'EOF'
112 libexecdir: %{_libdir}/apr
113 installbuilddir: ${datadir}/build-${APR_MAJOR_VERSION}
114 localstatedir: /var/run
116 libsuffix: -${APR_MAJOR_VERSION}
121 install /usr/share/automake/config.* build
125 %ifarch armv3l %{armv4} %{armv5} %{armv6}
128 --enable-layout=PLD \
129 %ifarch %{ix86} %{x8664}
131 --enable-nonportable-atomics \
134 --enable-pool-concurrency-check \
136 --with-devrandom=/dev/urandom
139 %{?with_tests:%{__make} -j1 check}
142 rm -rf $RPM_BUILD_ROOT
145 DESTDIR=$RPM_BUILD_ROOT
147 mv -f $RPM_BUILD_ROOT%{_datadir}/build-1 $RPM_BUILD_ROOT%{_datadir}/build
148 install build/{*apr*.m4,*.awk,*.sh,gen-build.py} $RPM_BUILD_ROOT%{_datadir}/build
149 ln -snf /usr/share/automake/config.{guess,sub} $RPM_BUILD_ROOT%{_datadir}/build
150 if [ -f /usr/share/libtool/config/ltmain.sh ]; then
151 ln -snf /usr/share/libtool/config/ltmain.sh $RPM_BUILD_ROOT%{_datadir}/build
153 ln -snf /usr/share/libtool/ltmain.sh $RPM_BUILD_ROOT%{_datadir}/build
155 ln -snf /usr/bin/libtool $RPM_BUILD_ROOT%{_datadir}/build
156 ln -sf build $RPM_BUILD_ROOT%{_datadir}/build-1
158 sed -i -e 's@^\(APR_SOURCE_DIR=\).*@\1"%{_datadir}"@' \
159 $RPM_BUILD_ROOT%{_bindir}/apr-1-config
160 sed -i -e 's@^\(apr_builddir\|apr_builders\)=.*@\1=%{_datadir}/build-1@' \
161 $RPM_BUILD_ROOT%{_datadir}/build/apr_rules.mk
162 sed -i -e '1s@#!.*python@#!%{__python}@' $RPM_BUILD_ROOT%{_datadir}/build/gen-build.py
165 rm -rf $RPM_BUILD_ROOT
167 %post -p /sbin/ldconfig
168 %postun -p /sbin/ldconfig
171 %defattr(644,root,root,755)
172 %doc CHANGES docs/*.html
173 %attr(755,root,root) %{_libdir}/libapr-1.so.*.*.*
174 %attr(755,root,root) %ghost %{_libdir}/libapr-1.so.0
177 %defattr(644,root,root,755)
178 %attr(755,root,root) %{_bindir}/apr-1-config
179 %attr(755,root,root) %{_libdir}/libapr-1.so
180 %{_libdir}/libapr-1.la
184 %dir %{_datadir}/build
185 %{_datadir}/build/*.mk
186 %{_datadir}/build/*.m4
187 %{_datadir}/build/*.awk
188 %attr(755,root,root) %{_datadir}/build/config.*
189 %attr(755,root,root) %{_datadir}/build/*.sh
190 %attr(755,root,root) %{_datadir}/build/libtool
191 %attr(755,root,root) %{_datadir}/build/gen-build.py
193 %{_pkgconfigdir}/apr-1.pc
196 %defattr(644,root,root,755)
197 %{_libdir}/libapr-1.a