I'm trying to use system.lisp as the hook into writing code that reads command line parameters and does stuff - to use abcl for scripting.
The problem is that debugging it is ... uncomfortable... , because
(handler-case (require 'system) (t ()))
Means that any error just stops what's happening.
How can I establish that my code running as called from system.lisp runs in a normal debugging environment?
Thanks, Alan
On 5/11/10 10:36 PM, Alan Ruttenberg wrote:
I'm trying to use system.lisp as the hook into writing code that reads command line parameters and does stuff - to use abcl for scripting.
The problem is that debugging it is ... uncomfortable... , because
(handler-case (require 'system) (t ()))
Means that any error just stops what's happening.
How can I establish that my code running as called from system.lisp runs in a normal debugging environment?
This code is executed before the standard restarts have been put into place, as far as I can tell. Perhaps this code should be executed later?
I'm struggling trying to understand what sort of restarts have been established where in the code, so help would be appreciated. As Alan points out, the way both the inclusion of the system code and the implementation of require is sub-optimal, so suggestions are welcome.
On 5/12/10 12:09 PM, Mark Evenson wrote: […]
How can I establish that my code running as called from system.lisp runs in a normal debugging environment?
This code is executed before the standard restarts have been put into place, as far as I can tell. Perhaps this code should be executed later?
I [moved the execution of of 'system.lisp'][1] later in the boot after the condition system has been initialized so that conditions now drop to the debugger.
[1]: http://trac.common-lisp.net/armedbear/changeset/12673
And [there is now a facility to customize the code in 'system.lisp'][2] as part of the Ant build: set the Ant property 'abcl.startup.file' to refer to a file whose forms will be appended.
[2]: http://trac.common-lisp.net/armedbear/changeset/12671
Please let me know if this doesn't work out for you.
ooh - thanks :)
FWIW, I've been updating the system.lisp using jar uf as it's usually post-build that I'm doing this stuff. However, I've been prototyping a distribution system that has two parts - an abcl combined with all java libraries, and a second, smaller file with compiled lisp files as a manner of distribution and so it may be that I will suggest some generic code for system.lisp that supports that. I'll try to write it up in the next couple of weeks. I've already successfully deployed using this, but it still needs some further review and work (for instance testing and using your fix to directory/wild)
-Alan
Current status:
http://code.google.com/p/lsw2/downloads/list http://code.google.com/p/lsw2/source/browse/trunk/packit/org/armedbear/lisp/... http://code.google.com/p/lsw2/source/browse/trunk/packit/jar-current-classpa... http://code.google.com/p/lsw2/source/browse/trunk/packit/jar-current-loaded-... http://code.google.com/p/lsw2/source/browse/trunk/owl2/abcl-module-owltool.l...
On Thu, May 13, 2010 at 8:55 AM, Mark Evenson evenson@panix.com wrote:
On 5/12/10 12:09 PM, Mark Evenson wrote: […]
How can I establish that my code running as called from system.lisp runs in a normal debugging environment?
This code is executed before the standard restarts have been put into place, as far as I can tell. Perhaps this code should be executed later?
I [moved the execution of of 'system.lisp'][1] later in the boot after the condition system has been initialized so that conditions now drop to the debugger.
And [there is now a facility to customize the code in 'system.lisp'][2] as part of the Ant build: set the Ant property 'abcl.startup.file' to refer to a file whose forms will be appended.
Please let me know if this doesn't work out for you.
-- "A screaming comes across the sky. It has happened before, but there is nothing to compare to it now."
armedbear-devel mailing list armedbear-devel@common-lisp.net http://common-lisp.net/cgi-bin/mailman/listinfo/armedbear-devel
eh, well
[echo] [echo] Compiling Lisp system [echo] from /Users/alanr/repos/abcl/src/org/armedbear/lisp [echo] to /Users/alanr/repos/abcl/build/classes/org/armedbear/lisp [java] Armed Bear Common Lisp 0.21.0-dev (built Thu May 13 2010 10:28:36 EDT) [java] Java 1.5.0_19 Apple Inc. [java] Java HotSpot(TM) Client VM [java] Low-level initialization completed in 0.415 seconds. [java] Startup completed in 4.991 seconds. [java] #<THREAD "interpreter" {7BD86D}>: Debugger invoked on condition of type ERROR [java] Failed to find loadable system file 'system' in boot classpath. [java] [1] CL-USER(1):
On Thu, May 13, 2010 at 9:23 AM, Alan Ruttenberg alanruttenberg@gmail.comwrote:
ooh - thanks :)
FWIW, I've been updating the system.lisp using jar uf as it's usually post-build that I'm doing this stuff. However, I've been prototyping a distribution system that has two parts - an abcl combined with all java libraries, and a second, smaller file with compiled lisp files as a manner of distribution and so it may be that I will suggest some generic code for system.lisp that supports that. I'll try to write it up in the next couple of weeks. I've already successfully deployed using this, but it still needs some further review and work (for instance testing and using your fix to directory/wild)
-Alan
Current status:
http://code.google.com/p/lsw2/downloads/list
http://code.google.com/p/lsw2/source/browse/trunk/packit/org/armedbear/lisp/...
http://code.google.com/p/lsw2/source/browse/trunk/packit/jar-current-classpa...
http://code.google.com/p/lsw2/source/browse/trunk/packit/jar-current-loaded-...
http://code.google.com/p/lsw2/source/browse/trunk/owl2/abcl-module-owltool.l...
On Thu, May 13, 2010 at 8:55 AM, Mark Evenson evenson@panix.com wrote:
On 5/12/10 12:09 PM, Mark Evenson wrote: […]
How can I establish that my code running as called from system.lisp
runs
in a normal debugging environment?
This code is executed before the standard restarts have been put into place, as far as I can tell. Perhaps this code should be executed
later?
I [moved the execution of of 'system.lisp'][1] later in the boot after the condition system has been initialized so that conditions now drop to the debugger.
And [there is now a facility to customize the code in 'system.lisp'][2] as part of the Ant build: set the Ant property 'abcl.startup.file' to refer to a file whose forms will be appended.
Please let me know if this doesn't work out for you.
-- "A screaming comes across the sky. It has happened before, but there is nothing to compare to it now."
armedbear-devel mailing list armedbear-devel@common-lisp.net http://common-lisp.net/cgi-bin/mailman/listinfo/armedbear-devel
On 5/13/10 4:41 PM, Alan Ruttenberg wrote:
eh, well
[echo] [echo] Compiling Lisp system [echo] from /Users/alanr/repos/abcl/src/org/armedbear/lisp [echo] to /Users/alanr/repos/abcl/build/classes/org/armedbear/lisp [java] Armed Bear Common Lisp 0.21.0-dev (built Thu May 13 2010
10:28:36 EDT) [java] Java 1.5.0_19 Apple Inc. [java] Java HotSpot(TM) Client VM [java] Low-level initialization completed in 0.415 seconds. [java] Startup completed in 4.991 seconds. [java] #<THREAD "interpreter" {7BD86D}>: Debugger invoked on condition of type ERROR [java] Failed to find loadable system file 'system' in boot classpath. [java] [1] CL-USER(1):
Arrgh. [Fixed in r12675?][1].
[1]: http://trac.common-lisp.net/armedbear/changeset/12675
Still no cigar :(
java -server -Xmx1024m -Xss24m -d32 -cp /Users/alanr/repos/lsw2/trunk/bin/../lib/abcl.jar:/Users/alanr/repos/lsw2/trunk/bin/../lib/asm-all-3.1.jar:/Users/alanr/repos/lsw2/trunk/bin/../lib/bsh-2.0b4.jar:/Users/alanr/repos/lsw2/trunk/bin/../lib/httpserver.jar:/Users/alanr/repos/lsw2/trunk/bin/../lib/jscheme.jar:/Users/alanr/repos/lsw2/trunk/bin/../lib/script-api.jar:/Users/alanr/repos/lsw2/trunk/bin/../lib/skij.jar:/Users/alanr/repos/lsw2/trunk/bin/../lib/virtjdbc3.jar -Xdock:icon=/Users/alanr/repos/lsw2/trunk/bin/../images/lswicon.icns -Xdock:name=Armed Bear Common Lisp org.armedbear.lisp.Main --load /Users/alanr/repos/lsw2/trunk/bin/../scripts/system-registry.lisp --eval (asdf::oos 'asdf::load-op 'owl2) Armed Bear Common Lisp 0.21.0-dev Java 1.5.0_19 Apple Inc. Java HotSpot(TM) Server VM Low-level initialization completed in 0.444 seconds. java.lang.Error at org.armedbear.lisp.Primitives$pf_error.execute(Primitives.java:1561) at org.armedbear.lisp.Primitive.execute(Primitive.java:108) at org.armedbear.lisp.Symbol.execute(Symbol.java:776) at org.armedbear.lisp.Lisp.error(Lisp.java:356) at org.armedbear.lisp.Load.loadSystemFile(Load.java:287) at org.armedbear.lisp.Load$load_system_file.execute(Load.java:686) at org.armedbear.lisp.LispThread.execute(LispThread.java:568) at org.armedbear.lisp.Lisp.evalCall(Lisp.java:522) at org.armedbear.lisp.Lisp.eval(Lisp.java:487) at org.armedbear.lisp.Load.loadStream(Load.java:561) at org.armedbear.lisp.Load.loadFileFromStream(Load.java:523) at org.armedbear.lisp.Load.loadFileFromStream(Load.java:413) at org.armedbear.lisp.Load.loadSystemFile(Load.java:337) at org.armedbear.lisp.Interpreter.initializeLisp(Interpreter.java:161) at org.armedbear.lisp.Interpreter.createDefaultInstance(Interpreter.java:93) at org.armedbear.lisp.Main$1.run(Main.java:48) at java.lang.Thread.run(Thread.java:613) ERROR placeholder called with arguments: #<ERROR {A449E0}> Failed to find loadable system file 'autoloads' in boot classpath.
On Thu, May 13, 2010 at 12:39 PM, Mark Evenson evenson@panix.com wrote:
On 5/13/10 4:41 PM, Alan Ruttenberg wrote:
eh, well
[echo] [echo] Compiling Lisp system [echo] from /Users/alanr/repos/abcl/src/org/armedbear/lisp [echo] to /Users/alanr/repos/abcl/build/classes/org/armedbear/lisp [java] Armed Bear Common Lisp 0.21.0-dev (built Thu May 13 2010
10:28:36 EDT) [java] Java 1.5.0_19 Apple Inc. [java] Java HotSpot(TM) Client VM [java] Low-level initialization completed in 0.415 seconds. [java] Startup completed in 4.991 seconds. [java] #<THREAD "interpreter" {7BD86D}>: Debugger invoked on condition of type ERROR [java] Failed to find loadable system file 'system' in boot classpath. [java] [1] CL-USER(1):
Arrgh. [Fixed in r12675?][1].
-- "A screaming comes across the sky. It has happened before, but there is nothing to compare to it now."
Just svn updated and the latest changes seem to resolve the problem, and let me enter the debugger when there's a problem. Thanks! -Alan
armedbear-devel@common-lisp.net