You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cocoon.apache.org by Niclas Hedhman <ni...@localbar.com> on 2000/03/26 12:17:29 UTC

Bug reports...

Building;

Problem 1.
--------
build.sh and build.bat should have xml.jar in classpath for Ant to work.
And since Cocoon2 is more or less Java2 by now,
I suggest the following start of Ant is used instead;

$JAVA_HOME/bin/java -Dant.home=$ANT_HOME
-Djava.ext.dirs=./lib:$JAVA_HOME/jre/lib/ext org.apache.tools.ant.Main
$*

which will automatically use all the JARs in the lib directory.


Problem 2.
-------
BUILD CONFIG ERROR: Configuration property "classname" does not have a
setMethod in class org.apache.tools.ant.taskdefs.Java
org.apache.tools.ant.BuildException: Configuration property "classname"
does not have a setMethod in class org.apache.tools.ant.taskdefs.Java
        at
org.apache.tools.ant.ProjectHelper.configureTask(ProjectHelper.java:296)

        at
org.apache.tools.ant.ProjectHelper.configureTasks(ProjectHelper.java:228)

        at
org.apache.tools.ant.ProjectHelper.configureTargets(ProjectHelper.java:195)

        at
org.apache.tools.ant.ProjectHelper.configureProject(ProjectHelper.java:128)

        at org.apache.tools.ant.Main.runBuild(Main.java:222)
        at org.apache.tools.ant.Main.main(Main.java:191)

Probably due to an old ANT version. Where can an appropriate one be
found?
http://jakarta.apache.org/builds/tomcat/nightly/ant.zip
and all the other ant*.zip are all 0k in size.

http://jakarta.apache.org/builds/tomcat/release/v3.0/
is empty. Confusiom reigns!!


Problem 3;
--------
Compile problems in DOMBuilder and DOMStreamer.  Giacomo just brought it
up...

My Solution; Get the Recommendation from W3C at;
http://www.w3.org/TR/2000/CR-DOM-Level-2-20000307/java-binding.zip
and unzip them into the source directory and compile with them.
I have xerces.jar (CVS), xalan_0_20_0.jar (release) and sax.jar (w/
Cocoon2) in the lib directory, and they are in the classpath of JAVAC.

The adventure continues later...

Niclas


Re: Bug reports...

Posted by Niclas Hedhman <ni...@localbar.com>.
More Linux related problems...

The AntRun shell script also is lacking the +x flag.

chmod +x lib/bin/AntRun


Niclas


Re: Bug reports...

Posted by Stefano Mazzocchi <st...@apache.org>.
Niclas Hedhman wrote:
> 
> Stefano Mazzocchi wrote:
> 
> > Let's keep things simple. if your java_home is not set, you have to set
> > it. Simple enough.
> >
> > Good guesses don't help... either you do autoconf stuff or nothing.
> >
> > BTW, you should set your java_home environment anyway for good behavior
> > (otherwise, how do you change JVM while you go?)
> 
> Ah Ha!! A handicapped Windows user speaking...

admittedly so :)
 
> We have (and you don't) something called symbolic links, meaning we can create a
> reference to another file or directory (or device, process and so forth). This works
> at file system level, and not the dinky toy of Links in Windows Explorer. And this
> can be cascaded, so

look, I'm not _that_ handicapped :) I have my linux box right here side
by side with my windosh box.
 
> ln -s /java/sun/jdk1.2.2  /java/jdk1.2
> ln -s /java/jdk/1.2 /java/jdk
> 
> creates a reference chain of
> 
> /java/jdk  ->  /java/jdk1.2  ->  /java/sun/jdk1.2.2-final
> 
> So, assuming I want to change from Sun's to Blackdown's implementation in
> /java/blackdown/jdk1.2.2-rc3, I do
> 
> rm /java/jdk1.2    #Remove existing link
> ln -s /java/blackdown/jdk1.2.2-rc3  /java/jdk1.2 #Create new link
> 
> Nothing else...

I do that myself.
 
> I disagree that Environment variables are a good way to go on Linux.
> a)  A lot of people have no idea how to set them permanently
> b)  Setting them permanently is different on different distrubtions on Linux.
> c)  There are different ways for users and all_users.
> d)  Which does not include processes started at boot time, such as JServ.

