Patch for ARM which doesn't use signed chars as a default

f38
Vít Ondruch 12 years ago
parent 64df6cdde0
commit 115cc23665

@ -5,11 +5,14 @@
Summary: Textile parser for Ruby
Name: rubygem-%{gem_name}
Version: 4.2.9
Release: 4%{?dist}
Release: 5%{?dist}
Group: Development/Languages
License: MIT
URL: http://redcloth.org
Source0: http://gems.rubyforge.org/gems/%{gem_name}-%{version}.gem
# Fixes failing tests on ARM which defaults to use unsigned char
# http://jgarber.lighthouseapp.com/projects/13054-redcloth/tickets/236-test-failure-on-armelpowerpc
Patch0: rubygem-redcloth-4.2.9-unsigned-char-fix.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
Requires: ruby(release)
Requires: ruby(rubygems)
@ -23,11 +26,18 @@ Provides: rubygem(%{gem_name}) = %{version}
%description
Textile parser for Ruby.
%prep
%setup -q -c -T
gem unpack %{SOURCE0}
%setup -q -D -T -n %{gem_name}-%{version}
gem spec %{SOURCE0} -l --ruby > %{gem_name}.gemspec
%patch0 -p1
%build
gem build %{gem_name}.gemspec
%gem_install -n %{SOURCE0}
%gem_install
# To create debuginfo file corretly (workaround for
# "#line" directive)
@ -36,9 +46,6 @@ mkdir ext
ln -sf .. ext/redcloth_scan
popd
%build
%install
mkdir -p %{buildroot}%{gem_dir}
cp -a ./%{gem_dir}/* %{buildroot}%{gem_dir}/
@ -83,6 +90,9 @@ popd
%changelog
* Wed Apr 10 2013 Josef Stribny <jstribny@redhat.com> - 4.2.9-5
- Patch for ARM which doesn't use signed chars as a default
* Thu Mar 07 2013 Josef Stribny <jstribny@redhat.com> - 4.2.9-4
- Rebuild for https://fedoraproject.org/wiki/Features/Ruby_2.0.0

@ -0,0 +1,12 @@
diff --git a/ext/redcloth_scan/extconf.rb b/ext/redcloth_scan/extconf.rb
index 506d4a3..edd46c4 100644
--- a/ext/redcloth_scan/extconf.rb
+++ b/ext/redcloth_scan/extconf.rb
@@ -1,6 +1,6 @@
require 'mkmf'
CONFIG['warnflags'].gsub!(/-Wshorten-64-to-32/, '') if CONFIG['warnflags']
-$CFLAGS << ' -O0 -Wall ' if CONFIG['CC'] =~ /gcc/
+$CFLAGS << ' -O0 -Wall -fsigned-char' if CONFIG['CC'] =~ /gcc/
dir_config("redcloth_scan")
have_library("c", "main")
create_makefile("redcloth_scan")
Loading…
Cancel
Save