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