gump-general mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brett Porter <brett.por...@gmail.com>
Subject Re: Maven 2 (was Re: Maven 1.1)
Date Fri, 18 Nov 2005 11:27:53 GMT
On 11/16/05, Leo Simons <mail@leosimons.com> wrote:
> I wrote an answer then deleted it. I got lost a little. Seperating concerns:
>
>   --> support for maven2 in gump2
>       --> I'm not going to work on it

Fine by me. I assume gump3 is not far off then?

>   --> how to properly support maven2 in gump3
>

...

>
>   --> a python function or two to work with that xml (while in DOM form)
>       and help transform it into the python object model gump uses

I'll come back to this.

> <project name="mvn">
>   <module name="mvn"/>
>   <depend name="maven2-bootstrap" inherit="all"/>
>   <mvn/>
>   <jar name="target/mvn.jar" runtime="true"/>
> </project>

This is oversimplified as a working Maven contains more than one jar
and a few dependencies. But the bootstrap can be used to build that
install in the first step and then the above could rebuild a new maven
install after gump has built its dependencies. That was all discussed
in my email.

> Ideally we can run mvn without using its shell scripts and just digest
> a command which starts with "java", since that makes it easier to get
> things like the CLASSPATH right.

There is no classpath. Maven starts with just classworlds, which
constructs class loaders for different areas of the system. So its
fine to run without the shell scripts, they don't do much except make
it usable, but the behaviour won't change.

> In this case we don't have a local
> installation but one running straight from trunk (just like ant).

As built above, sure.

> Now,
> if we need some special bits like some java code to replace the repository
> management, we would have something like
>
> <project name="mvn-gump-java-helper">
>   <module name="gump3"/>
>   <depend name="ant" inherit="all"/>
>   <depend name="mvn-bootstrap" inherit="all"/>
>   <ant/>
>   <jar name="target/mvn-gump-java-helper.jar"/>
> </project>

You've got Maven at this point, you can build with it :)

This will just be one class, and was something I discussed in my prior email.

> Now, as far as repository management, downloading, dependency resolution,
> any of that is concerned, what we want to do in this "mvn-gump-java-helper"
> is simply disable as much of those bits of maven2 as possible.

Yes, but you are going to have to go the other way around. It's a
component that resolves artifacts and metadata. It doesn't get fed, it
hunts. You can't use CLASSPATH. The helper will be the implementation
that goes and finds things.

> I hope all that made sense. Now, moving on to the first implementation
> details....

LOL. Like there weren't any implementation details above :)

Unfortunately, the assumptions above won't work. Maven needs to
resolve JARs, and resolve dependencies via metadata. This means it has
to be able to find the JARs (Seems easy enough), and the metadata -
which means reading gump.xml/pom.xml/something-else.xml.

In the part above where you create a gump object model, you will need
to write that out in a form so that Maven (though the gump java
helper) can digest it and get the proper ids and the dependencies.

Is it possible for me to put ID mappings into the gump2/3 descriptor
without breaking anything, or will we need to align them?

>
>   --> how to bootstrap maven2
>
> Downloading things from elsewhere is not a problem. The key bit is getting
> to a classpath when using maven to build stuff that contains only "fresh"
> built sources and none of the prepackaged bits (just like when you're
> bootstrapping GCC -- you download a binary GCC to build GCC, then you throw
> the binary away). If there is a procedure to get absolutely everything from
> source including all of mavens dependencies and build all of it properly (I
> really hope there is one now for maven 2) and dependably, lets use it.

Currently, it downloads the bits that it depends on outside the Maven
tree. I can change those to be checked out and built too.

> Key bit here is that what gump does for bootstrapping is the same as what
> the maven 2 people do for bootstrapping. It sounds like the one you use
> yourselves is the first option so lets roll with that.

Ok, this part is fine.

- Brett

---------------------------------------------------------------------
To unsubscribe, e-mail: general-unsubscribe@gump.apache.org
For additional commands, e-mail: general-help@gump.apache.org


Mime
View raw message