good points. still I like more

build.sh --java-home=/usr/local/java/jdk 

than heuristics scripts.
 
> I think many (most?) Linux users agrees with me. (But I may also be completely
> wrong).
> 
> Niclas


-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<st...@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------
 Missed us in Orlando? Make it up with ApacheCON Europe in London!
------------------------- http://ApacheCon.Com ---------------------



Re: Bug reports...

Posted by Niclas Hedhman <ni...@localbar.com>.
Stefano Mazzocchi wrote:

> Let's keep things simple. if your java_home is not set, you have to set
> it. Simple enough.
>
> Good guesses don't help... either you do autoconf stuff or nothing.
>
> BTW, you should set your java_home environment anyway for good behavior
> (otherwise, how do you change JVM while you go?)

Ah Ha!! A handicapped Windows user speaking...

We have (and you don't) something called symbolic links, meaning we can create a
reference to another file or directory (or device, process and so forth). This works
at file system level, and not the dinky toy of Links in Windows Explorer. And this
can be cascaded, so

ln -s /java/sun/jdk1.2.2  /java/jdk1.2
ln -s /java/jdk/1.2 /java/jdk

creates a reference chain of

/java/jdk  ->  /java/jdk1.2  ->  /java/sun/jdk1.2.2-final

So, assuming I want to change from Sun's to Blackdown's implementation in
/java/blackdown/jdk1.2.2-rc3, I do

rm /java/jdk1.2    #Remove existing link
ln -s /java/blackdown/jdk1.2.2-rc3  /java/jdk1.2 #Create new link

Nothing else...

I disagree that Environment variables are a good way to go on Linux.
a)  A lot of people have no idea how to set them permanently
b)  Setting them permanently is different on different distrubtions on Linux.
c)  There are different ways for users and all_users.
d)  Which does not include processes started at boot time, such as JServ.

I think many (most?) Linux users agrees with me. (But I may also be completely
wrong).


Niclas


RE: Bug reports...

Posted by Donald Ball <ba...@webslingerZ.com>.
On Wed, 29 Mar 2000, Gerard van Enk wrote:

> > On Mon, 27 Mar 2000, Stefano Mazzocchi wrote:
> >
> > > Niclas Hedhman wrote:
> > >
> > > > > > The adventure continues later...
> > > >
> > > > build.sh is lacking the Execute flag.
> > > > chmod +x build.sh
> > > > is required, unless one want to start by
> > > > sh build.sh which is a real drag...
> > >
> > > I have no idea on how to do "chmod +x build.sh" on the CVS from windows.
> > >
> > > Donald, Ricardo... could you take a look at this please?
> >
> > Hmm. I just chmoded the files on my box and ran cvs commit and nothing
> > happened. I'm sure there's some way to do it, but cvs is beyond my area of
> > expertise.
> 
> The only solution I know of is do a chmod+x on the file in the repository on
> the server (on the build.sh,v file)........But maybe there's a better
> solution???

That would work, but the files aren't all group writable... pier, can you
chmod -R g+w /home/cvs/xml-cocoon?

- donald


RE: Bug reports...

Posted by Gerard van Enk <ge...@eo.nl>.
> On Mon, 27 Mar 2000, Stefano Mazzocchi wrote:
>
> > Niclas Hedhman wrote:
> >
> > > > > The adventure continues later...
> > >
> > > build.sh is lacking the Execute flag.
> > > chmod +x build.sh
> > > is required, unless one want to start by
> > > sh build.sh which is a real drag...
> >
> > I have no idea on how to do "chmod +x build.sh" on the CVS from windows.
> >
> > Donald, Ricardo... could you take a look at this please?
>
> Hmm. I just chmoded the files on my box and ran cvs commit and nothing
> happened. I'm sure there's some way to do it, but cvs is beyond my area of
> expertise.

The only solution I know of is do a chmod+x on the file in the repository on
the server (on the build.sh,v file)........But maybe there's a better
solution???

Gerard


Re: Bug reports...

Posted by Donald Ball <ba...@webslingerZ.com>.
On Mon, 27 Mar 2000, Stefano Mazzocchi wrote:

