Bonjour,
J'ai 4 projets j2ee sous Eclipse ayant chacun leur fichier build.xml, j'ai créé un 5ème projet destiné à contenir un 5ème fichier build.xml que j'ai nommé buildGlobal.xml.
Comment faire pour lancer les 4 build.xml à partir de buildGlobal.xml ?
voici le contenu de buildGlobal.xml :
voici celui de build.xml du projet n°1 (et ça plante là déjà) :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9 <project name="Global" default="all" basedir=".."> <target name="all"> <ant dir="projet1/ant" antfile="build.xml"/> <ant dir="projet2/ant" antfile="build.xml"/> <ant dir="projet3/ant" antfile="build.xml"/> <ant dir="projet4/ant" antfile="build.xml"/> </target> </project>
voici la sortie sur la console quand j'exécute buildGlobal.xml :
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22 <project name="projet1" default="packTheme" basedir=".."> <property name="themejarname" value="millstone-web-themes-3.1.0.jar"/> <property name="themesdir" value="${basedir}/themes"/> <target name="packTheme" depends="cleanTheme" description="génère le jar theme"> <jar jarfile="${basedir}/lib/${themejarname}" basedir="${themesdir}/"> <manifest> <attribute name="Built-By" value="phoebe"/> <section name="org/millstone/webadapter/themes"> <attribute name="Version" value="3.1.0"/> </section> </manifest> </jar> </target> <target name="cleanTheme" description="nettoie le jar theme" > <delete file="${basedir}/lib/${themejarname}"/> </target> </project>
Je précise que si je lance les 4 build.xml indépendament, ça fonctionne très bien, en fait il ne va pas chercher le répertoire themes/ au bon endroit
Code : Sélectionner tout - Visualiser dans une fenêtre à part
1
2
3
4
5
6
7
8 Buildfile: C:\eclipse\workspace\projetGlobal\buildGlobal.xml cleanTheme: packTheme: BUILD FAILED C:\eclipse\workspace\projetGlobal\buildGlobal.xml:3: The following error occurred while executing this line: C:\eclipse\workspace\projet1\ant\build.xml:5: C:\eclipse\workspace\projet1\ant\themes not found.
voici l'architecture de mon workspace Eclipse :
Partager