File.lchmod causes UnsatisfiedLinkError on unsupported platforms
----------------------------------------------------------------
Key: JRUBY-2274
URL: http://jira.codehaus.org/browse/JRUBY-2274
Project: JRuby
Issue Type: Bug
Components: Core Classes/Modules
Environment: OS X, Java 1.5, JRuby 1.1RC2
Reporter: Daniel Berger
Priority: Minor
On MRI calling File.lchmod raises a NoMethodError on OS X. JRuby blows up:
{noformat}
File.lchmod(0755, 'test.txt') # lchmod_test.rb
daniel-bergers-computer:~/programming/jruby djberge$ jruby lchmod_test.rb
Exception in thread "main" java.lang.UnsatisfiedLinkError: Error looking up
function 'lchmod': dlsym(0x1007c0, lchmod): symbol not found
at com.sun.jna.Function.<init>(Function.java:126)
at com.sun.jna.NativeLibrary.getFunction(NativeLibrary.java:219)
at com.sun.jna.Library$Handler.invoke(Library.java:191)
at $Proxy0.lchmod(Unknown Source)
at org.jruby.ext.posix.BaseNativePOSIX.lchmod(BaseNativePOSIX.java:151)
at org.jruby.RubyFile.lchmod(RubyFile.java:1297)
at org.jruby.RubyFileInvoker$lchmod_method_2_0.call(Unknown Source)
at
org.jruby.internal.runtime.methods.JavaMethod$JavaMethodNoBlock.call(JavaMethod.java:63)
at
org.jruby.internal.runtime.methods.DynamicMethod.call(DynamicMethod.java:86)
at
org.jruby.runtime.CallSite$InlineCachingCallSite.cacheAndCall(CallSite.java:177)
at
org.jruby.runtime.CallSite$InlineCachingCallSite.call(CallSite.java:339)
at
ruby.Users.djberge.programming.jruby.lchmod_test.__file__(lchmod_test.rb:1)
at ruby.Users.djberge.programming.jruby.lchmod_test.load(lchmod_test.rb)
at org.jruby.Ruby.runScript(Ruby.java:497)
at org.jruby.Ruby.runNormally(Ruby.java:417)
at org.jruby.Ruby.runFromMain(Ruby.java:297)
at org.jruby.Main.run(Main.java:141)
at org.jruby.Main.run(Main.java:88)
at org.jruby.Main.main(Main.java:79)
{noformat}
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email