> Niclas Hedhman wrote:
> 
> > > > The adventure continues later...
> > 
> > build.sh is lacking the Execute flag.
> > chmod +x build.sh
> > is required, unless one want to start by
> > sh build.sh which is a real drag...
> 
> I have no idea on how to do "chmod +x build.sh" on the CVS from windows.
> 
> Donald, Ricardo... could you take a look at this please?

Hmm. I just chmoded the files on my box and ran cvs commit and nothing
happened. I'm sure there's some way to do it, but cvs is beyond my area of
expertise.

> BTW, you should set your java_home environment anyway for good behavior
> (otherwise, how do you change JVM while you go?)

uh, by changing filesystem symlinks... much easier than env variables.

- donald


Re: Bug reports...

Posted by Stefano Mazzocchi <st...@apache.org>.
Niclas Hedhman wrote:

> > > The adventure continues later...
> 
> build.sh is lacking the Execute flag.
> chmod +x build.sh
> is required, unless one want to start by
> sh build.sh which is a real drag...

I have no idea on how to do "chmod +x build.sh" on the CVS from windows.

Donald, Ricardo... could you take a look at this please?

> I have also attached a more advanced script that will make an attemp to find a
> JDK if JAVA_HOME is not set. The directories to look in should perhaps be
> evaluated by a query among Linux users of where they place the JDK. I have just
> made some qualified guesses.
> Unfortunately I don't have the knowledge of how to do this on a Windows system
> (if it is at all possible), sorry...

Let's keep things simple. if your java_home is not set, you have to set
it. Simple enough.
 
Good guesses don't help... either you do autoconf stuff or nothing.

BTW, you should set your java_home environment anyway for good behavior
(otherwise, how do you change JVM while you go?)

-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<st...@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------
 Missed us in Orlando? Make it up with ApacheCON Europe in London!
------------------------- http://ApacheCon.Com ---------------------



Re: Bug reports...

Posted by Niclas Hedhman <ni...@localbar.com>.
Regarding the +x flag for build.sh and AntRun....

It is only the case in CVS, not in the distribution build.

Niclas

Niclas Hedhman wrote:

> build.sh is lacking the Execute flag.
> chmod +x build.sh
> is required, unless one want to start by
> sh build.sh which is a real drag...
>


Re: Bug reports...

Posted by Niclas Hedhman <ni...@localbar.com>.
Ross Burton wrote:

> /opt/JDK-1.2.2-final
> /opt/JDK-1.2  -> JDK-1.2.2.-final
> /opt/JDK  -> JDK-1.2

I expect that people are using symbolic links in a way that you are trying to
show.
Is it fair to expect that the top-most link would be;
*/jdk
or as you suggest
*/JDK

Then the second sub-issue would be where do they end up;
/
/opt
/usr/local
/usr/share
/java

Anybody has other positions.

>
>
> (excuse: it's easy to install a new JVM and realise its broken and go back,
> or if it works remove the old one, or run two at different times)
>
> I think you should add uppercase JDK paths to the search list.

Uppercase???
The default packaging on all JVMs I have seen is in lowercase.


Niclas


Re: Bug reports...

Posted by Ross Burton <ro...@mail.com>.
> I have also attached a more advanced script that will make an attemp to
find a
> JDK if JAVA_HOME is not set. The directories to look in should perhaps be
> evaluated by a query among Linux users of where they place the JDK. I have
just
> made some qualified guesses.

A I strange in having the following structure?

/opt/JDK-1.2.2-final
/opt/JDK-1.2  -> JDK-1.2.2.-final
/opt/JDK  -> JDK-1.2

(excuse: it's easy to install a new JVM and realise its broken and go back,
or if it works remove the old one, or run two at different times)

I think you should add uppercase JDK paths to the search list.

> Unfortunately I don't have the knowledge of how to do this on a Windows
system
> (if it is at all possible), sorry...

I have a feeling a script which actually does something usefull is not
possible under Windows.

Ross Burton


Re: Bug reports...

Posted by Niclas Hedhman <ni...@localbar.com>.
Stefano Mazzocchi wrote:

> Niclas Hedhman wrote:
> > build.sh and build.bat should have xml.jar in classpath for Ant to work.
>
> no. the ant.jar file you find in cocoon2 was compiled to work with
> xerces.

