Comments (6)
I'm also seeing this. I tried to get around this with gem install ncurses
but no joy. I'm stuck in the same place.
from mctop.
Hi Guys,
the curses module is part of the ruby standard library so shouldn't require any additional gems. I've only tested under 1.9.3 and 1.8.7. What verson of ruby are you running?
If you fire up irb can you do a:
require 'curses'
Does that fail?
Cheers,
Marcus
from mctop.
I'm running Ruby 1.9.3, and this does fail:
()[~] ➔ ruby -v
ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-linux]
()[~] ➔ irb
irb(main):001:0> require 'curses'
LoadError: cannot load such file -- curses
from /home/eric/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /home/eric/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from (irb):1
from /home/eric/.rvm/rubies/ruby-1.9.3-p327/bin/irb:12:in `<main>'
irb(main):002:0>
Installing the ncurses gem leads to this (at the end - skipping a long list of make instructions and warnings):
In file included from form_wrap.h:26:0,
from form_wrap.c:28:
/usr/include/form.h:403:28: note: expected ‘const char *’ but argument is of type ‘int’
form_wrap.c: In function ‘make_arg’:
form_wrap.c:1126:38: error: ‘struct RArray’ has no member named ‘len’
form_wrap.c:1130:5: warning: format not a string literal and no format arguments [-Wformat-security]
make: *** [form_wrap.o] Error 1
Gem files will remain installed in /home/eric/.rvm/gems/ruby-1.9.3-p327/gems/ncurses-0.9.1 for inspection.
Results logged to /home/eric/.rvm/gems/ruby-1.9.3-p327/gems/ncurses-0.9.1/./gem_make.out
I'm on Ubuntu 12.10, using rvm.
from mctop.
I'm running Linux Mint 14 (which is a deriviative of Ubuntu 12.10).
$ ruby -v
ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-linux]
$ irb
Readline was unable to be required, if you need completion or history install readline then reinstall the ruby.
You may follow 'rvm notes' for dependencies and/or read the docs page https://rvm.io/packages/readline/ . Be sure you 'rvm remove X ; rvm install X' to re-compile your ruby with readline support after obtaining the readline libraries.
cannot load such file -- irbtools
1.9.3p327 :001 > require 'curses'
LoadError: cannot load such file -- curses
from /home/kgustavson/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in require' from /home/kgustavson/.rvm/rubies/ruby-1.9.3-p327/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in
require'
from (irb):1
from /home/kgustavson/.rvm/rubies/ruby-1.9.3-p327/bin/irb:16:in `
1.9.3p327 :002 >
$ /usr/bin/irb
irb(main):001:0>
Looks like rvm might have a problem. I installed ruby 1.8 and support files then ran...
sudo /usr/bin/ruby1.8 bin/mctop -i eth0
Then it finally came up. It still won't run in system 1.9.3, it can't find pcap.
from mctop.
I looks a little like something wacky with rvm. I've tested in a couple places now. On my Mac with Ruby installed from homebrew:
$ ruby --version
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin12.1.0]
$ irb
irb(main):001:0> require 'curses'
=> true
And i've been using rbenv for testing other Ruby versions, I installed 1.9.3p327 and no problems either:
$ ruby --version
ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-linux]
$ irb
irb(main):001:0> require 'curses'
=> true
You'll need to ensure under each version of ruby you're running it against that you've got the ruby-pcap gem installed. It's a native extension so requires libpcap-devel to be available at gem install time.
Hope that helps.
from mctop.
No further action here ... closing this one
from mctop.
Related Issues (10)
- wrong number of arguments (1 for 0) (ArgumentError) HOT 4
- need some exception handling in the sniffer thread
- Binary protocol HOT 4
- `require': cannot load such file -- curses (LoadError) HOT 3
- Does it work with elastic cache?
- NoMethodError on run HOT 2
- Feature Request: make cap.setfilter port configurable HOT 2
- P.O.C. statsd sniffer for mctop HOT 1
- MemcacheSniffer error on load HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mctop.