Maven 3 polyglot and/or attribute based configuration

2010-12-20 Thread Niels B Nielsen
Hi,

I have long been a user of Maven, but disfavoured the xml verbosity. With Maven 
3 I am aware of the polyglot capabilities of using Groovy or YAML for pom 
files, but I would still prefer the xml syntax for a while.

A few years ago, a JIRA was raised [1], and an experimental branch created as a 
proof-of-concept, introducing attributed based configuration, having entities 
like:


  


Which I think is a good format. It is easier to compact a full pom file and see 
what goes on, and it still verifies against a DTD. However, it may contradict 
existing tools and behaviours.
Alternatively mix the current model with a namespaced schema-extension, which 
could provide attributed based primitives for the most common items.

Does anyone know if this has been reconsider inside Maven 3 at all or is the 
polyglot solution the path to the future maven configuration?


Regards


Niels B Nielsen | Lead Engineer
J.P. Morgan | IBTech Global Rates Derivatives

[1] http://jira.codehaus.org/browse/MNG-3397



This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.  

RE: Handling native dependencies via classifier(s)

2010-12-14 Thread Niels B Nielsen
Well, I can tell you how I deal with it..

I have all editions of our native libraries bundled inside a single jar file, I 
created.
./win32/libsomething.dll
./win64/libsomething.dll
./unix/x32/something.so
etc

and unpacks that into lib (similar to what you did).
During test and execution we navigate the right structure and set 
java.library.path.

the eclipse plugin surely has some shortcomings, especially in the native ares.
When setting up for eclipse, I use 'mvn eclipse:eclipse -DdownloadSources 
-DdownloadJavadocs', and then just reference the library in the launch 
configuration (java.library.path).

Hope that helps.

P.S. I would never add a dependency on source and javadocs etc, as the main 
resolve would transitively include these in the classpath.

Niels B Nielsen | Lead Engineer
J.P. Morgan | IBTech Global Rates Derivatives



-Original Message-
From: Peter Bridge [mailto:peter_bri...@hotmail.com] 
Sent: 14 December 2010 12:45
To: users@maven.apache.org
Subject: Handling native dependencies via classifier(s)

My project depends on a 3rd party library for OpenGL + Java called JOGL
(http://jogamp.org/jogl/www/)

The library is currently not maven-ized and I'm trying to find the best
way to achieve that.  My progress is documented at:
http://jogamp.762907.n3.nabble.com/maven2-artifacts-tp1935908p1935908.html

To get started I'm just manually putting the JOGL jars into a local
repository.  Currently this is 4 jar files and each jar has a dependency
on a couple of native libs (.dll .jnilib .so etc) which I'm zipping and
then unpacking again for my project with:

   

maven-dependency-plugin


unpack-dependencies
generate-sources

unpack-dependencies


   
${basedir}/lib
zip






For each Jar I have a block like this:


com.jogamp.jogl
jogl-all
${jogl.version}


com.jogamp.jogl
jogl-natives
${jogl.version}
osx-universal
zip


Now this is going to get ugly quite fast, ie once I add all 5 supported
native platforms.  It also feels wrong, although I'm very new to
maven2.  Somehow I expected that there would be a way to tie the native
dependencies together with the jar in a more elegant way, maybe
something like:


com.jogamp.jogl
jogl-all
${jogl.version}
sources
javadoc
osx-universal
windows
linux
...


I considered some kind of wrapper pom for each jar, but it also feels
like a work-around.  ie the jar can't be used without the natives, so
somehow they should be configured as a single artifact/entity/dependency.

The next issue I trip over with native handling, is eclipse:eclipse. 
Looking at the sources, it seems to take account of classifiers for
'sources' and 'javadoc' but I don't see anything for handling of native
directories.  ie the EclipseClasspathWriter and AbstractIdeSupportMojo
would need to output something like this:








Now I'm thinking I can't be the first person to trip over this, but
google isn't giving much help.  So I'm wondering how other people are
dealing with this?

Or is it just that maven currently just isn't designed to work with
native dependencies?




-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



RE: How to download transitive dependencies

2010-12-03 Thread Niels B Nielsen
would dependency:go-offline work?

Regards

-Original Message-
From: amaresh mourya [mailto:amaresh.mou...@gmail.com] 
Sent: 03 December 2010 11:21
To: Maven Users List
Subject: How to download transitive dependencies

Hi All,

I have a project(A) containing pom.xml and that have a dependency of

  ca.grimoire.maven
  maven-utils-parent
  1.0
  pom


And this maven-utils-parent-1.0.pom (in my local repository) has few
dependencies in . Is it possible to download these
dependencies via some command. As when I run dependency:resolve on pom.xml
of project A, I got ca.grimoire.maven:maven-utils-parent:pom:1.0 in my local
repository. Is there any other command which can download all dependencies
including below ones..




  
  
${project.groupId}
maven-utils
${project.version}
  

  
  
log4j
log4j
1.2.14
  

  
junit
junit
3.8.1
test
  

  
  
javax.servlet
servlet-api
2.5
provided
  

  
javax.servlet.jsp
jsp-api
2.1
provided
  

  

Thanks,
Amaresh
This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.

-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



How do I augment the release plugin?

2010-12-01 Thread Niels B Nielsen
Hi,

I would like to to utilize the maven-release-plugin (v 2.1) for one of our 
projects, but unfortunately I have a bit of a show stopper for actually doing 
this.

The mojo's in the maven-release-plugin utilize the maven-release-manager, which 
has a set of predefined release phases, such as this (for branching)

  create-backup-poms
  check-poms
  scm-check-modifications
  map-branch-versions
  map-development-versions
  rewrite-poms-for-branch
  scm-commit-branch
  scm-branch
  rewrite-poms-for-development
  scm-commit-release
  end-release


If I want to add additional phases in there, how would I go about doing it?
I  found the phases defined in a components-fragment.xml in the 
maven-release-manager plugin.

 I can see in the maven-release-plugin that it gets the MavenReleaseManager 
injected as a component, but I don't know if or how I can swap it out with a 
custom defined component. If anybody can point me to anything relevant I would 
be very grateful..

Regards


Niels B Nielsen | Lead Engineer
J.P. Morgan | IBTech Global Rates Derivatives



This email is confidential and subject to important disclaimers and
conditions including on offers for the purchase or sale of
securities, accuracy and completeness of information, viruses,
confidentiality, legal privilege, and legal entity disclaimers,
available at http://www.jpmorgan.com/pages/disclosures/email.