Update to 1.8.7 p352

CVE-2011-2686 is fixed in this version (bug 722415)
Update ext/tk to the latest git
Remove duplicate path entry (bug 718695)
This commit is contained in:
Mamoru Tasaka 2011-07-16 10:31:19 +09:00
parent 13bbaded90
commit ace4eca586
4 changed files with 75 additions and 4 deletions

2
.gitignore vendored
View File

@ -5,3 +5,5 @@ ruby-rev415a3ef9ab82c65a7abc-ext_tk.tar.gz
/ruby-1.8.7-p330.tar.bz2
/ruby-revf30eca26639ce538339bc488c7ed1fd397b0c13f-ext_tk.tar.gz
/ruby-1.8.7-p334.tar.bz2
/ruby-1.8.7-p352.tar.bz2
/ruby-revc2dfaa7d40531aef3706bcc16f38178b0c6633ee-ext_tk.tar.gz

View File

@ -0,0 +1,54 @@
--- ruby-1.8.7-p352/array.c.pathuniq 2009-02-05 08:55:33.000000000 +0900
+++ ruby-1.8.7-p352/array.c 2011-07-16 09:44:35.000000000 +0900
@@ -2954,7 +2954,7 @@
* b.uniq! #=> nil
*/
-static VALUE
+GCC_VISIBILITY_HIDDEN VALUE
rb_ary_uniq_bang(ary)
VALUE ary;
{
@@ -2987,7 +2987,7 @@
* a.uniq #=> ["a", "b", "c"]
*/
-static VALUE
+GCC_VISIBILITY_HIDDEN VALUE
rb_ary_uniq(ary)
VALUE ary;
{
--- ruby-1.8.7-p352/intern.h.pathuniq 2011-05-23 13:49:40.000000000 +0900
+++ ruby-1.8.7-p352/intern.h 2011-07-16 09:43:10.000000000 +0900
@@ -18,6 +18,11 @@
*/
#define ID_ALLOCATOR 1
+#ifdef __GNUC__
+#define GCC_VISIBILITY_HIDDEN __attribute__ ((visibility("hidden")))
+#else
+#define GCC_VISIBILITY_HIDDEN
+#endif
/* array.c */
void rb_mem_clear _((register VALUE*, register long));
@@ -44,6 +49,8 @@
VALUE rb_ary_reverse _((VALUE));
VALUE rb_ary_sort _((VALUE));
VALUE rb_ary_sort_bang _((VALUE));
+GCC_VISIBILITY_HIDDEN VALUE rb_ary_uniq _((VALUE));
+GCC_VISIBILITY_HIDDEN VALUE rb_ary_uniq_bang _((VALUE));
VALUE rb_ary_delete _((VALUE, VALUE));
VALUE rb_ary_delete_at _((VALUE, long));
VALUE rb_ary_clear _((VALUE));
--- ruby-1.8.7-p352/ruby.c.pathuniq 2011-07-16 08:54:11.000000000 +0900
+++ ruby-1.8.7-p352/ruby.c 2011-07-16 09:36:13.000000000 +0900
@@ -341,6 +341,8 @@
if (rb_safe_level() == 0) {
incpush(".");
}
+
+ rb_load_path = rb_ary_uniq(rb_load_path);
}
struct req_list {

View File

@ -1,6 +1,6 @@
%global rubyxver 1.8
%global rubyver 1.8.7
%global _patchlevel 334
%global _patchlevel 352
%global dotpatchlevel %{?_patchlevel:.%{_patchlevel}}
%global patchlevel %{?_patchlevel:-p%{_patchlevel}}
@ -12,12 +12,12 @@
%{!?sitearchbase: %global sitearchbase %{vendorarchbase}/site_ruby}
%global _normalized_cpu %(echo %{_target_cpu} | sed 's/^ppc/powerpc/;s/i.86/i386/;s/sparcv./sparc/;s/armv.*/arm/')
# Sun Dec 25 17:00:00 2010 +0000
%global ruby_tk_git_revision f30eca26639ce538339bc488c7ed1fd397b0c13f
# Fri Jul 15 21:28:10 2011 +0000
%global ruby_tk_git_revision c2dfaa7d40531aef3706bcc16f38178b0c6633ee
Name: ruby
Version: %{rubyver}%{?dotpatchlevel}
Release: 4%{?dist}
Release: 1%{?dist}
# Please check if ruby upstream changes this to "Ruby or GPLv2+"
License: Ruby or GPLv2
URL: http://www.ruby-lang.org/
@ -58,6 +58,9 @@ Patch29: ruby-1.8.7-always-use-i386.patch
# Use shared libs as opposed to static for mkmf
# See bug 428384
Patch33: ruby-1.8.7-p249-mkmf-use-shared.patch
# Remove duplicate path entry
# bug 718695
Patch34: ruby-1.8.7-p352-path-uniq.patch
# Change ruby load path to conform to Fedora/ruby
# library placement (various 1.8.6 patches consolidated into this)
Patch100: ruby-1.8.7-lib-paths.patch
@ -178,6 +181,7 @@ pushd %{name}-%{arcver}
%patch23 -p1
%patch29 -p1
%patch33 -p1
%patch34 -p1
%patch100 -p1
(
@ -185,6 +189,9 @@ pushd %{name}-%{arcver}
rm -rf tk
cp -a ../../ext/tk tk
find tk -type d -name \.svn | sort -r | xargs rm -rf
# Remove rpath
sed -i.rpath -e 's|-Wl,-R|-L|g' tk/extconf.rb
)
popd
@ -530,6 +537,12 @@ rm -rf $RPM_BUILD_ROOT
%{_datadir}/ri
%changelog
* Sat Jul 16 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 1.8.7.352-1
- Update to 1.8.7 p352
- CVE-2011-2686 is fixed in this version (bug 722415)
- Update ext/tk to the latest git
- Remove duplicate path entry (bug 718695)
* Thu Jul 14 2011 Mamoru Tasaka <mtasaka@fedoraproject.org> - 1.8.7.334-4
- Once fix FTBFS (bug 716021)

View File

@ -1,2 +1,4 @@
fcc35655da3047f64650a526c179ade8 ruby-revf30eca26639ce538339bc488c7ed1fd397b0c13f-ext_tk.tar.gz
2f14f604bf981bb938ab5fc8b09eb1a6 ruby-1.8.7-p334.tar.bz2
0c61ea41d1b1183b219b9afe97f18f52 ruby-1.8.7-p352.tar.bz2
01b1053cf357459349bf74363756ad41 ruby-revc2dfaa7d40531aef3706bcc16f38178b0c6633ee-ext_tk.tar.gz