I wanted know that can i create an Install Shield using Ant, suppose to install an application you get setup.exe file for windows rpm files for Linux, so i want to create an install shield wizard for my java application in which i had to check that whether the user got the desired jre which the application requried, conditions are like this 1)Check whether the m/c got jre if not then i have to install the jre 2)Check whether the m/c got jre but of lower version then i have to install the jre on which my aplication runs, but the older version shouldt be effected. and so on
Pritesh Saharey BE(Mech) Software Engineer --- Ivan Ivanov <[EMAIL PROTECTED]> wrote: Pritesh, Can you explain what exactly you want to install? I have made some successfull attempts to use Ant as an installer of web applications. I did roughly the following: 1) Install a database (MySQL in most cases) 2) Start it as a service(on Win), as a daemon (on Linux) 3) Using <sql> task, initialize the database of your application 4) Install Tomcat (easy if you use a zip archive) using unzip task abd start it as a service(on Win), as a daemon (on Linux) 5) Copy the war of your web in tomcat's webapp dir and wait to be deployed. I usually control the folders where the pieces of sofware will be installed by using properties file. There is also an <input> task that can read user input, but I have never used it. As for platform independence (or how to reach the unreachable :)) ), I have never succeded in it 100%. Let's take as an example Tomcat. Under Linux it is easy to unzip it somewhere, then prepare some sh file and copy them in /etc/rc.d so that the tomcat is started as a daemon. But I have never found a way how to install it easy as a service under Windows. (I know there is jakarta installer of tomcat that do this but in this way I have to use different tomcat bundles - jakarta-tomcat.zip for linux and jakarta-tomcat.exe for Windows). So my rule is: try hard to perform as many installation steps from ant (which means platform independence), for the rest steps do the manually or write some platform dependent files say bat or sh. Hope this helps Ivan Ivanov P.S. Well, I lied a little bit, since there is a condition in ant called os, with which one can guess the platform on which the installation is running. After finding it one can invoke different targets. For example: <condition property="isLinux"> <os family="linux"/> </condition> <condition property="isWindows"> <os family="windows"/> </condition> <target name="install" depends="lin-install, win-install"> ...Do your common install steps here </target> <target name="win-install" if="isWindows"> ...Do your windows specific install steps here </target> <target name="lin-install" if="isLinux"> ...Do your linux specific install steps here </target> But is this platform independence we all looking for? --- Pritesh saharey <[EMAIL PROTECTED]> wrote: > I would like to know can i create an installer for > my java application using ant both for Windows and > Linux. > > > > Pritesh Saharey > BE(Mech) > Software Engineer > > > _____________________________________________________________ > Join SQAtester.com Community ---> > http://www.sqatester.com/testersarea/joinus.htm > > --------------------------------------------------------------------- > To unsubscribe, e-mail: > [EMAIL PROTECTED] > For additional commands, e-mail: > [EMAIL PROTECTED] > __________________________________ Do you Yahoo!? Yahoo! Finance Tax Center - File online. File on time. http://taxes.yahoo.com/filing.html --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] _____________________________________________________________ Join SQAtester.com Community ---> http://www.sqatester.com/testersarea/joinus.htm --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]