My fault, I think my local CVS was screwed up. No Ant.jar in it, and I had a old
ant.jar in my extension lib, so I started from scratch!!! Works!!


> > My Solution; Get the Recommendation from W3C at;
> > http://www.w3.org/TR/2000/CR-DOM-Level-2-20000307/java-binding.zip
> > and unzip them into the source directory and compile with them.
> > I have xerces.jar (CVS), xalan_0_20_0.jar (release) and sax.jar (w/
> > Cocoon2) in the lib directory, and they are in the classpath of JAVAC.
>
> just follow the instruction, people, and cleanup your ext/ directory
> which should _NEVER_ contain anything else but java extentions.

I know it is not the Cocoon project that screwed up, it is W3C who are not
distinct in their recommendation, and other people (incl. Sun) unable to have
some foresight.
The so called Java-Bindings should be packaged as a binary JAR as well, which
should be included separately from the applications that are using them. The
situation is absolutely horrendous, and definately against the naming and
deployment recommendations from Sun.
Not only does these interface show up every here and there, but the W3C
completely ignores the fact that interfaces DO NOT change over time. They are
either extended OR placed in different packages. And this is the real culprit of
the dom and sax bindings.
Anyone on this list has some influence to straighten this up.

> > The adventure continues later...

build.sh is lacking the Execute flag.
chmod +x build.sh
is required, unless one want to start by
sh build.sh which is a real drag...

I have also attached a more advanced script that will make an attemp to find a
JDK if JAVA_HOME is not set. The directories to look in should perhaps be
evaluated by a query among Linux users of where they place the JDK. I have just
made some qualified guesses.
Unfortunately I don't have the knowledge of how to do this on a Windows system
(if it is at all possible), sorry...

Niclas


Re: Bug reports...

Posted by Niclas Hedhman <ni...@localbar.com>.
Giacomo Pati wrote:

> My ext/ directory is now allways empty since I've spent some hours of
> debugging because some jars were left in that directory and I was not
> aware of. Now I'm controlling everything within my classpath.

Especially since you can do things like

-extdirs=
in javac...

and

java.ext.dirs=
java.lib.dirs=
    :

Niclas


Re: Bug reports...

Posted by Pierpaolo Fumagalli <pi...@apache.org>.
Stefano Mazzocchi wrote:
> 
> > My ext/ directory is now allways empty since I've spent some hours of
> > debugging because some jars were left in that directory and I was not
> > aware of. Now I'm controlling everything within my classpath.
> 
> Good boy! Pier, listen up! :-)

No way I'm gonna change it :)

	Pier
-- 
----------------------------------------------------------------------
pier: stable structure erected over water to allow docking of seacraft
<ma...@betaversion.org>      <http://www.betaversion.org/~pier/>
----------------------------------------------------------------------

Re: Bug reports...

Posted by Stefano Mazzocchi <st...@apache.org>.
Giacomo Pati wrote:
> 
> Pierpaolo Fumagalli wrote:
> >
> > Stefano Mazzocchi wrote:
> > >
> > > just follow the instruction, people, and cleanup your ext/ directory
> > > which should _NEVER_ contain anything else but java extentions.
> >
> > ???? Ha... You should see _MY_ ext directory.... :)
> 
> My ext/ directory is now allways empty since I've spent some hours of
> debugging because some jars were left in that directory and I was not
> aware of. Now I'm controlling everything within my classpath.

Good boy! Pier, listen up! :-)

-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<st...@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------
 Missed us in Orlando? Make it up with ApacheCON Europe in London!
------------------------- http://ApacheCon.Com ---------------------

Re: Bug reports...

Posted by Giacomo Pati <Gi...@pwr.ch>.
Pierpaolo Fumagalli wrote:
> 
> Stefano Mazzocchi wrote:
> >
> > just follow the instruction, people, and cleanup your ext/ directory
> > which should _NEVER_ contain anything else but java extentions.
> 
> ???? Ha... You should see _MY_ ext directory.... :)

My ext/ directory is now allways empty since I've spent some hours of
debugging because some jars were left in that directory and I was not
aware of. Now I'm controlling everything within my classpath.

Giacomo
> 
>         Pier
> 
> --
> ----------------------------------------------------------------------
> pier: stable structure erected over water to allow docking of seacraft
> <ma...@betaversion.org>      <http://www.betaversion.org/~pier/>
> ----------------------------------------------------------------------

