ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Scot P. Floess" <flo...@mindspring.com>
Subject Re: Trouble executing a beanshell script
Date Tue, 09 Jan 2007 13:37:30 GMT
Peter:

Perfect...I can do that!  Thanks ;)

Scot

Peter Reilly wrote:
> On 1/8/07, Scot P. Floess <floess@mindspring.com> wrote:
>> Peter:
>>
>> Thanks for the prompt reply :)
>>
>> I downloaded apache-ant-20070107-bin.tar.bz2
>> <http://people.apache.org/builds/ant/nightly/apache-ant-20070107-bin.tar.bz2>

>>
>> and got the same result.  Executing "ant -version" yields:
>>
>> Apache Ant version 1.7.0RC1 compiled on January 7 2007
>>
>> Did I download the wrong thing?
> No,.... -- download and check ---- ....
> but it seems that the nightly builds are not working - or
> at least not picking up the HEAD of SVN.
>
> You will need to compile your own copy.....
> 1) Get the svn source from http://svn.apache.org/snapshots/ant/
>   or svn co http://svn.apache.org/repos/asf/ant/core/trunk/ ant
> 2) get bsf.jar from within the binary dist from
>    http://jakarta.apache.org/site/downloads/downloads_bsf.cgi
> 3) get /commons-logging-1.1.jar  from within the binary dist from
>   http://jakarta.apache.org/site/downloads/downloads_commons-logging.cgi
> 4) untar the ant svn source to $ANT_SRC
>   copy bsf.jar and commons-logging-1.1.jar to $ANT_SRC/lib/optional
> 5) build ant using build.sh -
>   cd $ANT_SRC; ./build.sh
> 6) set ANT_HOME to $ANT_SRC/dist
>   export ANT_HOME=~/src/ant/dist
>
>   Peter
>
>
>
>
>>
>> Thanks,
>>
>> Scot
>>
>>
>>
>>
>> Peter Reilly wrote:
>> > On 1/8/07, Scot P. Floess <floess@mindspring.com> wrote:
>> >> All:
>> >>
>> >> I was trying to execute a simple beanshell script from within my ant
>> >> script (I tried using an example found in the documentation):
>> >> From the manual:
>> >
>> > """NB: This classpath cannot (currently) be used to specify the
>> > location of the BSF jar file. """
>> > This has been fixed in SVN, and will be in ant 1.7.1.
>> > You can use the nightly build at
>> > http://people.apache.org/builds/ant/nightly/
>> > Peter
>> >
>> >>
>> >>     <script language="beanshell">
>> >>         <classpath>
>> >>             <fileset
>> >> dir="/home/sfloess/development/jplate/environment/lib" includes="*.
>> >> jar" />
>> >>         </classpath>
>> >>         System.out.println("Hello world");
>> >>     </script>
>> >>
>> >> If I run Ant with "-lib
>> >> /home/sfloess/development/jplate/environment/lib" command line 
>> option, I
>> >> see the System.out.println() executed as I would expect.
>> >>
>> >> However, if I do not use the -lib option, I get:
>> >> "java.lang.NoClassDefFoundError:  org/apache/bsf/BSFException" 
>> error.  I
>> >> assumed the classpath element would take care of this...but to no 
>> avail.
>> >>
>> >> My lib dir contains bsf.jar and bsh-2.0b4.jar
>> >>
>> >> Again, if I use the -lib command line param everything works fine.
>> >>
>> >> Thanks ahead of time...
>> >>
>> >> Scot
>> >>
>> >> --
>> >> Scot P. Floess
>> >> 27 Lake Royale
>> >> Louisburg, NC  27549
>> >>
>> >> 252-478-8087 (Home)
>> >> 919-754-4592 (Work)
>> >>
>> >> Chief Architect JPlate  http://sourceforge.net/projects/jplate
>> >> Chief Architect JavaPIM http://sourceforge.net/projects/javapim
>> >>
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>> >> For additional commands, e-mail: user-help@ant.apache.org
>> >>
>> >>
>> >
>> > ---------------------------------------------------------------------
>> > To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
>> > For additional commands, e-mail: user-help@ant.apache.org
>> >
>> >
>>
>> -- 
>> Scot P. Floess
>> 27 Lake Royale
>> Louisburg, NC  27549
>>
>> 252-478-8087 (Home)
>> 919-754-4592 (Work)
>>
>> Chief Architect JPlate  http://sourceforge.net/projects/jplate
>> Chief Architect JavaPIM http://sourceforge.net/projects/javapim
>>
>>
>>
>

-- 
Scot P. Floess
27 Lake Royale
Louisburg, NC  27549

252-478-8087 (Home)
919-754-4592 (Work)

Chief Architect JPlate  http://sourceforge.net/projects/jplate
Chief Architect JavaPIM http://sourceforge.net/projects/javapim


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message