Archive of RubyForge sup-talk mailing list
 help / color / mirror / Atom feed
From: Richard Heycock <rgh@topikality.com>
To: sup-talk <sup-talk@rubyforge.org>
Subject: Re: [sup-talk] sent mail
Date: Thu, 08 Apr 2010 23:27:28 +1000	[thread overview]
Message-ID: <1270731588-sup-6397@roughage.com.au> (raw)
In-Reply-To: <alpine.DEB.1.10.1004081346370.23329@stewart.warwick.ac.uk>

Excerpts from Neil Stewart's message of 2010-04-08 22:54:01 +1000:
> Hi Richard,
> 
> > Not sure if this helps but you really don't want to be using ruby 1.9.0
> > the latest is ruby-1.9.1-p376. If you want to install using Debian
> > packages they are in testing.
> >
> >    apt-get install rubygems1.9.1 ruby1.9.1-dev rdoc1.9.1 irb1.9.1
> >
> > should see you right.
> 
> Thanks for the pointers. I've got the right ruby packages now.
> 
> # dpkg -l | grep ruby
> ii  libreadline-ruby1.9.1                1.9.1.378-1                Readline interface for Ruby 1.9.1
> ii  libruby1.9.1                         1.9.1.378-1                Libraries necessary to run Ruby 1.9.1
> ii  ruby1.9.1                            1.9.1.378-1                Interpreter of object-oriented scripting lan
> ii  ruby1.9.1-dev                        1.9.1.378-1                Header files for compiling extension modules
> ii  rubygems1.9.1                        1.3.5-2                    package management framework for Ruby librar
> 
> > "gem install sup" will put a script in /usr/bin so you should be able to
> > simply type sup. If you have multiple versions of ruby you might have
> > problems but if you invoke it thus: /path/to/ruby /usr/bin/sup you
> > should be right.
> 
> "gem install sup" seems to be failing on ncurses.
> 
> # gem install sup
> Building native extensions.  This could take a while...
> ERROR:  Error installing sup:
>          ERROR: Failed to build gem native extension.
> 
> /usr/bin/ruby1.9.1 extconf.rb
> checking for unistd.h... yes
> checking for ncurses.h... yes
> checking for wmove() in -lncurses... yes
> checking for newscr()... yes
> checking for TABSIZE()... yes
> checking for ESCDELAY()... yes
> checking for keybound()... yes
> checking for curses_version()... yes
> [SNIP]
> checking for new_form() in -lform... yes
> creating Makefile
> 
> make
> Makefile:158: warning: overriding commands for target
> `/var/lib/gems/1.9.1/gems/ncurses-0.9.1/lib'
> Makefile:156: warning: ignoring old commands for target
> `/var/lib/gems/1.9.1/gems/ncurses-0.9.1/lib'
> cc -I. -I/usr/include/ruby-1.9.1/x86_64-linux
> -I/usr/include/ruby-1.9.1/ruby/backward -I/usr/include/ruby-1.9.1 -I.
> -DHAVE_UNISTD_H -DHAVE_NCURSES_H -DHAVE_NEWSCR -DHAVE_TABSIZE
> -DHAVE_ESCDELAY -DHAVE_KEYBOUND -DHAVE_CURSES_VERSION -DHAVE_TIGETSTR
> -DHAVE_GETWIN -DHAVE_PUTWIN -DHAVE_UNGETMOUSE -DHAVE_MOUSEMASK
> -DHAVE_WENCLOSE -DHAVE_MOUSEINTERVAL -DHAVE_WMOUSE_TRAFO -DHAVE_MCPRINT
> -DHAVE_HAS_KEY -DHAVE_DELSCREEN -DHAVE_DEFINE_KEY -DHAVE_KEYOK
> -DHAVE_RESIZETERM -DHAVE_USE_DEFAULT_COLORS -DHAVE_USE_EXTENDED_NAMES
> -DHAVE_WRESIZE -DHAVE_ATTR_ON -DHAVE_ATTR_OFF -DHAVE_ATTR_SET -DHAVE_CHGAT
> -DHAVE_COLOR_SET -DHAVE_FILTER -DHAVE_INTRFLUSH -DHAVE_MVCHGAT
> -DHAVE_MVHLINE -DHAVE_MVVLINE -DHAVE_MVWCHGAT -DHAVE_MVWHLINE
> -DHAVE_MVWVLINE -DHAVE_NOQIFLUSH -DHAVE_PUTP -DHAVE_QIFLUSH -DHAVE_SCR_DUMP
> -DHAVE_SCR_INIT -DHAVE_SCR_RESTORE -DHAVE_SCR_SET -DHAVE_SLK_ATTR
> -DHAVE_SLK_ATTR_SET -DHAVE_SLK_COLOR -DHAVE_TIGETFLAG -DHAVE_TIGETNUM
> -DHAVE_USE_ENV -DHAVE_VIDATTR -DHAVE_WATTR_ON -DHAVE_WATTR_OFF
> -DHAVE_WATTR_SET -DHAVE_WCHGAT -DHAVE_WCOLOR_SET -DHAVE_GETATTRS
> -DHAVE_ASSUME_DEFAULT_COLORS -DHAVE_ATTR_GET -DHAVE_PANEL_H -DHAVE_FORM_H
> -fPIC -fno-strict-aliasing -g -g -O2 -O2 -g -Wall -Wno-parentheses  -fPIC -g
> -o form_wrap.o -c form_wrap.c
> form_wrap.c: In function 'rbncurs_m_new_form':
> form_wrap.c:395: error: 'struct RArray' has no member named 'len'
> form_wrap.c: In function 'rbncurs_c_set_field_type':
> form_wrap.c:619: error: 'struct RArray' has no member named 'len'
> form_wrap.c: In function 'rbncurs_c_set_form_fields':
> form_wrap.c:778: error: 'struct RArray' has no member named 'len'
> form_wrap.c: In function 'make_arg':
> form_wrap.c:1126: error: 'struct RArray' has no member named 'len'
> make: *** [form_wrap.o] Error 1
> 
> 
> Gem files will remain installed in /var/lib/gems/1.9.1/gems/ncurses-0.9.1
> for inspection.
> Results logged to /var/lib/gems/1.9.1/gems/ncurses-0.9.1/gem_make.out
> 
> 
> I get pretty much identical output from "gem install ncurses", so I suspect
> the problem is not even a sup issue. Am I doing something terribly wrong?
> All comments most welcome.