-- 
PWR Organisation & Entwicklung            Tel:   +41 (0)1 856 2202
Giacomo Pati                              Fax:   +41 (0)1 856 2201
Hintereichenstrasse 7                     Mailto:Giacomo.Pati@pwr.ch
CH-8166 Niederweningen                    Web:   http://www.pwr.ch

Re: Bug reports...

Posted by Pierpaolo Fumagalli <pi...@apache.org>.
Stefano Mazzocchi wrote:
> 
> just follow the instruction, people, and cleanup your ext/ directory
> which should _NEVER_ contain anything else but java extentions.

???? Ha... You should see _MY_ ext directory.... :)

	Pier

-- 
----------------------------------------------------------------------
pier: stable structure erected over water to allow docking of seacraft
<ma...@betaversion.org>      <http://www.betaversion.org/~pier/>
----------------------------------------------------------------------

Re: Bug reports...

Posted by Stefano Mazzocchi <st...@apache.org>.
Niclas Hedhman wrote:
> 
> Building;
> 
> Problem 1.
> --------
> build.sh and build.bat should have xml.jar in classpath for Ant to work.

no. the ant.jar file you find in cocoon2 was compiled to work with
xerces.

> And since Cocoon2 is more or less Java2 by now,
> I suggest the following start of Ant is used instead;
> 
> $JAVA_HOME/bin/java -Dant.home=$ANT_HOME
> -Djava.ext.dirs=./lib:$JAVA_HOME/jre/lib/ext org.apache.tools.ant.Main
> $*
> 
> which will automatically use all the JARs in the lib directory.

but this is still a good solution. Will do that.
 
> Problem 2.
> -------
> BUILD CONFIG ERROR: Configuration property "classname" does not have a
> setMethod in class org.apache.tools.ant.taskdefs.Java
> org.apache.tools.ant.BuildException: Configuration property "classname"
> does not have a setMethod in class org.apache.tools.ant.taskdefs.Java
>         at
> org.apache.tools.ant.ProjectHelper.configureTask(ProjectHelper.java:296)
> 
>         at
> org.apache.tools.ant.ProjectHelper.configureTasks(ProjectHelper.java:228)
> 
>         at
> org.apache.tools.ant.ProjectHelper.configureTargets(ProjectHelper.java:195)
> 
>         at
> org.apache.tools.ant.ProjectHelper.configureProject(ProjectHelper.java:128)
> 
>         at org.apache.tools.ant.Main.runBuild(Main.java:222)
>         at org.apache.tools.ant.Main.main(Main.java:191)
> 
> Probably due to an old ANT version. Where can an appropriate one be
> found?
> http://jakarta.apache.org/builds/tomcat/nightly/ant.zip
> and all the other ant*.zip are all 0k in size.
> 
> http://jakarta.apache.org/builds/tomcat/release/v3.0/
> is empty. Confusiom reigns!!

Ok, you are the one having the old ant.jar in your classpath, probably
in your /ext directory so remove that.

For the empty directory, our great system administrator (Pier!) just
typed a "rm -rf" on jakarta root and wiped out the whole site! Since we
can't find back-ups, all those directories are now empty. Don't tell me
about it :)
  
> Problem 3;
> --------
> Compile problems in DOMBuilder and DOMStreamer.  Giacomo just brought it
> up...
> 
> My Solution; Get the Recommendation from W3C at;
> http://www.w3.org/TR/2000/CR-DOM-Level-2-20000307/java-binding.zip
> and unzip them into the source directory and compile with them.
> I have xerces.jar (CVS), xalan_0_20_0.jar (release) and sax.jar (w/
> Cocoon2) in the lib directory, and they are in the classpath of JAVAC.

just follow the instruction, people, and cleanup your ext/ directory
which should _NEVER_ contain anything else but java extentions.
 
> The adventure continues later...
> 
> Niclas


-- 
Stefano Mazzocchi      One must still have chaos in oneself to be
                          able to give birth to a dancing star.
<st...@apache.org>                             Friedrich Nietzsche
--------------------------------------------------------------------
 Missed us in Orlando? Make it up with ApacheCON Europe in London!
------------------------- http://ApacheCon.Com ---------------------