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