<< Back to previous view

[CLJ-843] clojure.lang.RT should provide a loadLibrary static method Created: 26/Sep/11  Updated: 02/Dec/11  Resolved: 02/Dec/11

Status: Closed
Project: Clojure
Component/s: None
Affects Version/s: Release 1.3
Fix Version/s: Release 1.4

Type: Enhancement Priority: Minor
Reporter: Baishampayan Ghose Assignee: Unassigned
Resolution: Completed Votes: 0
Labels: None

Attachments: Text File 0001-Add-a-static-method-loadLibrary-to-clojure.lang.RT-t.patch    
Patch: Code
Approval: Ok


Right now, loading native libraries in Clojure doesn't work as expected because those libraries are loaded into the classloader of the invoking class (that is, Clojure's own classloader).

This problem has been discussed on the mailing list and a patch has been welcomed by Rich -


To fix this, I am attaching a trivial patch that implements loadLibrary in RT.

Comment by Chouser [ 20/Nov/11 4:02 PM ]

Tests would be nice, though I can see how getting such a test to work without 3rd party deps might be difficult.

My naive attempts to reproduce the problem failed. For example, this works fine for me:
(System/loadLibrary "hprof")

Nevertheless, the patch applies cleanly and appears to be what Rich asked for, so I'm setting this to "screened".

Generated at Sun May 19 11:56:01 CDT 2019 using JIRA 4.4#649-r158309.