From f52c365558f3d32bd4ea776522dec3a762a887b4 Mon Sep 17 00:00:00 2001 From: Vít Ondruch Date: Mon, 28 Nov 2011 13:36:14 +0100 Subject: Updated to typhoeus 0.3.3. --- .gitignore | 1 + rubygem-typhoeus-gcc-flags-fix.patch | 31 +++++++++++++ rubygem-typhoeus.spec | 84 ++++++++++-------------------------- sources | 4 +- 4 files changed, 56 insertions(+), 64 deletions(-) create mode 100644 rubygem-typhoeus-gcc-flags-fix.patch diff --git a/.gitignore b/.gitignore index f160975..e4888a5 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ /typhoeus-0.1.31.gem /rubygem-typhoeus-gcc-flags-fix.patch /typhoeus-0.2.0.gem +/typhoeus-0.3.3.gem diff --git a/rubygem-typhoeus-gcc-flags-fix.patch b/rubygem-typhoeus-gcc-flags-fix.patch new file mode 100644 index 0000000..4f56370 --- /dev/null +++ b/rubygem-typhoeus-gcc-flags-fix.patch @@ -0,0 +1,31 @@ +*** ext/typhoeus/extconf.rb 2010-10-04 13:39:02.983245045 +0200 +--- ext/typhoeus/extconf.rb.new 2010-10-13 15:07:43.289099195 +0200 +*************** +*** 25,31 **** + use_macports = !(defined?(RUBY_ENGINE) && RUBY_ENGINE != 'ruby') + $LIBPATH << "/opt/local/lib" if use_macports + +! $CFLAGS << " -O3 -Wall -Wcast-qual -Wwrite-strings -Wconversion -Wmissing-noreturn -Winline" + + if Config::CONFIG['target_os'] == 'mingw32' + header = File.join(ROOT, 'cross', 'curl-7.19.4.win32', 'include') +--- 25,31 ---- + use_macports = !(defined?(RUBY_ENGINE) && RUBY_ENGINE != 'ruby') + $LIBPATH << "/opt/local/lib" if use_macports + +! $CFLAGS << " -Wall -Wcast-qual -Wwrite-strings -Wconversion -Wmissing-noreturn -Winline" + + if Config::CONFIG['target_os'] == 'mingw32' + header = File.join(ROOT, 'cross', 'curl-7.19.4.win32', 'include') +*************** +*** 62,65 **** + ) + end + +! create_makefile("typhoeus/native") +\ No newline at end of file +--- 62,65 ---- + ) + end + +! create_makefile("typhoeus/native") diff --git a/rubygem-typhoeus.spec b/rubygem-typhoeus.spec index 55da661..bd6549b 100644 --- a/rubygem-typhoeus.spec +++ b/rubygem-typhoeus.spec @@ -1,28 +1,28 @@ +%global gemname typhoeus + %global ruby_sitearch %(ruby -rrbconfig -e 'puts Config::CONFIG["sitearchdir"] ') %global gemdir %(ruby -rubygems -e 'puts Gem::dir' 2>/dev/null) -%global gemname typhoeus %global geminstdir %{gemdir}/gems/%{gemname}-%{version} %global rubyabi 1.8 Summary: A library for interacting with web services at blinding speed Name: rubygem-%{gemname} -Version: 0.2.0 -Release: 2%{?dist} +Version: 0.3.3 +Release: 1%{?dist} Group: Development/Languages License: MIT URL: http://github.com/pauldix/typhoeus Source0: http://gems.rubyforge.org/gems/%{gemname}-%{version}.gem -Patch0: %{name}-gcc-flags-fix.patch -Requires: rubygems +Requires: ruby(rubygems) Requires: ruby(abi) = %{rubyabi} -Requires: rubygem(rack) +Requires: rubygem(mime-types) BuildRequires: ruby(abi) = %{rubyabi} -BuildRequires: rubygems -BuildRequires: rubygem(rspec) -BuildRequires: rubygem(rake) -BuildRequires: rubygem(rack) -BuildRequires: rubygem(diff-lcs) +BuildRequires: ruby(rubygems) +# Use rspec-core until rspec are not migrated to RSpec 2.x +BuildRequires: rubygem(rspec-core) BuildRequires: rubygem(json) +BuildRequires: rubygem(mime-types) +BuildRequires: rubygem(sinatra) BuildRequires: ruby-devel BuildRequires: libcurl-devel Provides: rubygem(%{gemname}) = %{version} @@ -49,23 +49,16 @@ gem install \ --install-dir ./%{gemdir} \ -V --force --rdoc \ %{SOURCE0} -pushd .%{geminstdir} -%patch0 -popd %build -pushd .%{geminstdir}/ext/%{gemname} -(%_bindir/ruby extconf.rb && make clean all) -popd %install rm -rf %{buildroot} mkdir -p %{buildroot}%{gemdir} cp -a ./%{gemdir}/* %{buildroot}%{gemdir} + mkdir -p %{buildroot}%{ruby_sitearch}/%{gemname} -mv -f %{buildroot}%{geminstdir}/ext/%{gemname}/*.so %{buildroot}%{ruby_sitearch}/%{gemname} -rm -rf %{buildroot}%{geminstdir}/ext -find %{buildroot}/%{geminstdir} -name .gitignore | xargs rm -f +mv -f %{buildroot}%{geminstdir}/lib/%{gemname}/*.so %{buildroot}%{ruby_sitearch}/%{gemname} # remove all shebang, set permission to 0644 (mtasaka) for f in $(find %{buildroot}%{geminstdir} -name \*.rb) @@ -76,64 +69,33 @@ done %check pushd .%{geminstdir} -ln -sf %{buildroot}%{ruby_sitearch}/%{gemname}/native.so lib/%{gemname}/native.so - -NEEDSKIP="" -for needskip in \ - spec/%{gemname}/request_spec.rb \ - spec/%{gemname}/hydra_spec.rb \ - spec/%{gemname}/remote_spec.rb \ - spec/%{gemname}/multi_spec.rb \ - spec/%{gemname}/easy_spec.rb \ - spec/%{gemname}/remote_proxy_object_spec.rb -do - NEEDSKIP="$NEEDSKIP $needskip" -done - -for needskip in $NEEDSKIP -do - mv $needskip ${needskip}.save -done - -rake spec --trace - -for needskip in $NEEDSKIP -do - mv ${needskip}.save $needskip -done - -rm -f lib/%{gemname}/native.so - +rspec spec popd -%clean -rm -rf %{buildroot} - %files -%defattr(-, root, root, -) %dir %{geminstdir} %dir %{ruby_sitearch}/%{gemname} +%exclude %{geminstdir}/ext %{geminstdir}/lib +%exclude %{geminstdir}/lib/typhoeus/.gitignore %{ruby_sitearch}/%{gemname}/*.so -%doc %{geminstdir}/VERSION -%doc %{geminstdir}/README.textile -%doc %{geminstdir}/CHANGELOG.markdown -%{gemdir}/cache/%{gemname}-%{version}.gem +%doc %{geminstdir}/LICENSE +%exclude %{gemdir}/cache/%{gemname}-%{version}.gem %{gemdir}/specifications/%{gemname}-%{version}.gemspec %files doc -%defattr(-, root, root, -) +%doc %{geminstdir}/CHANGELOG.markdown %{geminstdir}/Rakefile %{geminstdir}/Gemfile %{geminstdir}/Gemfile.lock %{geminstdir}/spec -%{geminstdir}/benchmarks -%{geminstdir}/examples -%{geminstdir}/profilers %{geminstdir}/%{gemname}.gemspec -%{gemdir}/doc/%{gemname}-%{version} +%doc %{gemdir}/doc/%{gemname}-%{version} %changelog +* Mon Nov 28 2011 Vít Ondruch - 0.3.3-1 +- Updated to typhoeus 0.3.3. + * Wed Feb 09 2011 Fedora Release Engineering - 0.2.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild diff --git a/sources b/sources index c52730c..94500b1 100644 --- a/sources +++ b/sources @@ -1,3 +1 @@ -f99f3c63d11d6779306b157ab9db3e1d typhoeus-0.1.31.gem -b5d51183aeb4b9b20f28542d37d9f148 rubygem-typhoeus-gcc-flags-fix.patch -b4b8c00393d153caf00698f3090d4044 typhoeus-0.2.0.gem +d944f1c8fcc348e47cecbb0dc6ab3fb1 typhoeus-0.3.3.gem -- cgit