canweriotnow / rpam-ruby19

PAM auth for Ruby - 1.9 compat version
https://rubygems.org/gems/rpam-ruby19
GNU General Public License v2.0
9 stars 5 forks source link

undefined symbol: STR2CSTR #7

Closed bararchy closed 10 years ago

bararchy commented 10 years ago

When trying the fallowing code:

require 'rpam'
include Rpam

if  authpam("user","pass") == true
  puts "SUCCESS"
else
  puts "FAILED"
end

On Ubuntu12.04 with the latest "gem install rpam-ruby19"

canweriotnow commented 10 years ago

It looks like you may also have plain old 'rpam' installed as well, which may take precedence... part of the ruby-1.9.x compatibility change was removing the (old, <= 1.8.x) STR2CSTR function and using StringValuePtr instead... So it looks like you're using the old rpam with Ruby 1.9.x... can you verify that rpam is not installed and check your Ruby version?

bararchy commented 10 years ago

You had it right, cleaned the development area of all gems and it works as it should.