This commit is contained in:
Mamoru TASAKA 2012-04-09 18:27:08 +09:00
parent 481cf014ea
commit b0329e1b24
3 changed files with 21 additions and 33 deletions

1
.gitignore vendored
View File

@ -4,3 +4,4 @@ nokogiri-1.4.3.1.gem
/nokogiri-1.5.0.beta.3.gem /nokogiri-1.5.0.beta.3.gem
/nokogiri-1.5.0.beta.4.gem /nokogiri-1.5.0.beta.4.gem
/nokogiri-1.5.0.gem /nokogiri-1.5.0.gem
/nokogiri-1.5.2.gem

View File

@ -1,10 +1,10 @@
%global ruby_sitearch %(ruby -rrbconfig -e "puts Config::CONFIG['sitearchdir']") %global ruby_sitearch %(ruby -rrbconfig -e "puts Config::CONFIG['sitearchdir']")
%global rubyabi 1.8 %global rubyabi 1.8
%global mainver 1.5.0 %global mainver 1.5.2
#%%global prever .beta.4 #%%global prever .beta.4
%global mainrel 3 %global mainrel 1
%global prerpmver %(echo "%{?prever}" | sed -e 's|\\.||g') %global prerpmver %(echo "%{?prever}" | sed -e 's|\\.||g')
%global gemdir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null) %global gemdir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null)
@ -38,16 +38,11 @@ URL: http://nokogiri.rubyforge.org/nokogiri/
Source0: http://gems.rubyforge.org/gems/%{gemname}-%{mainver}%{?prever}.gem Source0: http://gems.rubyforge.org/gems/%{gemname}-%{mainver}%{?prever}.gem
# ./test/html/test_element_description.rb:62 fails, as usual...... # ./test/html/test_element_description.rb:62 fails, as usual......
# Patch0: rubygem-nokogiri-1.5.0.beta3-test-failure.patch # Patch0: rubygem-nokogiri-1.5.0.beta3-test-failure.patch
Patch0: rubygem-nokogiri-1.5.0-allow-non-crosscompile.patch #Patch0: rubygem-nokogiri-1.5.0-allow-non-crosscompile.patch
BuildRequires: ruby(abi) = %{rubyabi} BuildRequires: ruby(abi) = %{rubyabi}
BuildRequires: ruby(rubygems) BuildRequires: ruby(rubygems)
## ##
## For %%check ## For %%check
BuildRequires: rubygem(hoe)
# Not available yet
# BuildRequires: rubygem(hoe-debugging)
BuildRequires: rubygem(rake)
BuildRequires: rubygem(rake-compiler)
BuildRequires: rubygem(minitest) BuildRequires: rubygem(minitest)
%if 0%{?ruby19} > 0 %if 0%{?ruby19} > 0
BuildRequires: rubygems-devel BuildRequires: rubygems-devel
@ -111,7 +106,7 @@ gem install \
# patches # patches
pushd .%{geminstdir} pushd .%{geminstdir}
%patch0 -p1 #%%patch0 -p1
popd popd
# Permission # Permission
@ -123,15 +118,6 @@ rm -f .%{geminstdir}/lib/*.jar
rm -rf .%{geminstdir}/ext/java rm -rf .%{geminstdir}/ext/java
%build %build
# cflags wrong (-O3 passed), recompiling
pushd ./%{geminstdir}
sed -i.flags -e 's|-O3||' ext/nokogiri/extconf.rb
find . -name \*.so -or -name \*.o -exec rm -f {} \;
# touch
touch \
lib/nokogiri/css/tokenizer.rb \
lib/nokogiri/css/parser.rb
rake -v compile --trace
%install %install
mkdir -p %{buildroot}%{gemdir} mkdir -p %{buildroot}%{gemdir}
@ -227,13 +213,6 @@ create_symlink_rec %{geminstdir}/lib %{ruby_sitelib}
%check %check
# Ah.... # Ah....
rm -rf TMPBINDIR
mkdir -p TMPBINDIR
pushd TMPBINDIR
ln -sf /bin/true sudo
export PATH=$(pwd):$PATH
popd
# test_exslt(TestXsltTransforms) [./test/test_xslt_transforms.rb:93] # test_exslt(TestXsltTransforms) [./test/test_xslt_transforms.rb:93]
# fails without TZ on sparc # fails without TZ on sparc
export TZ="Asia/Tokyo" export TZ="Asia/Tokyo"
@ -243,16 +222,21 @@ LANG=ja_JP.UTF-8
%endif %endif
pushd ./%{geminstdir} pushd ./%{geminstdir}
# Some files are missing and due to it some tests fail, skil # Some files are missing and due to it some tests fail, skip
for TEST in \ SKIPTEST="test/xml/test_xinclude.rb"
test_document_xhtml_enc for f in $SKIPTEST
do do
grep -l "def $TEST" test/*/*.rb | \ mv $f $f.skip
xargs sed -i.fail -e "/$TEST/a \ # Needed file does not exist\n return\n" done
ruby -I.:lib:test -e \
"require 'minitest/autorun' ; Dir.glob('test/**/test_*.rb'){|f| require f}"
for f in $SKIPTEST
do
mv $f.skip $f
done done
rake test --trace
# rake spec --trace
popd popd
%files %files
@ -296,6 +280,9 @@ popd
%endif %endif
%changelog %changelog
* Mon Apr 9 2012 Mamoru Tasaka <mtasaka@fedoraproject.org> - 1.5.2-1
- 1.5.2
* Tue Apr 03 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 1.5.0-3 * Tue Apr 03 2012 Bohuslav Kabrda <bkabrda@redhat.com> - 1.5.0-3
- Fix conditionals for F17 to work for RHEL 7 as well. - Fix conditionals for F17 to work for RHEL 7 as well.

View File

@ -1 +1 @@
91aef0c0d912554f0abfbd82666a0504 nokogiri-1.5.0.gem 38ce6d3bf4020667de8816bcd3daeacc nokogiri-1.5.2.gem