[122863] trunk/dports/lang/ruby21
kimuraw at macports.org
kimuraw at macports.org
Fri Aug 1 04:33:02 PDT 2014
Revision: 122863
https://trac.macports.org/changeset/122863
Author: kimuraw at macports.org
Date: 2014-08-01 04:33:02 -0700 (Fri, 01 Aug 2014)
Log Message:
-----------
lang/ruby21: fix ext/fiddle not installed with libffi-3.1 (#44508)
- https://bugs.ruby-lang.org/issues/9897 ext/fiddle not installed with libffi-3.1
- https://bugs.ruby-lang.org/issues/9656 ext/dl not installed with apple clang-5.1
Modified Paths:
--------------
trunk/dports/lang/ruby21/Portfile
Added Paths:
-----------
trunk/dports/lang/ruby21/files/patch-ext-dl-extconf.rb.diff
trunk/dports/lang/ruby21/files/patch-ext-fiddle-extconf.rb.diff
Modified: trunk/dports/lang/ruby21/Portfile
===================================================================
--- trunk/dports/lang/ruby21/Portfile 2014-08-01 04:44:40 UTC (rev 122862)
+++ trunk/dports/lang/ruby21/Portfile 2014-08-01 11:33:02 UTC (rev 122863)
@@ -6,7 +6,7 @@
name ruby21
version 2.1.2
-revision 0
+revision 1
categories lang ruby
maintainers kimuraw openmaintainer
@@ -59,6 +59,11 @@
# Port "ruby" and "ruby19" does the same.
configure.env-append UNAME_RELEASE=${os.major}
+# patch-ext-fiddle-extconf.rb.diff: https://bugs.ruby-lang.org/issues/9897
+# patch-ext-dl-extconf.rb.diff: https://bugs.ruby-lang.org/issues/9656
+patchfiles patch-ext-dl-extconf.rb.diff \
+ patch-ext-fiddle-extconf.rb.diff
+
# Add the architecture flag as required
if {[info exists build_arch] && ${build_arch} != ""} {
configure.args-append "--with-arch=${build_arch}"
Added: trunk/dports/lang/ruby21/files/patch-ext-dl-extconf.rb.diff
===================================================================
--- trunk/dports/lang/ruby21/files/patch-ext-dl-extconf.rb.diff (rev 0)
+++ trunk/dports/lang/ruby21/files/patch-ext-dl-extconf.rb.diff 2014-08-01 11:33:02 UTC (rev 122863)
@@ -0,0 +1,18 @@
+Index: ext/dl/extconf.rb
+===================================================================
+--- ext/dl/extconf.rb (revision 46302)
++++ ext/dl/extconf.rb (revision 46303)
+@@ -1,7 +1,12 @@
+ require 'mkmf'
+
+ if RbConfig::CONFIG['GCC'] == 'yes'
+- (have_macro("__clang__") ? $LDFLAGS : $CFLAGS) << " -fno-defer-pop"
++ flag = " -fno-defer-pop"
++ if have_macro("__clang__")
++ $LDFLAGS << flag if try_ldflags(flag)
++ else
++ $CFLAGS << flag
++ end
+ $CFLAGS << " -fno-omit-frame-pointer"
+ end
+
Added: trunk/dports/lang/ruby21/files/patch-ext-fiddle-extconf.rb.diff
===================================================================
--- trunk/dports/lang/ruby21/files/patch-ext-fiddle-extconf.rb.diff (rev 0)
+++ trunk/dports/lang/ruby21/files/patch-ext-fiddle-extconf.rb.diff 2014-08-01 11:33:02 UTC (rev 122863)
@@ -0,0 +1,14 @@
+Index: ext/fiddle/extconf.rb
+===================================================================
+--- ext/fiddle/extconf.rb (revision 46608)
++++ ext/fiddle/extconf.rb (revision 47020)
+@@ -7,7 +7,8 @@
+ pkg_config("libffi")
+ if ver = pkg_config("libffi", "modversion")
+ ver = ver.gsub(/-rc\d+/, '') # If ver contains rc version, just ignored.
+- $defs.push(%{-DRUBY_LIBFFI_MODVERSION=#{ '%d%03d%03d' % ver.split('.') }})
++ ver = (ver.split('.') + [0,0])[0,3]
++ $defs.push(%{-DRUBY_LIBFFI_MODVERSION=#{ '%d%03d%03d' % ver }})
+ end
+
+ unless have_header('ffi.h')
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-changes/attachments/20140801/c9e2c288/attachment.html>
More information about the macports-changes
mailing list