From: Srinivasa Rao Date: 2008-07-29T15:45:17+09:00 Subject: Re: Using Antwrap in Ruby Hi Caleb, Thank for your helpful suggestions. Installed rjb and antwrap successfully.Started working on antwrap. My code is below. ----------------- options = {:ant_home=>"D://apache-ant-1.7.1", :name=>'BotServer', :basedir=>"C://InstantRails-1.3a-with-PHP-5.1.4//InstantRails//rails_apps", :declarative=> true, :logger=> Logger.new(STDOUT), :loglevel=> Logger::DEBUG} puts "options------------------------------1" antProject = AntProject.new(options) antTask = AntTask.new('ws-run -DD=PRnnn', antProject, {:debug => 'on', :verbose => 'no', :fork => 'no'}) puts "before task------------------------------" antTask.execute() While running i am facing problems. ----------------------------------- -> up to options i was able to execute. -> then i am getting error in this below manner (debugger not at all excecute ant project code.) My varaiables shows this value for creating instance for AntProject -------------------------------------------------------------------- exception uninitialized constant TestRunsController::AntProject @blamed_files Empty Array md nil msg nil origin_file nil origin_line nil Here TestRunsController is my controller. Could you please help me in this regard. ----------------------------------------------------------------------- Caleb Powell wrote: > Hi Srinivasa, > > there are two distribution of Antwrap: > > - This first one is for C based Ruby interpreter (MRI). It has a > dependency on RJB (RubyJavaBridge), a gem that enables > you to load and instantiate Java Classes from within a ruby process. > Antwrap needs this to load and execute Ant tasks. > > - The second distro is meant to run on JRuby, and thus has no no > dependency on RJB because it can load Java classes via the > interpreter. > > When you install Antwrap, it will ask you to choose the distribution > with the choice of Ruby or Java. You have chosen the first option, and > the failure is occurring during the installation > of RJB. It is trying to compile it's classes using the gcc, but it is > having problems resolving the location of your JAVA_HOME (RJB needs to > link to some C libraries in the JVM). > This problem is probably due to the Cygwin paths. Try putting this > into your .bashrc or .bash_profile file: > > export JAVA_HOME=$(cygpath -ua $JAVA_HOME) > export PATH=$JAVA_HOME/bin:$PATH > > There are some other suggestions on how to solve this here: > > http://arton.no-ip.info/collabo/backyard/?HowToBuildRjb > > Let me know how this goes for you. > > On Wed, Jul 23, 2008 at 7:55 AM, Srinivasa Rao > wrote: >> $ gem install Antwrap-0.7.0.gem >> details. You may need configuration options. >> --srcdir=. >> >> gcc: FilesJavajdk1.5.0_11/include: No such file or directory >> >> >> >> Regards, >> M.SrinivasaRao. >> -- >> Posted via http://www.ruby-forum.com/. >> >> > > > > -- > Caleb > > "I do not know which makes a man more conservative—to know nothing but > the present, or nothing but the past." > - John Maynard Keynes -- Posted via http://www.ruby-forum.com/.