"Scott Francis" <[EMAIL PROTECTED]> wrote on 21/09/2002 01:31:42 
AM:

> I have very similar questions to the ones you posted... hope we get a
> good answer :)
> (and i hope i haven't already missed it!)
Some comments, inline...

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] 
> Sent: Thursday, September 19, 2002 11:15 PM
> To: [EMAIL PROTECTED]
> Cc: [EMAIL PROTECTED]
> Subject: Newbie problems with Maven
> 
> 
> Hi-,
> I spent a few hours trying to replace Ant1.5 with the latest Maven. Have
> a few questions/remarks:
> 
> 1. The 'project.xml' file has lots of elements, which hardly make any
> sense in commercial projects (mailing lists, http repositories ...).
> Maybe it is OK for Commons/Turbine, but it is still a very narrow view
> of how project must be organized.

Lots of those are optional. Out of the *mandatory* stuff:
project
  - pomVersion, id, name, currentVersion
  - organization
    - name
  - inceptionYear
  - shortDescription
  - developers
  - build

Which are unnecessary for a commercial project? I use Maven for work most 
days, and these are ok for me....

> 2. The only thing in project.xml that governs compilation I found was:
> ---------------------
> <build>
> ...
>     <sourceDirectory>src/java</sourceDirectory>
> ....
> </build>
> ---------------------

Sure, but there's a ton of properties available. Some are documented here: 
http://jakarta.apache.org/turbine/maven/reference/plugins/java/properties.html 
, but others are as yet no documented.

> Then, how can I transition a former and not-so-trivial Ant task, such
> as:
> ----------------------------------------------------------------------
> <target name="compile" depends="prepare">
>      <mkdir dir="${build.dir}/classes"/>
>     <javac
>         fork="yes"

The java plugin doesn't currently allow forking.

>         compiler="modern"

I believe this is the default for jdk1.3/1.4

>         executable="${java.home}/../bin/javac"

See the note on forking.

>            destdir="${build.dir}/classes"

This is the ${maven.build.dest} property.

>            source="1.4"

We had problems with specfiying source= for javac when not using one of 
the jdks from memory, and currently it's not passed to ant.
>            deprecation="on"
This is the ${maven.compile.deprecation} property

>            debug="${jcompiler.debug}"
This is the ${maven.compile.debug} property
>            optimize="${jcompiler.optimize}">
This is the ${maven.compile.optimize} property

>            <compilerarg line="-J-Xbootclasspath/p:
> ${lib.dir}/gj/javac.jar"/>
>            <compilerarg line="-bootclasspath ${lib.dir}/gj/collect.jar;
> ${java.home}/lib/rt.jar"/>


>            <compilerarg line="-gj"/>
>            <compilerarg line="-warnunchecked"/>

Not currently supported by the plugin

>           <classpath refid="project.classpath"/>

This is specified by your <dependencies> in project.xml

>           <src path="${src.dir}/census/java"/>

You already know how to set this one using build.xml

>        </javac>
>   </target>
> ------------------------------------------------------------------------
> ---
> 
> This is how you'd compile if you already use Java Generics/jsr-014. And
> I do! Do I need to write maven.xml and if so, where can I look to see
> how to hack <goal name="java:compile"> to make it call back my weird
> javac Ant task ?

It'd probably be better if we came up with a way of compiling generics as 
we do aspects or other code.

> 3. James, any plans to implement "go-fetch-me-a-jar" tag(s) in pure
> Jelly? This would make Jelly+Ant  sifficiently powerful and the reasons
> for switching to Maven far less compelling. Whatever happened to JJAR?

Jelly has a HTTP taglibrary from memory, and there's also one in Latka. 
JJAR - no idea.

> 4. Any plans to implement extracting jars from within other bundles on
> an HTTP server? For example, I need Jakarta POI jars, but they do not
> exist at ibiblio.org/maven and I can not put them there. However, I
> could possibly extract them in a local repository form the official POI
> site.

You can have your own repositories. You don't have to always have them at 
ibiblio. However, if you'd like something at ibiblio, drop us a line.

> 5. The current fetch engine in Maven would only takes care of executable
> jars. How can I make Maven bring the source too (well, I know there are
> no sources at ibiblio.org currently). This is important for tools like
> IDEA, CodeGuide, Eclipse, etc. Further, how about storing debug vs.
> optimized jars at ibiblio.org?

All good points...

> Thanks,
> Hristo
--
dIon Gillard, Multitask Consulting
Work:      http://www.multitask.com.au
Developers: http://adslgateway.multitask.com.au/developers




--
To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>

Reply via email to