You are right it's not a sup issue. Ruby ncurses hasn't been ported to
1.9 so I just used ncursesw which seems to work quite well. Since you
are using gem to install sup you will need to untar the gem file modify
the metadata, tar it all up and reinstall. Something along the lines of:

cd /var/lib/gems/1.9.1/gems/cache/
mkdir tmp; cd tmp
tar xf ../sup-0.11.gem (ignore any timestamp errors)
vi metadata (make sure you use vim which will deal with the compression)
tar cf ../sup-0.11.gem .
cd ..
gem install sup-0.11.gem
rm -r tmp (assuming it works)

If you have problems working out which line to change in the metadata
you could unzip it and apply the following patch:

--- metadata.old        2010-04-08 23:10:27.363603950 +1000
+++ metadata.new        2010-04-08 23:11:09.479559396 +1000
@@ -32,7 +32,7 @@
   type: :runtime
   version_requirements: *id001
 - !ruby/object:Gem::Dependency 
-  name: ncurses
+  name: ncursesw
   prerelease: false
   requirement: &id002 !ruby/object:Gem::Requirement 
     requirements: 

And that should do you.

Or you could download a modified gem from http://stuff.roughage.com.au/sup-0.11.gem.
That gem was built from git and works (on my machine!).

William, is there any reason you are using ncurses and not ncursesw?

rgh

> Best,
> Neil.
> 
-- 
Richard Heycock

http://topikality.com

+61 (0) 410 646 369
[e]:  rgh@topikality.com
[im]: rgh@topikality.com
_______________________________________________
sup-talk mailing list
sup-talk@rubyforge.org
http://rubyforge.org/mailman/listinfo/sup-talk


  reply	other threads:[~2010-04-08 13:27 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-04-08 10:08 Neil Stewart
2010-04-08 12:01 ` Richard Heycock
2010-04-08 12:54   ` Neil Stewart
2010-04-08 13:27     ` Richard Heycock [this message]
     [not found]       ` <alpine.DEB.1.10.1004092231370.4476@stewart.warwick.ac.uk>
2010-04-09 21:37         ` Neil Stewart
2010-04-09 22:09       ` Rich Lane
2010-04-14 13:06         ` William Morgan
2010-04-08 21:44   ` Neil Stewart
  -- strict thread matches above, loose matches on Subject: below --
2010-04-06 14:13 Neil Stewart
2010-04-06 16:23 ` Michael Stapelberg

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1270731588-sup-6397@roughage.com.au \
    --to=rgh@topikality.com \
    --cc=sup-talk@rubyforge.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox