Hi,

I've used the following Ant targets for build scripts that required
platform dependent work. In the example here, the property
"catalina.home" is set according to what platform we're running on. You
can adapt as needed.

  <target name="platform" description="Sets properties based on
platform">
    <condition property="isWin32">
      <os family="windows" />
    </condition>
    <condition property="isUnix">
      <os family="unix" />
    </condition>
  </target>

  <target name="win32" depends="platform" if="isWin32"
    description="Sets properties for Win32">
    <echo message="Looks like we're on Win32" />
    <property name="catalina.home" value="C:\Program Files\Apache
Group\Tomcat 5.0" />
  </target>

  <target name="unix" depends="platform" if="isUnix"
    description="Sets properties for Unix">
    <echo message="Looks like we're on Unix" />
    <property name="catalina.home" value="/usr/local/tomcat" />
  </target>




>>> "Karthik N S" <[EMAIL PROTECTED]> 09/13/04 10:34PM >>>
Hi

      Erik


   1) Using Ant and Build.xml I want to run the
org.apache.lucene.demo.IndexFiles to create an Indexfolder

   2) Problem is The same Build.xml is to be used Across the O/s for
creating Index

   3) The path of Lucene1-4-final.jar  are in respective directories
for the
O/s...

        [ Note :- The Path of Lucene_home,I/P and O/p directories are
also
O/s Specific should be in the Build.xml  and
                        should be trigged somthing   by this type


                             <condition property="isWindows">
                                  <os family="windows" />
                              </condition>

                                           or

                            <condition property="isUnix">
                                  <os family="unix" />
                            </condition>


    I hope u get the situation............. :{


With regards
Karthik



-----Original Message-----
From: Erik Hatcher [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, September 14, 2004 7:37 PM
To: Lucene Users List
Subject: Re: ANT +BUILD + LUCENE


I'm not following what you want very clearly, but there is an <index>
task in Lucene's Sandbox.

Please post what you are trying, and I'd be happy to help once I see
the details.

        Erik

On Sep 12, 2004, at 4:44 PM, Karthik N S wrote:

> Hi
>
> Guys
>
>
> Apologies..........
>
>
> The Task for me is to build the Index folder using Lucene &  a
simple
> Build.xml  for ANT
>
> The Problem ...... Same 'Build .xml'  should be used for differnet
> O/s...
> [ Win / Linux ]
>
> The glitch is  respective jar files such as Lucene-1.4 .jar & other
jar
> files are not in same dir for the O/s.
> Also the  I/p , O/p Indexer path for source/target may also vary.
>
>
> Please Somebody Help me..... :(
>
>
>
> with regards
> Karthik
>
>
>
>
>       WITH WARM REGARDS
>       HAVE A NICE DAY
>       [ N.S.KARTHIK]
>
>
>
>
>
---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED] 
> For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED] 
For additional commands, e-mail: [EMAIL PROTECTED] 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to