You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@maven.apache.org by Björn Höfling <bj...@bjoernhoefling.de> on 2016/08/23 06:25:36 UTC

Building Maven from scratch

I want to build maven without haven _ANY_ maven/plugin binary. How can
I do that?

I found out that there is a build.xml and it start building a first
version of Maven. But then it needs plugins to go further.

I found the plugins source here: https://maven.apache.org/plugins/
But these have only pom.xml, there is no Ant build script.

Is there any documentation on this. Searching for "Ant Maven" just
leads you to the ant-maven-plugin...

Thank you,

Björn

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Building Maven from scratch

Posted by Anders Hammar <an...@hammar.net>.
I doubt this is possible. We used to support building Maven core with Ant,
but IIRC a fairly recent discussion resulted in a decision to stop
supporting that. So you need Maven installed to build Maven core. More info
here:
http://maven.apache.org/guides/development/guide-building-maven.html

/Anders

On Tue, Aug 23, 2016 at 8:25 AM, Björn Höfling <
bjoern.hoefling@bjoernhoefling.de> wrote:

> I want to build maven without haven _ANY_ maven/plugin binary. How can
> I do that?
>
> I found out that there is a build.xml and it start building a first
> version of Maven. But then it needs plugins to go further.
>
> I found the plugins source here: https://maven.apache.org/plugins/
> But these have only pom.xml, there is no Ant build script.
>
> Is there any documentation on this. Searching for "Ant Maven" just
> leads you to the ant-maven-plugin...
>
> Thank you,
>
> Björn
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
>
>

Re: Building Maven from scratch

Posted by Björn Höfling <bj...@bjoernhoefling.de>.
Hi Karl Heinz,

On Wed, 24 Aug 2016 19:54:07 +0200
Karl Heinz Marbaise <kh...@gmx.de> wrote:

> First we call Maven Core this:
> 
> https://git-wip-us.apache.org/repos/asf/maven.git
> 
> which is Maven itself  and in the end can be downloaded from 
> http://maven.apache.org/download.html and what you call usually from 
> command line like this:
> 
> mvn clean package
> 
> You can clone the above git repo and change to Tag: maven-3.3.9 and 
> there you will find build.xml for an Ant build...If you have finished 
> Maven 3.3.9 you can use Maven 3.3.9 to build 3.4.0 (currently not 
> released)...
> 
> 
> http://maven.apache.org/source-repository.html


I see, "Maven core" is just the basic maven command. I tried to compile
that one with ant but noticed the ant build is already downloading many
jar-files (plugins, dependencies) from the Maven repository.

I tried it with Maven 2.x and 1.x, but all download some binary jar
files first. If you try to build those from source, you either need
Maven or they download even more binary jars or the source code is no
longer available.

This looks to be much harder than I thought. Can't find the first
chicken to compile.

When finished with this, I could write a paper on the history
and evolution of Java XML parsers :-)

> >> The question is why do you want to do that?
> >
> > It is out of curiosity, and a not too serious BLOB-fearfulness.
> 
> BLOB ?

BLOB=Binary Large OBject. I mean any compiled binary code, bytecode,
jar-files, executables, compiled from source code.

> 
>  >  And
> > finally I played around with GuixSD in the last time and wondered
> > how to get Maven into there as a deterministically from source
> > compiled package.
> 
> Why not using the available binaries ? There packages for linux which 
> only need a JDK ?
> 
> Those packages are compiled from Source as well ?

Everything is compiled from source in GuixSD. It's like Gentoo, but
100% GNU FSDG compliant and hopefully a reproducible build. 

> Do you build JDK also from source ?

Yes, that figured already someone else out. Here is the recipe for
IcedTea 3:

http://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/java.scm#n964

Thank you so far,

Björn

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Building Maven from scratch

Posted by Karl Heinz Marbaise <kh...@gmx.de>.
Hi Bj�rn,

