Skip to content

Commit

Permalink
Remove patch for using UTF-8 as the default for Encoding.default_exte…
Browse files Browse the repository at this point in the history
…rnal.

This is in response to issue #38.

I'll introduce an option in the installer to enable it.
  • Loading branch information
larskanis committed May 19, 2017
1 parent 46e1803 commit faee373
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 43 deletions.
13 changes: 0 additions & 13 deletions recipes/compile/ruby-2.3.4/0005-utf-8-default-encoding.patch

This file was deleted.

3 changes: 0 additions & 3 deletions recipes/compile/ruby-2.3.4/PKGBUILD.erb
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@ source=("https://cache.ruby-lang.org/pub/ruby/${pkgver%.*}/${_realname}-${pkgver
0002-use-gnu-printf.patch
0003-fix-check-types.patch
0004-exclude-changelog-from-rdoc.patch
0005-utf-8-default-encoding.patch
0006-fix-conversion-warning-win32-powl.patch
0007-rbinstall-destdir.patch
ruby.ico
Expand All @@ -33,7 +32,6 @@ sha256sums=('cd9808bb53824d6edb58beaadd3906cb23b987438ce75ab7bb279b2229930e2f'
'578bd0830fe96efc7656c732ec46b0658fc436a7a30d8945cf3b8240797809f0'
'846d73ad389249c54ff4e009ad2fd4cdbc46714fce25c724bc706b3ec2f2fe3a'
'389236bdca5f283adde9b4b56febcfc25e228716e06a0edc21ea8fd7f27b75fa'
'76159e9fcefba7220e7b22fc1825714d5b734e1613eda53ad9fcc66c04f33f78'
'e7f83bc6e3b7ddadb5e3b14aa7d3a4e30eb97aea02df38796ca78714ad20e9b7'
'02382ec3b9e42d7dbb58edad3e41c361d98871711bb2f0320082c2acc6a82e2e'
'6c80ba2ca49840e387a08b7fedc6e7acd298ac2ec853155209efb2af20397b22'
Expand All @@ -45,7 +43,6 @@ prepare() {
patch -p1 -i ${srcdir}/0002-use-gnu-printf.patch
patch -p1 -i ${srcdir}/0003-fix-check-types.patch
patch -p1 -i ${srcdir}/0004-exclude-changelog-from-rdoc.patch
patch -p1 -i ${srcdir}/0005-utf-8-default-encoding.patch
patch -p1 -i ${srcdir}/0006-fix-conversion-warning-win32-powl.patch
patch -p1 -i ${srcdir}/0007-rbinstall-destdir.patch

Expand Down
22 changes: 0 additions & 22 deletions recipes/compile/ruby-2.4.1/0005-utf-8-default-encoding.patch

This file was deleted.

3 changes: 0 additions & 3 deletions recipes/compile/ruby-2.4.1/PKGBUILD.erb
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ options=('staticlibs' 'strip')
source=("https://cache.ruby-lang.org/pub/ruby/${pkgver%.*}/${_realname}-${pkgver}.tar.bz2"
0002-use-gnu-printf.patch
0004-exclude-changelog-from-rdoc.patch
0005-utf-8-default-encoding.patch
0006-fix-conversion-warning-win32-powl.patch
ruby.ico
rubyw.ico)
Expand All @@ -28,7 +27,6 @@ source=("https://cache.ruby-lang.org/pub/ruby/${pkgver%.*}/${_realname}-${pkgver
sha256sums=('ccfb2d0a61e2a9c374d51e099b0d833b09241ee78fc17e1fe38e3b282160237c'
'578bd0830fe96efc7656c732ec46b0658fc436a7a30d8945cf3b8240797809f0'
'389236bdca5f283adde9b4b56febcfc25e228716e06a0edc21ea8fd7f27b75fa'
'339538b8b06feaf54de525dcae3c11ee548a1fb97fbe0ad319019027d6d19044'
'e7f83bc6e3b7ddadb5e3b14aa7d3a4e30eb97aea02df38796ca78714ad20e9b7'
'6c80ba2ca49840e387a08b7fedc6e7acd298ac2ec853155209efb2af20397b22'
'c30fb04ac0e88ba634daaa811a81ea5a75027646617b895acd14df9518a4a55a')
Expand All @@ -37,7 +35,6 @@ prepare() {
cd ${srcdir}/${_realname}-${pkgver}
patch -p1 -i ${srcdir}/0002-use-gnu-printf.patch
patch -p1 -i ${srcdir}/0004-exclude-changelog-from-rdoc.patch
patch -p1 -i ${srcdir}/0005-utf-8-default-encoding.patch
patch -p1 -i ${srcdir}/0006-fix-conversion-warning-win32-powl.patch

autoreconf -fi
Expand Down
4 changes: 2 additions & 2 deletions test/test_encoding.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@

class TestEncoding < Minitest::Test
def test_default_external
assert_equal Encoding::UTF_8, Encoding.default_external
assert_equal Encoding.find("locale"), Encoding.default_external
end

def test_default_internal
assert_nil Encoding.default_internal
end

def test_default_external_file_read
content = File.read(__FILE__)
content = File.read(__FILE__, encoding: __ENCODING__)
assert_equal Encoding::UTF_8, content.encoding
assert_match(/ÄöüßЖ/, content)
end
Expand Down

0 comments on commit faee373

Please sign in to comment.