I have a clean install of mountain lion 10.8.2 and have installed rbenv and gem installed wkpdf. When I try and run wkpdf, I get the following message:
xxxx-MacBook-Pro:~ xxx$ wkpdf --help
Cannot load RubyCocoa library
wkpdf requires that RubyCocoa is installed, which is shipped by default since
Mac OS X 10.5. If you use Mac OS X 10.4, you have to install RubyCocoa
yourself from http://rubycocoa.sourceforge.net/HomePage
Is possible to run wkpdf in the rbenv environment? (I have posted a similar question on rbenv github but have not yet had a response)
It's possible that you have installed wkpdf in a Ruby version other than "system" one. Check your active version with rbenv versions
.
When installing and using wkpdf, ensure that you've selected the "system" version:
RBENV_VERSION=system gem install wkpdf
Also when using the gem, you must use "system" version as well for executing code in your project, or the gem won't be found.
It seems that because of the nature of how wkpdf works, it relies on executing within system Ruby on OS X.