/[packages]/cauldron/pcre/current/SPECS/pcre.spec
ViewVC logotype

Annotation of /cauldron/pcre/current/SPECS/pcre.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 594784 - (hide annotations) (download)
Wed Feb 19 14:09:32 2014 UTC (6 years, 4 months ago) by oden
File size: 7719 byte(s)
- added the stack guard function (upstream) which enables mariadb-10.x to use it

1 luigiwalser 303179 %define pcre_major 1
2     %define pcrecpp_major 0
3 blino 581 %define pcreposix_major 1
4 luigiwalser 309694 %define pcreposix_compat_major 0
5 blino 581 %define libname_orig lib%{name}
6 neoclust 335530 %define libname16_orig lib%{name}16
7     %define libname32_orig lib%{name}32
8 luigiwalser 303179 %define libname %mklibname pcre %{pcre_major}
9 fwang 335603 %define libname16 %mklibname pcre 16 %{pcrecpp_major}
10     %define libname32 %mklibname pcre 32 %{pcrecpp_major}
11 luigiwalser 309694 %define libnamecpp %mklibname pcrecpp %{pcrecpp_major}
12     %define libnameposix %mklibname pcreposix %{pcreposix_major}
13     %define libnameposix_compat %mklibname pcreposix %{pcreposix_compat_major}
14 blino 581 %define develname %mklibname -d pcre
15 fwang 323606 %define develcpp %mklibname -d pcrecpp
16 fwang 323586 %define develposix %mklibname -d pcreposix
17 blino 581
18     %define build_pcreposix_compat 1
19    
20     Summary: Perl-compatible regular expression library
21     Name: pcre
22 fwang 584398 Version: 8.34
23 oden 594784 Release: %mkrel 2
24 blino 581 License: BSD-Style
25     Group: File tools
26     URL: http://www.pcre.org/
27 fwang 187740 Source0: http://downloads.sourceforge.net/pcre/%{name}-%{version}.tar.bz2
28     Source1: http://downloads.sourceforge.net/pcre/%{name}-%{version}.tar.bz2.sig
29 blino 581 Requires: %{libname} = %{version}-%{release}
30     BuildRequires: automake
31 oden 594784 Patch0: pcre-0.6.5-fix-detect-into-kdelibs.patch
32     Patch1: pcre-linkage_fix.diff
33     Patch2: pcre-8.34-stack_guard.diff
34 blino 581 # from debian:
35     Patch4: pcre-pcreposix-glibc-conflict.patch
36    
37     %description
38     PCRE has its own native API, but a set of "wrapper" functions that are based on
39     the POSIX API are also supplied in the library libpcreposix. Note that this
40     just provides a POSIX calling interface to PCRE: the regular expressions
41     themselves still follow Perl syntax and semantics.
42     This package contains a grep variant based on the PCRE library.
43    
44     %package -n %{libname}
45     Group: System/Libraries
46     Summary: Perl-compatible regular expression library
47 colin 273158 Requires(pre): filesystem >= 2.1.9-18
48 blino 581 Provides: %{libname_orig} = %{version}-%{release}
49    
50     %description -n %{libname}
51 luigiwalser 309694 This package contains the shared library libpcre.
52 blino 581
53 neoclust 335530 %package -n %{libname16}
54     Group: System/Libraries
55     Summary: Perl-compatible regular expression library
56     Requires(pre): filesystem >= 2.1.9-18
57     Provides: %{libname16_orig} = %{version}-%{release}
58 fwang 335603 Obsoletes: %{_lib}pcre16_1 < %{version}-%{release}
59 luigiwalser 309694
60 neoclust 335530 %description -n %{libname16}
61     This package contains the shared library libpcre.
62    
63     %package -n %{libname32}
64     Group: System/Libraries
65     Summary: Perl-compatible regular expression library
66     Requires(pre): filesystem >= 2.1.9-18
67     Provides: %{libname32_orig} = %{version}-%{release}
68 fwang 335603 Obsoletes: %{_lib}pcre32_1 < %{version}-%{release}
69 neoclust 335530
70     %description -n %{libname32}
71     This package contains the shared library libpcre.
72    
73 luigiwalser 309694 %package -n %{libnamecpp}
74     Group: System/Libraries
75     Summary: Perl-compatible regular expression library
76     Conflicts: %{_lib}pcre0 < 8.21-3
77    
78     %description -n %{libnamecpp}
79     This package contains the shared library libpcrecpp.
80    
81    
82     %package -n %{libnameposix}
83     Group: System/Libraries
84     Summary: Perl-compatible regular expression library
85     Conflicts: %{_lib}pcre0 < 8.21-3
86    
87     %description -n %{libnameposix}
88     This package contains the shared library libpcreposix.
89    
90    
91     %package -n %{libnameposix_compat}
92     Group: System/Libraries
93     Summary: Perl-compatible regular expression library
94     Conflicts: %{_lib}pcre0 < 8.21-3
95    
96     %description -n %{libnameposix_compat}
97     This package contains the shared library libpcreposix compat.
98    
99    
100 blino 581 %package -n %{develname}
101     Group: Development/C
102     Summary: Headers and static lib for pcre development
103     Requires: %{libname} = %{version}-%{release}
104 neoclust 335530 Requires: %{libname16} = %{version}-%{release}
105     Requires: %{libname32} = %{version}-%{release}
106 blino 581 Provides: %{libname_orig}-devel = %{version}-%{release}
107     Provides: %{name}-devel = %{version}-%{release}
108     Obsoletes: %mklibname pcre 0 -d
109    
110     %description -n %{develname}
111     Install this package if you want do compile applications using the pcre
112     library.
113    
114 fwang 323606 %package -n %{develcpp}
115     Group: Development/C++
116     Summary: Headers and static lib for pcrecpp development
117     Provides: pcrecpp-devel = %{version}-%{release}
118     Requires: %{libnamecpp} = %{version}-%{release}
119     Requires: %{develname} = %{version}-%{release}
120     Conflicts: pcre-devel < 8.32-4
121    
122     %description -n %{develcpp}
123     Install this package if you want do compile applications using the pcrecpp
124     library.
125    
126 fwang 323586 %package -n %{develposix}
127     Group: Development/C
128     Summary: Headers and static lib for pcreposix development
129     Provides: pcreposix-devel = %{version}-%{release}
130     Requires: %{libnameposix} = %{version}-%{release}
131     Requires: %{develname} = %{version}-%{release}
132 fwang 323606 Conflicts: pcre-devel < 8.32-4
133 fwang 323586
134     %description -n %{develposix}
135     Install this package if you want do compile applications using the pcre
136     library.
137    
138 luigiwalser 309694 The header file for the POSIX-style functions is called pcreposix.h. The
139     official POSIX name is regex.h, but I didn't want to risk possible problems
140     with existing files of that name by distributing it that way. To use it with an
141     existing program that uses the POSIX API, it will have to be renamed or pointed
142     at by a link.
143    
144 blino 581 %prep
145     %setup -q
146 oden 594784 %patch0 -p1 -b .detect_into_kdelibs
147     %patch1 -p0
148     %patch2 -p1
149 blino 581
150     %if %{build_pcreposix_compat}
151     # pcre-pcreposix-glibc-conflict patch below breaks compatibility,
152     # create a libpcreposix.so.0 without the patch
153     cp -a . ../pcre-with-pcreposix_compat && mv ../pcre-with-pcreposix_compat .
154     %endif
155     %patch4 -p1 -b .symbol-conflict
156    
157     %build
158     %if %{build_pcreposix_compat}
159     dirs="pcre-with-pcreposix_compat ."
160     %else
161     dirs="."
162     %endif
163     for i in $dirs; do
164     cd $i
165     mkdir -p m4
166 fwang 134303 autoreconf -fi
167 luigiwalser 309694 %configure2_5x \
168     --disable-static \
169 fwang 323576 --enable-utf \
170 luigiwalser 309694 --enable-unicode-properties \
171 neoclust 335530 --enable-pcre8 \
172     --enable-pcre16 \
173     --enable-pcre32 \
174 luigiwalser 309694 --enable-jit
175 blino 581 %make
176     cd -
177     done
178    
179     %check
180     export LC_ALL=C
181     # Tests, patch out actual pcre_study_size in expected results
182     #echo 'int main() { printf("%d", sizeof(pcre_study_data)); return 0; }' | \
183     #%{__cc} -xc - -include "pcre_internal.h" -I. -o study_size
184     #STUDY_SIZE=`./study_size`
185     #perl -pi -e "s,(Study size\s+=\s+)\d+,\${1}$STUDY_SIZE," testdata/testoutput*
186     make check
187    
188     %install
189     %if %{build_pcreposix_compat}
190     %makeinstall_std -C pcre-with-pcreposix_compat
191     %endif
192     %makeinstall_std
193    
194 fwang 170356 %multiarch_binaries %{buildroot}%{_bindir}/pcre-config
195 blino 581
196     # Remove unwanted files
197 luigiwalser 309694 rm -f %{buildroot}%{_docdir}/pcre/{AUTHORS,ChangeLog,COPYING,LICENCE,NEWS}
198     rm -f %{buildroot}%{_docdir}/pcre/{pcre-config.txt,pcre.txt,pcregrep.txt}
199     rm -f %{buildroot}%{_docdir}/pcre/{pcretest.txt,README}
200     rm -rf %{buildroot}%{_docdir}/pcre/html
201     rm -f %{buildroot}%{_libdir}/*.la
202 blino 581
203     %files
204 luigiwalser 309694 %doc AUTHORS COPYING LICENCE NEWS README
205 luigiwalser 303179 %{_mandir}/man1/pcregrep.1*
206     %{_mandir}/man1/pcretest.1*
207     %{_bindir}/pcregrep
208 fwang 323949 %{_bindir}/pcretest
209 blino 581
210     %files -n %{libname}
211 luigiwalser 303179 %{_libdir}/libpcre.so.%{pcre_major}*
212 luigiwalser 309694
213 neoclust 335530 %files -n %{libname16}
214     %{_libdir}/libpcre16.so.%{pcrecpp_major}*
215    
216     %files -n %{libname32}
217     %{_libdir}/libpcre32.so.%{pcrecpp_major}*
218    
219 luigiwalser 309694 %files -n %{libnamecpp}
220 luigiwalser 303179 %{_libdir}/libpcrecpp.so.%{pcrecpp_major}*
221 luigiwalser 309694
222 luigiwalser 303179 %if %{build_pcreposix_compat}
223 luigiwalser 309694 %files -n %{libnameposix_compat}
224     %{_libdir}/libpcreposix.so.%{pcreposix_compat_major}*
225 luigiwalser 303179 %endif
226 luigiwalser 309694
227     %files -n %{libnameposix}
228 luigiwalser 303179 %{_libdir}/libpcreposix.so.%{pcreposix_major}*
229 blino 581
230     %files -n %{develname}
231     %doc doc/html
232     %doc ChangeLog
233 fwang 323606 %{_libdir}/libpcre.so
234 neoclust 335530 %{_libdir}/libpcre16.so
235     %{_libdir}/libpcre32.so
236 fwang 323606 %{_includedir}/pcre.h
237     %{_includedir}/pcre_*.h
238 luigiwalser 303179 %{_libdir}/pkgconfig/libpcre.pc
239 neoclust 335530 %{_libdir}/pkgconfig/libpcre16.pc
240     %{_libdir}/pkgconfig/libpcre32.pc
241 luigiwalser 303179 %{_bindir}/pcre-config
242 blino 581 %multiarch %{multiarch_bindir}/pcre-config
243 luigiwalser 303179 %{_mandir}/man1/pcre-config.1*
244     %{_mandir}/man3/*.3*
245 fwang 323586 %exclude %{_libdir}/libpcreposix.so
246     %exclude %{_mandir}/man3/pcreposix.3*
247    
248 fwang 323606 %files -n %{develcpp}
249     %{_includedir}/pcrecpp*.h
250     %{_libdir}/libpcrecpp.so
251     %{_libdir}/pkgconfig/libpcrecpp.pc
252     %{_mandir}/man3/pcrecpp.3*
253    
254 fwang 323586 %files -n %{develposix}
255 fwang 323606 %{_includedir}/pcreposix.h
256 fwang 323586 %{_libdir}/libpcreposix.so
257     %{_libdir}/pkgconfig/libpcreposix.pc
258     %{_mandir}/man3/pcreposix.3*

  ViewVC Help
Powered by ViewVC 1.1.28