I have built abcl from source Then went to write my first simple hello world....
public class Tester {
void simple() { Interpreter interpreter = Interpreter.createInstance(); LispObject result = interpreter.eval("(format t "Hello, world!~%")"); System.out.println(result); }
public static void main(String[] args) {
new Tester().simple(); } }
The execution fails with the following. ant -f C:\git\abcl -Djavac.includes=org/armedbear/lisp/util/Tester.java - Dnb.internal.action.name=run.single -Drun.class=org.armedbear.lisp.util.Tester run-single init: Deleting: C:\git\abcl\build\built-jar.properties deps-jar: Updating property file: C:\git\abcl\build\built-jar.properties Compiling 1 source file to C:\git\abcl\build\classes compile-single: run-single: LISP_HOME C:\git\abcl\src\org\armedbear\lisp\ java.lang.ClassNotFoundException: org.armedbear.lisp.SpecialOperators at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2802) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) java.lang.ClassNotFoundException: org.armedbear.lisp.AutoloadGeneralizedReference at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2807) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) java.lang.ClassNotFoundException: org.armedbear.lisp.cxr at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2808) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) java.lang.ClassNotFoundException: org.armedbear.lisp.Do at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2809) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) java.lang.ClassNotFoundException: org.armedbear.lisp.dolist at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2810) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) java.lang.ClassNotFoundException: org.armedbear.lisp.dotimes at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2811) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) java.lang.ClassNotFoundException: org.armedbear.lisp.ash at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2816) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) java.lang.ClassNotFoundException: org.armedbear.lisp.PackageFunctions at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:349) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.armedbear.lisp.Lisp.loadClass(Lisp.java:2791) at org.armedbear.lisp.Lisp.<clinit>(Lisp.java:2818) at org.armedbear.lisp.Function$pf_function_class_bytes.<init>(Function.java:225) at org.armedbear.lisp.Function.<clinit>(Function.java:222) at org.armedbear.lisp.Interpreter.<clinit>(Interpreter.java:532) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) Unable to determine LISP_HOME. Unable to determine LISP_HOME. org.armedbear.lisp.IntegrityError ERROR placeholder called with arguments: at org.armedbear.lisp.Primitives$pf_error.execute(Primitives.java:1577) Failed to find loadable system file 'boot.lisp' in boot classpath. at org.armedbear.lisp.Primitive.execute(Primitive.java:113) at org.armedbear.lisp.Symbol.execute(Symbol.java:803) at org.armedbear.lisp.Lisp.error(Lisp.java:383) Failed to find loadable system file 'boot.lisp' in boot classpath. at org.armedbear.lisp.Load.loadSystemFile(Load.java:322) at org.armedbear.lisp.Interpreter.initializeLisp(Interpreter.java:172) at org.armedbear.lisp.Interpreter.createInstance(Interpreter.java:72) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) Exception in thread "main" org.armedbear.lisp.IntegrityError at org.armedbear.lisp.Primitives$pf_error.execute(Primitives.java:1577) at org.armedbear.lisp.Primitive.execute(Primitive.java:113) at org.armedbear.lisp.Symbol.execute(Symbol.java:803) at org.armedbear.lisp.Lisp.error(Lisp.java:383) at org.armedbear.lisp.Load.loadSystemFile(Load.java:322) at org.armedbear.lisp.Interpreter.initializeLisp(Interpreter.java:172) at org.armedbear.lisp.Interpreter.createInstance(Interpreter.java:72) at org.armedbear.lisp.util.Tester.simple(Tester.java:34) at org.armedbear.lisp.util.Tester.main(Tester.java:50) C:\git\abcl\nbproject\build-impl.xml:1339: The following error occurred while executing this line: C:\git\abcl\nbproject\build-impl.xml:980: Java returned: 1 BUILD FAILED (total time: 0 seconds)
On Jan 16, 2019, at 14:21, Stephen Varey srvarey@gmail.com wrote:
I have built abcl from source Then went to write my first simple hello world....
public class Tester {
void simple() { Interpreter interpreter = Interpreter.createInstance(); LispObject result = interpreter.eval("(format t \"Hello, world!~%\")"); System.out.println(result); } public static void main(String[] args) { new Tester().simple(); }
}
The execution fails with the following. ant -f C:\git\abcl -Djavac.includes=org/armedbear/lisp/util/Tester.java -Dnb.internal.action.name=run.single -Drun.class=org.armedbear.lisp.util.Tester run-single init: Deleting: C:\git\abcl\build\built-jar.properties deps-jar: Updating property file: C:\git\abcl\build\built-jar.properties Compiling 1 source file to C:\git\abcl\build\classes compile-single:
It’s a little hard to tell what’s going on, but I *think* you are attempting to build your Tester.java class as part of the ABCL build, perhaps using a modified version of the file:build.xml to drive, but it is hard to tell without a copy of your source. If you could put up such a copy online, it would be helpful to diagnose things as I would have a reproducible recipe locally.
Developers usually build their application not by modifying the contents of `abcl.jar`, but an additional archive. It is fairly trivial to rebould a copy of `abcl-contrib` that contains a customized contribution.
Since your Tester.java is purely Java side, you might be able to get away with a simple invocation of `java` which includes `abcl.jar` in its class path like:
``` java -cp SOMEWHERE/abcl.jar:. Tester ```
I suspect you are trying to accomplish all of this via Netbeans projects. While possible, one has to understand a fair amount of the details, so being able to reproduce from the command line for a given online copy of the source would be ideal to get something working.
Yours, Mark
armedbear-devel@common-lisp.net