]> git.pld-linux.org Git - packages/apr.git/blame - apr.spec
Up to 1.7.4
[packages/apr.git] / apr.spec
CommitLineData
c4dbb403
JB
1#
2# Conditional build:
3%bcond_with tests # perform make test
4#
f3bf17ad 5Summary: Apache Portable Runtime
e51e866d 6Summary(pl.UTF-8): Apache Portable Runtime - przenośna biblioteka uruchomieniowa
f3bf17ad 7Name: apr
01725d11 8Version: 1.7.4
e642a4bb 9Release: 1
f3bf17ad 10Epoch: 1
b34d84ea 11License: Apache v2.0
f3bf17ad 12Group: Libraries
55e3eaa9 13Source0: http://www.apache.org/dist/apr/%{name}-%{version}.tar.bz2
01725d11 14# Source0-md5: f8a62f3984898ba0ea8b6f26b851cb99
9e32e98f 15Patch0: %{name}-link.patch
e642a4bb 16
0146b639
AM
17# disable some things that require recent kernel
18Patch2: %{name}-disable-features.patch
f3bf17ad 19URL: http://apr.apache.org/
cd9a5e0f 20BuildRequires: autoconf >= 2.59
c7edcef5 21BuildRequires: automake
df8efb25 22%if "%{pld_release}" != "ac"
0db5a6e1 23BuildRequires: glibc-devel >= 6:2.9
1b25cd0a 24BuildRequires: libtool >= 2:2.2
df8efb25
ER
25%else
26BuildRequires: libtool
27%endif
03334729
JP
28%ifarch armv3l %{armv4} %{armv5} %{armv6}
29BuildRequires: libatomic-devel
30%endif
69f0f35f 31BuildRequires: libuuid-devel
9e32e98f 32BuildRequires: python
df8efb25 33BuildRequires: rpm >= 4.4.9-56
7bac6e65 34BuildRequires: rpm-pythonprov
03334729 35BuildRequires: rpmbuild(macros) >= 2.007
df8efb25
ER
36BuildRequires: sed >= 4.0
37%if "%{pld_release}" != "ac"
1c519bd4 38BuildRequires: uname(release) >= 2.6
de68380e 39Requires: uname(release) >= 2.6.28
df8efb25 40%endif
97865247
AM
41# uuid.h misdetected from this one instead of libuuid-devel
42BuildConflicts: ossp-uuid-devel < 1.6.2-6
52336182
JB
43Conflicts: kernel24
44Conflicts: kernel24-smp
f3bf17ad
AM
45BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
47%define _includedir /usr/include/apr
48%define _datadir /usr/share/apr
49
50%description
51The mission of the Apache Portable Runtime (APR) project is to create
52and maintain software libraries that provide a predictable and
53consistent interface to underlying platform-specific implementations.
54The primary goal is to provide an API to which software developers may
55code and be assured of predictable if not identical behaviour
56regardless of the platform on which their software is built, relieving
57them of the need to code special-case conditions to work around or
58take advantage of platform-specific deficiencies or features.
59
a79d9376 60%description -l pl.UTF-8
b4838f76 61Celem projektu APR (Apache Portable Runtime) jest stworzenie i
a79d9376
JR
62utrzymywanie bibliotek dostarczających przewidywalnego i spójnego
63interfejsu do leżących u podstaw implementacji zależnych od platformy.
64Głównym celem jest dostarczenie API, którego mogą używać programiści
65mając pewność, że zachowuje się w sposób przewidywalny, jeśli nie
66identyczny, niezależnie od platformy na jakiej oprogramowanie jest
67budowane oraz bez potrzeby kodowania specjalnych warunków do
68obchodzenia lub wykorzystywania specyficznych dla platform różnic lub
69możliwości.
b4838f76 70
f3bf17ad 71%package devel
b4838f76 72Summary: Header files and development documentation for apr
e51e866d 73Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja programisty do apr
f3bf17ad 74Group: Development/Libraries
b4838f76 75Requires: %{name} = %{epoch}:%{version}-%{release}
d53f5760 76Requires: automake
df8efb25 77%if "%{pld_release}" != "ac"
1b25cd0a 78Requires: libtool >= 2:2.2
df8efb25
ER
79%else
80Requires: libtool
81%endif
d9cfa95e 82Requires: libuuid-devel
7bac6e65 83Requires: python-modules
f3bf17ad
AM
84
85%description devel
b4838f76
JB
86Header files and development documentation for apr.
87
a79d9376
JR
88%description devel -l pl.UTF-8
89Pliki nagłówkowe i dokumentacja programisty do apr.
f3bf17ad
AM
90
91%package static
92Summary: Static apr library
e51e866d 93Summary(pl.UTF-8): Statyczna biblioteka apr
f3bf17ad 94Group: Development/Libraries
b4838f76 95Requires: %{name}-devel = %{epoch}:%{version}-%{release}
f3bf17ad
AM
96
97%description static
98Static apr library.
99
a79d9376 100%description static -l pl.UTF-8
b4838f76
JB
101Statyczna biblioteka apr.
102
f3bf17ad 103%prep
af4e4c47 104%setup -q
9e32e98f 105%patch0 -p1
e642a4bb 106
e0b90f27 107%patch2 -p1
f3bf17ad 108
13f3c811
JB
109cat >> config.layout <<'EOF'
110<Layout PLD>
111sbindir: %{_sbindir}
112libexecdir: %{_libdir}/apr
113installbuilddir: ${datadir}/build-${APR_MAJOR_VERSION}
114localstatedir: /var/run
115runtimedir: /var/run
116libsuffix: -${APR_MAJOR_VERSION}
2523b113 117</Layout>
13f3c811
JB
118EOF
119
f3bf17ad 120%build
b34d84ea 121install /usr/share/automake/config.* build
cb4191bc 122%{__autoconf}
2523b113 123
f3bf17ad 124%configure \
03334729
JP
125%ifarch armv3l %{armv4} %{armv5} %{armv6}
126 LIBS="-latomic" \
127%endif
13f3c811 128 --enable-layout=PLD \
3c7d7510 129%ifarch %{ix86} %{x8664}
02a2518a 130%ifnarch i386
131 --enable-nonportable-atomics \
132%endif
133%endif
d28763da 134 --enable-pool-concurrency-check \
13f3c811
JB
135 --enable-threads \
136 --with-devrandom=/dev/urandom
f3bf17ad
AM
137%{__make}
138
9339f747 139%{?with_tests:%{__make} -j1 check}
7bcdeaec 140
f3bf17ad
AM
141%install
142rm -rf $RPM_BUILD_ROOT
143
144%{__make} install \
145 DESTDIR=$RPM_BUILD_ROOT
146
9e32e98f 147mv -f $RPM_BUILD_ROOT%{_datadir}/build-1 $RPM_BUILD_ROOT%{_datadir}/build
16773349 148install build/{*apr*.m4,*.awk,*.sh,gen-build.py} $RPM_BUILD_ROOT%{_datadir}/build
d53f5760 149ln -snf /usr/share/automake/config.{guess,sub} $RPM_BUILD_ROOT%{_datadir}/build
d522858e
ER
150if [ -f /usr/share/libtool/config/ltmain.sh ]; then
151 ln -snf /usr/share/libtool/config/ltmain.sh $RPM_BUILD_ROOT%{_datadir}/build
152else
153 ln -snf /usr/share/libtool/ltmain.sh $RPM_BUILD_ROOT%{_datadir}/build
154fi
d53f5760 155ln -snf /usr/bin/libtool $RPM_BUILD_ROOT%{_datadir}/build
9e32e98f 156ln -sf build $RPM_BUILD_ROOT%{_datadir}/build-1
8c18c9a9 157
16773349
ER
158sed -i -e 's@^\(APR_SOURCE_DIR=\).*@\1"%{_datadir}"@' \
159 $RPM_BUILD_ROOT%{_bindir}/apr-1-config
160sed -i -e 's@^\(apr_builddir\|apr_builders\)=.*@\1=%{_datadir}/build-1@' \
9e32e98f 161 $RPM_BUILD_ROOT%{_datadir}/build/apr_rules.mk
16773349 162sed -i -e '1s@#!.*python@#!%{__python}@' $RPM_BUILD_ROOT%{_datadir}/build/gen-build.py
f3bf17ad
AM
163
164%clean
165rm -rf $RPM_BUILD_ROOT
166
b4838f76
JB
167%post -p /sbin/ldconfig
168%postun -p /sbin/ldconfig
169
f3bf17ad
AM
170%files
171%defattr(644,root,root,755)
023f96c0 172%doc CHANGES docs/*.html
7a48bef9
JB
173%attr(755,root,root) %{_libdir}/libapr-1.so.*.*.*
174%attr(755,root,root) %ghost %{_libdir}/libapr-1.so.0
f3bf17ad
AM
175
176%files devel
177%defattr(644,root,root,755)
7a48bef9
JB
178%attr(755,root,root) %{_bindir}/apr-1-config
179%attr(755,root,root) %{_libdir}/libapr-1.so
180%{_libdir}/libapr-1.la
f3bf17ad
AM
181%{_libdir}/apr.exp
182%{_includedir}
183%dir %{_datadir}
9e32e98f
JB
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
16773349 191%attr(755,root,root) %{_datadir}/build/gen-build.py
9e32e98f 192%{_datadir}/build-1
af4e4c47 193%{_pkgconfigdir}/apr-1.pc
f3bf17ad
AM
194
195%files static
196%defattr(644,root,root,755)
7a48bef9 197%{_libdir}/libapr-1.a
This page took 0.181969 seconds and 4 git commands to generate.