[armedbear-devel] Using ABCL's JSR-223 support for Ant integration

Erik Huelsmann ehuels at gmail.com
Sun Dec 12 10:10:15 UTC 2010


Hi Jim!

On Sun, Dec 12, 2010 at 7:07 AM, Jim White <jim at pagesmiths.com> wrote:
> Erik Huelsmann wrote:
>
>
>> 2. What's happening with the 1-character-per-line output of my script????
>
> Having been around Ant task and JSR-223 code, my suspicion is that there is
> a flush being done for each character in ABCL.  The Ant outputStream
> wrappings log each of those flushes as a complete line of output.

Thanks for your help! With the current trunk version of ABCL, I'm able
to embed the following script in ABCL-web's build.xml; it's the basis
for a script to add lisp-file compilation: now it only prints output
(which is how I found the issue I was writing about earlier).

<script language="ABCL" classpath="lib/abcl.jar"><![CDATA[

(require "JAVA")
(let* ((the-project (jcall "getProject" self))
       (the-fileset (jcall "getReference" the-project "lisp-files"))
       (files-iterator (jcall (jmethod
"org.apache.tools.ant.types.Path" "iterator")
                                 the-fileset)))
   (loop while (jcall "hasNext" files-iterator)
        do (print (jcall "next" files-iterator))))
        ]]></script>


Bye,


Erik.




More information about the armedbear-devel mailing list