On 24/08/16 08:57, Bj�rn H�fling wrote:
> Hi Karl Heinz,
>
> On Tue, 23 Aug 2016 21:51:11 +0200
> Karl Heinz Marbaise <kh...@gmx.de> wrote:
>
>> Hi Bj�rn,
>>
>> On 23/08/16 08:25, Bj�rn H�fling wrote:
>>> I want to build maven without haven _ANY_ maven/plugin binary. How
>>> can I do that?
>>
>> First you can do that only till Maven 3.3.9 starting with Maven 3.4.0
>> you need Maven 3.3.9 to build Maven 3.4.0...Details [1].
>
> That is fine. I really thought it would be worse: Building maven 2 with
> 1, 3 with 2, or worse.
>
> But it seams I have to go back some way. Where should I start? Is
> there some manual? What exactly is maven core, is that enough?

First we call Maven Core this:

https://git-wip-us.apache.org/repos/asf/maven.git

which is Maven itself  and in the end can be downloaded from 
http://maven.apache.org/download.html and what you call usually from 
command line like this:

mvn clean package

You can clone the above git repo and change to Tag: maven-3.3.9 and 
there you will find build.xml for an Ant build...If you have finished 
Maven 3.3.9 you can use Maven 3.3.9 to build 3.4.0 (currently not 
released)...


http://maven.apache.org/source-repository.html

>
>
>> The question is why do you want to do that?
>
> It is out of curiosity, and a not too serious BLOB-fearfulness.

BLOB ?

 >  And
> finally I played around with GuixSD in the last time and wondered how
> to get Maven into there as a deterministically from source
> compiled package.

Why not using the available binaries ? There packages for linux which 
only need a JDK ?

Those packages are compiled from Source as well ?

Do you build JDK also from source ?


Kind regards
Karl Heinz Marbaise

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Building Maven from scratch

Posted by Björn Höfling <bj...@bjoernhoefling.de>.
Hi Karl Heinz,

On Tue, 23 Aug 2016 21:51:11 +0200
Karl Heinz Marbaise <kh...@gmx.de> wrote:

> Hi Björn,
> 
> On 23/08/16 08:25, Björn Höfling wrote:
> > I want to build maven without haven _ANY_ maven/plugin binary. How
> > can I do that?
> 
> First you can do that only till Maven 3.3.9 starting with Maven 3.4.0 
> you need Maven 3.3.9 to build Maven 3.4.0...Details [1].

That is fine. I really thought it would be worse: Building maven 2 with
1, 3 with 2, or worse.

But it seams I have to go back some way. Where should I start? Is
there some manual? What exactly is maven core, is that enough?


> The question is why do you want to do that?

It is out of curiosity, and a not too serious BLOB-fearfulness. And
finally I played around with GuixSD in the last time and wondered how
to get Maven into there as a deterministically from source
compiled package.

Björn 



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Building Maven from scratch

Posted by Karl Heinz Marbaise <kh...@gmx.de>.
Hi Bj�rn,

On 23/08/16 08:25, Bj�rn H�fling wrote:
> I want to build maven without haven _ANY_ maven/plugin binary. How can
> I do that?

First you can do that only till Maven 3.3.9 starting with Maven 3.4.0 
you need Maven 3.3.9 to build Maven 3.4.0...Details [1].

The question is why do you want to do that?

>
> I found out that there is a build.xml and it start building a first
> version of Maven. But then it needs plugins to go further.
>
> I found the plugins source here: https://maven.apache.org/plugins/
> But these have only pom.xml, there is no Ant build script.
>
> Is there any documentation on this. Searching for "Ant Maven" just
> leads you to the ant-maven-plugin...
>
> Thank you,
>
> Bj�rn



[1]: https://issues.apache.org/jira/browse/MNG-5904


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org


Re: Building Maven from scratch

Posted by Igor Fedorenko <ig...@ifedorenko.com>.
Out of curiosity, what is your usecase? 

-- 
Regards,
Igor

On Tue, Aug 23, 2016, at 02:25 AM, Björn Höfling wrote:
> I want to build maven without haven _ANY_ maven/plugin binary. How can
> I do that?
> 
> I found out that there is a build.xml and it start building a first
> version of Maven. But then it needs plugins to go further.
> 
> I found the plugins source here: https://maven.apache.org/plugins/
> But these have only pom.xml, there is no Ant build script.
> 
> Is there any documentation on this. Searching for "Ant Maven" just
> leads you to the ant-maven-plugin...
> 
> Thank you,
> 
> Björn
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
> For additional commands, e-mail: dev-help@maven.apache.org
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@maven.apache.org
For additional commands, e-mail: dev-help@maven.apache.org