Index: trunk/tools/ts-specs/base-specs/pcre.spec |
— | — | @@ -0,0 +1,63 @@ |
| 2 | +Name: TSpcre |
| 3 | +Version: 7.7 |
| 4 | +Source: %{sf_download}/pcre/pcre-%{version}.tar.gz |
| 5 | +Patch1: pcre-01-cve-2008-2371 |
| 6 | + |
| 7 | +%prep |
| 8 | +%setup -q -n %{src_name}-%{version} |
| 9 | +export CC=cc |
| 10 | +export CXX=CC |
| 11 | +export CFLAGS="%optflags" |
| 12 | +export CXXFLAGS="%cxx_optflags" |
| 13 | +export LDFLAGS="%_ldflags" |
| 14 | + |
| 15 | +./configure --prefix=%{_prefix} --libdir=%{_libdir} --bindir=%{_bindir} |
| 16 | + |
| 17 | +%patch1 -p0 |
| 18 | + |
| 19 | +%build |
| 20 | +CPUS=`/usr/sbin/psrinfo | grep on-line | wc -l | tr -d ' '` |
| 21 | +if test "x$CPUS" = "x" -o $CPUS = 0; then |
| 22 | + CPUS=1 |
| 23 | +fi |
| 24 | + |
| 25 | +gmake -j$CPUS |
| 26 | + |
| 27 | +%install |
| 28 | +gmake install DESTDIR=$RPM_BUILD_ROOT |
| 29 | +rm $RPM_BUILD_ROOT%{_libdir}/*.a |
| 30 | +rm $RPM_BUILD_ROOT%{_libdir}/*.la |
| 31 | + |
| 32 | +%clean |
| 33 | +rm -rf $RPM_BUILD_ROOT |
| 34 | + |
| 35 | +#%files |
| 36 | +#%defattr(-,root,bin) |
| 37 | +#%dir %attr (0755, root, bin) %{_libdir} |
| 38 | +#%{_libdir}/*.so.* |
| 39 | + |
| 40 | +#%files devel |
| 41 | +#%defattr(-,root,bin) |
| 42 | +#%dir %attr (0755, root, sys) %{_datadir} |
| 43 | +#%{_datadir}/man |
| 44 | +#%dir %attr (0755, root, other) %{_datadir}/doc |
| 45 | +#%{_datadir}/doc/* |
| 46 | + |
| 47 | +#%dir %attr (0755, root, bin) %{_includedir} |
| 48 | +#%{_includedir}/* |
| 49 | +#%dir %attr (0755, root, other) %{_libdir}/pkgconfig |
| 50 | +#%{_libdir}/pkgconfig/* |
| 51 | +#%dir %attr (0755, root, bin) %{_libdir} |
| 52 | +#%{_libdir}/*.so |
| 53 | +#%dir %attr (0755, root, bin) %{_bindir} |
| 54 | +#%{_bindir}/* |
| 55 | + |
| 56 | +#%changelog |
| 57 | +#* Sun Jul 6 2008 - river@wikimedia.org |
| 58 | +#- modified for toolserver |
| 59 | +#* Fri Jan 11 2008 - moinak.ghosh@sun.com |
| 60 | +#- Add conflict with SUNWpcre, remove -i386 from package name |
| 61 | +#* Mon Oct 29 2007 - brian.cameron@sun.com |
| 62 | +#- Bump to 7.4 and fix Source URL. |
| 63 | +#* 2007.Aug.11 - <shivakumar dot gn at gmail dot com> |
| 64 | +##- Initial spec. |
Index: trunk/tools/ts-specs/patches/pcre-01-cve-2008-2371 |
— | — | @@ -0,0 +1,11 @@ |
| 2 | +--- pcre_compile.c.old Sun Jul 6 14:43:28 2008 |
| 3 | +@@ -4931,7 +4931,7 @@ |
| 4 | + (lengthptr == NULL || *lengthptr == 2 + 2*LINK_SIZE)) |
| 5 | + { |
| 6 | + cd->external_options = newoptions; |
| 7 | +- options = newoptions; |
| 8 | ++ options = *optionsptr = newoptions; |
| 9 | + } |
| 10 | + else |
| 11 | + { |
Index: trunk/tools/ts-specs/TSpcre.spec |
— | — | @@ -0,0 +1,105 @@ |
| 2 | +%include Solaris.inc |
| 3 | + |
| 4 | +%ifarch amd64 sparcv9 |
| 5 | +%include arch64.inc |
| 6 | +%use pcre_64 = pcre.spec |
| 7 | +%endif |
| 8 | + |
| 9 | +%include base.inc |
| 10 | +%use pcre = pcre.spec |
| 11 | + |
| 12 | +%define src_name pcre |
| 13 | +%define src_version 7.7 |
| 14 | +%define pkg_release 1 |
| 15 | + |
| 16 | +SUNW_BaseDir: %{_basedir} |
| 17 | + |
| 18 | +Name: TS%{src_name} |
| 19 | +Summary: PCRE - Perl Compatible Regular Expressions |
| 20 | +Version: %{src_version} |
| 21 | +Release: %{pkg_release} |
| 22 | +License: BSD |
| 23 | +Source: %{sf_download}/pcre/%{src_name}-%{version}.tar.gz |
| 24 | +Patch1: pcre-01-cve-2008-2371 |
| 25 | +BuildRoot: %{_tmppath}/%{src_name}-%{version}-build |
| 26 | +Conflicts: SUNWpcre |
| 27 | +%include default-depend.inc |
| 28 | + |
| 29 | +%package devel |
| 30 | +Summary: %{summary} - development files |
| 31 | +SUNW_BaseDir: %{_basedir} |
| 32 | +%include default-depend.inc |
| 33 | +Requires: %name |
| 34 | + |
| 35 | +%prep |
| 36 | +rm -rf %name-%version |
| 37 | +mkdir %name-%version |
| 38 | + |
| 39 | +%ifarch amd64 sparcv9 |
| 40 | +mkdir %name-%version/%_arch64 |
| 41 | +%pcre_64.prep -d %name-%version/%_arch64 |
| 42 | +%endif |
| 43 | + |
| 44 | +mkdir %name-%version/%base_arch |
| 45 | +%pcre.prep -d %name-%version/%base_arch |
| 46 | + |
| 47 | +%build |
| 48 | +%ifarch amd64 sparcv9 |
| 49 | +%pcre_64.build -d %name-%version/%_arch64 |
| 50 | +%endif |
| 51 | + |
| 52 | +%pcre.build -d %name-%version/%base_arch |
| 53 | + |
| 54 | +%install |
| 55 | +rm -rf $RPM_BUILD_ROOT |
| 56 | + |
| 57 | +%ifarch amd64 sparcv9 |
| 58 | +%pcre_64.install -d %name-%version/%_arch64 |
| 59 | +%endif |
| 60 | + |
| 61 | +%pcre.install -d %name-%version/%base_arch |
| 62 | + |
| 63 | +%clean |
| 64 | +rm -rf $RPM_BUILD_ROOT |
| 65 | + |
| 66 | +%files |
| 67 | +%defattr(-,root,bin) |
| 68 | +%dir %attr (0755, root, bin) %{_libdir} |
| 69 | +%{_libdir}/*.so.* |
| 70 | +%ifarch amd64 sparcv9 |
| 71 | +%dir %attr (0755, root, bin) %{_libdir}/%_arch64 |
| 72 | +%{_libdir}/%_arch64/*.so.* |
| 73 | +%endif |
| 74 | + |
| 75 | +%files devel |
| 76 | +%defattr(-,root,bin) |
| 77 | +%dir %attr (0755, root, sys) %{_datadir} |
| 78 | +%{_datadir}/man |
| 79 | +%dir %attr (0755, root, other) %{_datadir}/doc |
| 80 | +%{_datadir}/doc/* |
| 81 | + |
| 82 | +%dir %attr (0755, root, bin) %{_includedir} |
| 83 | +%{_includedir}/* |
| 84 | +%dir %attr (0755, root, other) %{_libdir}/pkgconfig |
| 85 | +%{_libdir}/pkgconfig/* |
| 86 | +%dir %attr (0755, root, bin) %{_libdir} |
| 87 | +%{_libdir}/*.so |
| 88 | +%ifarch amd64 sparcv9 |
| 89 | +%dir %attr (0755, root, bin) %{_libdir}/%{_arch64} |
| 90 | +%{_libdir}/%{_arch64}/*.so |
| 91 | +%dir %attr (0755, root, other) %{_libdir}/%_arch64/pkgconfig |
| 92 | +%{_libdir}/%_arch64/pkgconfig/* |
| 93 | +%endif |
| 94 | + |
| 95 | +%dir %attr (0755, root, bin) %{_bindir} |
| 96 | +%{_bindir}/* |
| 97 | + |
| 98 | +%changelog |
| 99 | +* Sun Jul 6 2008 - river@wikimedia.org |
| 100 | +- modified for toolserver |
| 101 | +* Fri Jan 11 2008 - moinak.ghosh@sun.com |
| 102 | +- Add conflict with SUNWpcre, remove -i386 from package name |
| 103 | +* Mon Oct 29 2007 - brian.cameron@sun.com |
| 104 | +- Bump to 7.4 and fix Source URL. |
| 105 | +* 2007.Aug.11 - <shivakumar dot gn at gmail dot com> |
| 106 | +- Initial spec. |