|Hi Feng Wang,
Could you tell us whether you have ever successfully installed GS3 on a
local Linux machine? Was it Ubuntu? Did you encounter such a problem then?
Does your local installation use Ant 1.5 or 1.6.*? It may help with
diagnosing the problem if we know what factors we could rule out. For
example, in comparison to my situation, you're trying to install GS3:
1. remotely (ssh) vs my local installation
2. Linux Ubuntu server vs my Linux Fedora with default Apache tomcat
server that came with Greenstone
3. using Apache Ant 1.5 vs 1.6.5 or 1.6.* on my machine
It could be any of those factors or a combination thereof and that makes
it hard for us to tell from here.
I've just talked to Oran Fry who knows about Apache Ant and its build.xml
files and he came up with the following suggestion.
Since your situation involves Apache Ant 1.5, it may be that it requires a
<target name="some-target-name">...</target> nested around conditions. In
the build.xml file of GS3.03 that you have the conditions are not inside
targets but are directly inside the <project> tag.
message "Problem with condition task" and its responses for someone who
encountered "unexpected element condition" using Apache Ant 1.5 - it
turned out to be a syntax error in their build.xml. Similarly, it may be a
sort of syntax error for 1.5 if conditions are not nested inside target
tags, we don't know but Oran thinks it is worth considering.)
Therefore, Oran thought it may help in solving or at least narrowing down
the cause of the problem you're facing if you could try the following:
1. Make a copy of your build.xml file and rename it to something else.
2. Edit the particular build.xml file you have (the version is at
that lines 28-288 are nested inside a target tag as follows:
3. Now try to compile Greenstone again.
How did it go?
Alternatively, maybe you can want to try out the simple test Ant script at
and see if it works for you with the Ant 1.5 set-up, or whether the
"unexpected element condition" appears then as well. This script doesn't
have condition tags nested inside target tags either.
> Hi Oran Fry.
> Thanks for your mail.
> I checked the version of the Apache Ant in our Server is 1.5. It's not the
> current version, but i don't think it's too old to build the source code.
> I need the advices from you, pls help me!
> Feng Wang
> -------- Original-Nachricht --------
>> Datum: Thu, 03 Apr 2008 12:07:57 +1300
>> Von: Oran Fry of Greenstone Team <firstname.lastname@example.org>
>> An: feng wang <email@example.com>,
>> Betreff: Re: [greenstone-users] Installing the GSDL remote by using the
>> Hi feng wang,
>> What version of ant are you using? Check with 'ant -version'. Maybe your
>> ant is too old to recognise the condition element, or to accept it as a
>> root element, or something along those lines.
>> Also, how current is your source code? How recently did you check it
>> Kind Regards,
>> Oran Fry.
>> feng wang wrote:
>> > Hi Everyone,
>> > I tried to install the GSDL 3 in our Linux Ubuntu Server as a normal
>> > I used the SSH with Ant Command to install the Software from the
>> because i called the server remote.
>> > But i got still the Exception:
>> > file:/home/fwang/Source/GSDL/greenstone-3.03/build.xml:94: Unexpected
>> element "condition"
>> > Can someone give some advices? I need the help!
>> > Regards
>> > Feng Wang
>> > ------------------------------------------------------------------------
>> > _______________________________________________
>> > greenstone-users mailing list
>> > firstname.lastname@example.org
>> > https://list.scms.waikato.ac.nz/mailman/listinfo/greenstone-users
> GMX startet ShortView.de. Hier findest Du Leute mit Deinen Interessen!
> Jetzt dabei sein: http://www.shortview.de/?mc=sv_ext_mf@gmx
> greenstone-users mailing list