[Java lista] Egy NB6.8-as buildAll script keszitese
Verhás István
istvan at verhas.com
2010. Már. 26., P, 12:01:48 CET
maven? :)
üdv
vi
Szomor Attila wrote:
> Sziasztok,
>
> Az eddig NBv6.7/GFv2/ELv1.2-ben elkészült pilot projektünket átportoltam
> NBv6.8/GFv3/ELv2-re. Tulajdonképpen a forrásokhoz nem kellet hozzányúlni,
> csak a környezetet kellett átállítani, ez a GF fórumon kapott instrukciók
> alapján sikerült is.
> Most mindent lebírok az NB6.8 alól build-elni és a három EAR-nek a GFV3
> alá a deploy-a is működik, a klienst is tudom futtani tehát boldognak
> kellene lennem. Sajnos azonban ez nem így van, mert elakartam készíteni a
> szokásos "buildAll"-t, hogy a többieknek ne kelljen manuálisan végig menni
> a 22 JAR és 3 EAR összetevőn és kiadni a BUILD-et egy DEPLOY előtt. Ezt
> már az előző NB6.7 alatt is így csináltuk, abban nem volt még EAR, mert a
> GFv2 alá az EJB-ket önállóan is lehetett deploy-olni, a GFv3 alá azonban
> csak applikációkat (EAR) lehet már telepíteni (nagyon helyes ez így, ne
> libegjen egy EJB csak úgy a GF-ben).
> Röviden összefoglalva a 19 normál JAR és a 3 EJB-s JAR behelyezése a
> buildAll-ba nem okozott gondot, mert az NB6.7 alatti trunk/build.xml-t egy
> az egyben feltudta használni a NB6.8, ezt akartam bővíteni a három EAR
> build-al, sajnos azonban az ANT egy "src.dir" empty hibával leáll.
> A build.xml vége:
> -----------------
> <target name="clean">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="clean"/>
> <param name="ejb.target" value="clean"/>
> <param name="cli.target" value="clean"/>
> <param name="ear.target" value="init"/>
> </antcall>
> </target>
> <target name="build">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="compile"/>
> <param name="ejb.target" value="compile"/>
> <param name="cli.target" value="compile"/>
> <param name="ear.target" value="init"/>
> </antcall>
> </target>
> <target name="dist">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="jar"/>
> <param name="ejb.target" value="dist"/>
> <param name="cli.target" value="dist"/>
> <param name="ear.target" value="init"/>
> </antcall>
> </target>
> <target name="default">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="default"/>
> <param name="ejb.target" value="default"/>
> <param name="cli.target" value="default"/>
> <param name="ear.target" value="default"/>
> </antcall>
> </target>
> most az "ear.target"-hez "init" paramétert adtam meg az ANT-nak, mert az
> nem okoz hibát!
> Azonban sorban "clean", "compile" és "dist" paraméter kellene az ANT-nak,
> hogy a megfelelő alkönyvtárban találahtó igazi build.xml-t meghívva
> létrejöjjenek az EAR-ok, de ekkor jön az "empty src.dir" hiba, ami az NB
> alól manuálisan meghívott BUILD esetén nem jön!
>
> Tud esetleg valaki segíteni, előre is köszi, Attila.
>
>
>
> A projekt felépítése:
> =====================
> (buildAll)java/projects/ctmedika/trunk
> --------------------------------------
> build.xml
> ctAllPurposeConsts
> ctAllPurposeResources
> ctAllPurposeTypes
> ctAllPurposeUtils
> ctAllPurposeZeallyForms
> ctMedikaConsts
> ctMedikaDatabase
> ctMedikaLogicalUnit
> ctMedikaSwingAppClient
> nbproject
> src
> (EAR)java/projects/ctmedika/trunk/ctMedikaDatabase
> --------------------------------------------------
> build.xml
> ctMedikaDbPersistenceConsts
> ctMedikaDbPersistenceEntities
> ctMedikaDbPersistenceEntityClients
> ctMedikaDbPersistenceUnit
> ctMedikaDbTransferConsts
> ctMedikaDbTransferObject
> ctMedikaDbTransferObjectAssembler
> ctMedikaDbTransferObjectClients
> ctMedikaDbTransferObjectUnit
> nbproject
> src
> (EAR)java/projects/ctmedika/trunk/ctMedikaLogicalUnit
> -----------------------------------------------------
> build.xml
> ctMedikaLUnitUserAuthorization
> ctMedikaLUnitUserAuthorizationClients
> ctMedikaLUnitUserAuthorizationUnit
> ctMedikaLUnitVerb
> ctMedikaLUnitVerbClients
> ctMedikaLUnitVerbUnit
> nbproject
> src
> (EAR)java/projects/ctmedika/trunk/ctMedikaSwingAppClient
> --------------------------------------------------------
> build.xml
> ctMedikaSwingClient
> nbproject
> src
>
> A buildAll-os build.xml
> -----------------------
> <?xml version="1.0" encoding="UTF-8"?>
> <!-- You may freely edit this file. See commented blocks below for -->
> <!-- some examples of how to customize the build. -->
> <!-- (If you delete it and reopen the project it will be recreated.) -->
> <!-- By default, only the Clean and Build commands use this build script.
> -->
> <!-- Commands such as Run, Debug, and Test only use this build script if
> -->
> <!-- the Compile on Save feature is turned off for the project. -->
> <!-- You can turn off the Compile on Save (or Deploy on Save) setting -->
> <!-- in the project's Project Properties dialog box.-->
> <project name="buildAll" default="default" basedir="."
> xmlns:ear="http://www.netbeans.org/ns/j2ee-earproject/2">
> <description>Builds the project ctMedikaApplication.</description>
> <target name="init" description="Initialise build parameters">
> <property name="project.ctAllPurposeConsts"
> location="ctAllPurposeConsts"/>
> <property name="project.ctAllPurposeResources"
> location="ctAllPurposeResources"/>
> <property name="project.ctAllPurposeTypes"
> location="ctAllPurposeTypes"/>
> <property name="project.ctAllPurposeUtils"
> location="ctAllPurposeUtils"/>
> <property name="project.ctAllPurposeZeallyForms"
> location="ctAllPurposeZeallyForms"/>
> <property name="project.ctMedikaConsts" location="ctMedikaConsts"/>
> <property name="project.ctMedikaDbPersistenceConsts"
> location="ctMedikaDatabase/ctMedikaDbPersistenceConsts"/>
> <property name="project.ctMedikaDbPersistenceEntities"
> location="ctMedikaDatabase/ctMedikaDbPersistenceEntities"/>
> <property name="project.ctMedikaDbPersistenceEntityClients"
> location="ctMedikaDatabase/ctMedikaDbPersistenceEntityClients"/>
> <property name="project.ctMedikaDbPersistenceUnit"
> location="ctMedikaDatabase/ctMedikaDbPersistenceUnit"/>
> <property name="project.ctMedikaDbTransferObject"
> location="ctMedikaDatabase/ctMedikaDbTransferObject"/>
> <property name="project.ctMedikaDbTransferConsts"
> location="ctMedikaDatabase/ctMedikaDbTransferConsts"/>
> <property name="project.ctMedikaDbTransferObjectAssembler"
> location="ctMedikaDatabase/ctMedikaDbTransferObjectAssembler"/>
> <property name="project.ctMedikaDbTransferObjectClients"
> location="ctMedikaDatabase/ctMedikaDbTransferObjectClients"/>
> <property name="project.ctMedikaDbTransferObjectUnit"
> location="ctMedikaDatabase/ctMedikaDbTransferObjectUnit"/>
> <property name="project.ctMedikaLUnitUserAuthorization"
> location="ctMedikaLogicalUnit/ctMedikaLUnitUserAuthorization"/>
> <property name="project.ctMedikaLUnitUserAuthorizationClients"
> location="ctMedikaLogicalUnit/ctMedikaLUnitUserAuthorizationClients"/>
> <property name="project.ctMedikaLUnitUserAuthorizationUnit"
> location="ctMedikaLogicalUnit/ctMedikaLUnitUserAuthorizationUnit"/>
> <property name="project.ctMedikaLUnitVerb"
> location="ctMedikaLogicalUnit/ctMedikaLUnitVerb"/>
> <property name="project.ctMedikaLUnitVerbClients"
> location="ctMedikaLogicalUnit/ctMedikaLUnitVerbClients"/>
> <property name="project.ctMedikaLUnitVerbUnit"
> location="ctMedikaLogicalUnit/ctMedikaLUnitVerbUnit"/>
> <property name="project.ctMedikaSwingClient"
> location="ctMedikaSwingAppClient/ctMedikaSwingClient"/>
> <property name="project.ctMedikaDatabase"
> location="ctMedikaDatabase"/>
> </target>
> <target depends="init" name="ctAllPurposeConsts">
> <ant antfile="${project.ctAllPurposeConsts}/build.xml"
> dir="${project.ctAllPurposeConsts}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctAllPurposeConsts" name="ctAllPurposeResources">
> <ant antfile="${project.ctAllPurposeResources}/build.xml"
> dir="${project.ctAllPurposeResources}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctAllPurposeResources" name="ctAllPurposeTypes">
> <ant antfile="${project.ctAllPurposeTypes}/build.xml"
> dir="${project.ctAllPurposeTypes}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctAllPurposeTypes" name="ctAllPurposeUtils">
> <ant antfile="${project.ctAllPurposeUtils}/build.xml"
> dir="${project.ctAllPurposeUtils}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctAllPurposeUtils" name="ctAllPurposeZeallyForms">
> <ant antfile="${project.ctAllPurposeZeallyForms}/build.xml"
> dir="${project.ctAllPurposeZeallyForms}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctAllPurposeZeallyForms" name="ctMedikaConsts">
> <ant antfile="${project.ctMedikaConsts}/build.xml"
> dir="${project.ctMedikaConsts}" inheritall="false" target="${lib.target}"/>
> </target>
> <target depends="ctMedikaConsts" name="ctMedikaDbPersistenceConsts">
> <ant antfile="${project.ctMedikaDbPersistenceConsts}/build.xml"
> dir="${project.ctMedikaDbPersistenceConsts}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaDbPersistenceConsts"
> name="ctMedikaDbPersistenceEntities">
> <ant antfile="${project.ctMedikaDbPersistenceEntities}/build.xml"
> dir="${project.ctMedikaDbPersistenceEntities}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaDbPersistenceEntities"
> name="ctMedikaDbPersistenceEntityClients">
> <ant
> antfile="${project.ctMedikaDbPersistenceEntityClients}/build.xml"
> dir="${project.ctMedikaDbPersistenceEntityClients}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaDbPersistenceEntityClients"
> name="ctMedikaDbPersistenceUnit">
> <ant antfile="${project.ctMedikaDbPersistenceUnit}/build.xml"
> dir="${project.ctMedikaDbPersistenceUnit}" inheritall="false"
> target="${ejb.target}"/>
> </target>
> <target depends="ctMedikaDbPersistenceUnit"
> name="ctMedikaDbTransferObject">
> <ant antfile="${project.ctMedikaDbTransferObject}/build.xml"
> dir="${project.ctMedikaDbTransferObject}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaDbTransferObject"
> name="ctMedikaDbTransferConsts">
> <ant antfile="${project.ctMedikaDbTransferConsts}/build.xml"
> dir="${project.ctMedikaDbTransferConsts}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaDbTransferConsts"
> name="ctMedikaDbTransferObjectAssembler">
> <ant
> antfile="${project.ctMedikaDbTransferObjectAssembler}/build.xml"
> dir="${project.ctMedikaDbTransferObjectAssembler}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaDbTransferObjectAssembler"
> name="ctMedikaDbTransferObjectClients">
> <ant
> antfile="${project.ctMedikaDbTransferObjectClients}/build.xml"
> dir="${project.ctMedikaDbTransferObjectClients}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaDbTransferObjectClients"
> name="ctMedikaDbTransferObjectUnit">
> <ant antfile="${project.ctMedikaDbTransferObjectUnit}/build.xml"
> dir="${project.ctMedikaDbTransferObjectUnit}" inheritall="false"
> target="${ejb.target}"/>
> </target>
> <target depends="ctMedikaDbTransferObjectUnit"
> name="ctMedikaLUnitUserAuthorization">
> <ant antfile="${project.ctMedikaLUnitUserAuthorization}/build.xml"
> dir="${project.ctMedikaLUnitUserAuthorization}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaLUnitUserAuthorization"
> name="ctMedikaLUnitUserAuthorizationClients">
> <ant
> antfile="${project.ctMedikaLUnitUserAuthorizationClients}/build.xml"
> dir="${project.ctMedikaLUnitUserAuthorizationClients}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaLUnitUserAuthorizationClients"
> name="ctMedikaLUnitUserAuthorizationUnit">
> <ant
> antfile="${project.ctMedikaLUnitUserAuthorizationUnit}/build.xml"
> dir="${project.ctMedikaLUnitUserAuthorizationUnit}" inheritall="false"
> target="${ejb.target}"/>
> </target>
> <target depends="ctMedikaLUnitUserAuthorizationUnit"
> name="ctMedikaLUnitVerb">
> <ant antfile="${project.ctMedikaLUnitVerb}/build.xml"
> dir="${project.ctMedikaLUnitVerb}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaLUnitVerb" name="ctMedikaLUnitVerbClients">
> <ant antfile="${project.ctMedikaLUnitVerbClients}/build.xml"
> dir="${project.ctMedikaLUnitVerbClients}" inheritall="false"
> target="${lib.target}"/>
> </target>
> <target depends="ctMedikaLUnitVerbClients"
> name="ctMedikaLUnitVerbUnit">
> <ant antfile="${project.ctMedikaLUnitVerbUnit}/build.xml"
> dir="${project.ctMedikaLUnitVerbUnit}" inheritall="false"
> target="${ejb.target}"/>
> </target>
> <target depends="ctMedikaLUnitVerbUnit" name="ctMedikaSwingClient">
> <ant antfile="${project.ctMedikaSwingClient}/build.xml"
> dir="${project.ctMedikaSwingClient}" inheritall="false"
> target="${cli.target}"/>
> </target>
> <target depends="ctMedikaSwingClient" name="ctMedikaDatabase">
> <ant antfile="${project.ctMedikaDatabase}/build.xml"
> dir="${project.ctMedikaDatabase}" inheritall="false"
> target="${ear.target}"/>
> </target>
> <target name="clean">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="clean"/>
> <param name="ejb.target" value="clean"/>
> <param name="cli.target" value="clean"/>
> <param name="ear.target" value="init"/>
> </antcall>
> </target>
> <target name="build">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="compile"/>
> <param name="ejb.target" value="compile"/>
> <param name="cli.target" value="compile"/>
> <param name="ear.target" value="init"/>
> </antcall>
> </target>
> <target name="dist">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="jar"/>
> <param name="ejb.target" value="dist"/>
> <param name="cli.target" value="dist"/>
> <param name="ear.target" value="init"/>
> </antcall>
> </target>
> <target name="default">
> <antcall target="ctMedikaDatabase">
> <param name="lib.target" value="default"/>
> <param name="ejb.target" value="default"/>
> <param name="cli.target" value="default"/>
> <param name="ear.target" value="default"/>
> </antcall>
> </target>
> </project>
>
>
>
>
További információk a(z) Javalist levelezőlistáról