Lisp filepath issues when running application directly from jar file

Hamda Binte Ajmal hamda.binte.ajmal at
Fri Aug 14 10:20:18 UTC 2015

I was working on an application, that loads a few lisp files using lisp
(load "fullfilepath.lisp") from java using ABCL.
This file in turn loads the other lisp files located in same folder
hierarchy, and then i call lisp functions (defined in these files) from
java and everything works perfect as long as I run the application from
Close to deployment, I tested the application by running it from jar file,
I found that there are issues with filepaths, as the files are not a part
of file-system, and hence not accessible using a file-path.
Does anyone has any idea how to fix this issue ?
I tried many things, like

URL url = LispConnector.class.getResource("/Aima/aima/quicklisp/setup.lisp");String
path = url.getFile();File f = new File(path);
path = f.getAbsolutePath();
path = path.replace("\\", "/");

which returns [image: enter image description here]

But which is wrong as this is not a valid file path and does not exists so
lisp : (load "filepath") fails here.

When I use the code

String path = url.toURI();File = new File(path);
path = path.getAbsolutePath();

Again it works fine while running from netbeans, but shows error "URI is
not hierarchical" error while running the jar file.

Has anyone encountered this issue, please help.

Hamda Binte Ajmal
NUIG, Ireland
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>

More information about the armedbear-devel mailing list