Modified: trunk/dports/ruby/rb-ncurses-ruby/Portfile (74485 => 74486)
--- trunk/dports/ruby/rb-ncurses-ruby/Portfile 2010-12-19 08:22:46 UTC (rev 74485)
+++ trunk/dports/ruby/rb-ncurses-ruby/Portfile 2010-12-19 09:16:49 UTC (rev 74486)
@@ -2,6 +2,7 @@
PortSystem 1.0
PortGroup ruby 1.0
+
set myname ncurses-ruby
ruby.setup ${myname} 1.2.3 fetch
revision 1
@@ -35,17 +36,19 @@
copy ${filespath}/${myname}.gemspec ${worksrcpath}
}
+patchfiles extconf.rb.diff
+
use_configure no
build {
- system "cd ${worksrcpath} && ${ruby.gem} build ${myname}.gemspec"
+ system "cd ${worksrcpath} && ${ruby.gem} build ${myname}.gemspec -- --with-ncurses-include=${prefix}/include/ncurses"
}
destroot {
# This is basically just copied from the ruby portgroup, with a
# change to the gem location since we just built it
xinstall -d -m 0755 ${destroot}${prefix}/lib/ruby/gems/${ruby.version}
- system "cd ${worksrcpath} && ${ruby.gem} install --local --force --install-dir ${destroot}${prefix}/lib/ruby/gems/${ruby.version} ${worksrcpath}/ncurses-${version}.gem"
+ system "cd ${worksrcpath} && ${ruby.gem} install --local --force --install-dir ${destroot}${prefix}/lib/ruby/gems/${ruby.version} ${worksrcpath}/ncurses-${version}.gem -- --with-ncurses-include=${prefix}/include/ncurses"
set binDir ${destroot}${prefix}/lib/ruby/gems/${ruby.version}/bin
if {[file isdirectory $binDir]} {
foreach file [readdir $binDir] {
@@ -61,4 +64,3 @@
ln -s ${ruby.gemdir}/ncurses-${version}/lib/ncurses_bin.bundle \
${destroot}${ruby.lib}/${rubyarch}
}
-
Added: trunk/dports/ruby/rb-ncurses-ruby/files/extconf.rb.diff (0 => 74486)
--- trunk/dports/ruby/rb-ncurses-ruby/files/extconf.rb.diff (rev 0)
+++ trunk/dports/ruby/rb-ncurses-ruby/files/extconf.rb.diff 2010-12-19 09:16:49 UTC (rev 74486)
@@ -0,0 +1,11 @@
+--- extconf.rb.orig 2009-06-26 08:01:24.000000000 +1000
++++ extconf.rb 2010-12-19 20:08:48.000000000 +1100
+@@ -28,6 +28,8 @@
+ have_header("unistd.h")
+ have_header("locale.h")
+
++dir_config("ncurses")
++
+ if have_header("ncurses.h")
+ curses_header = "ncurses.h"
+ elsif have_header("ncurses/curses.h")