Hi all, 

I've a project where multiple libraries are created by maven
configuration. But I'm working
with Eclipse and m2eclipse integration.


I have one my projects with this build configuration:

pom.xml
-----------------
...
<build>
<finalName>crm-enterprise-hibernate-${project.version}</finalName>
<directory>target</directory>
<outputDirectory>target/classes</outputDirectory>
<sourceDirectory>src/main/java</sourceDirectory>
<testSourceDirectory>src/test/java</testSourceDirectory>
<testOutputDirectory>target/test-classes</testOutputDirectory>
<resources>
<resource>
<directory>src/main/resources</directory>
<targetPath>target/classes</targetPath>
<filtering>true</filtering>
<includes>
<include>**/*.html</include>
</includes>
<excludes>
<exclude></exclude>
</excludes>
</resource>
</resources>
<filters>
</filters>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>2.0.2</version>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
</plugins>
</build>
...
-------------------------

As you can see final name should be something with the version as the
following statetment says:
<finalName>crm-enterprise-hibernate-${project.version}</finalName>


But I found that org.eclipse.wst.common.component generation
configuration for this project is:
<?xml version="1.0" encoding="UTF-8"?>
<project-modules id="moduleCoreId" project-version="1.5.0">
    <wb-module deploy-name="crm-enterprise-hibernate">
        <wb-resource deploy-path="/" source-path="/src/main/java"/>
        <wb-resource deploy-path="/" source-path="/src/main/resources"/>
        <wb-resource deploy-path="/" source-path="/src/test/java"/>
        <wb-resource deploy-path="/" source-path="/src/test/resources"/>
    </wb-module>
</project-modules>


I cannot make the version appear in the built jar anyway (well, not
true, I can change deploy-name="crm-enterprise-hibernate" manually but I
don't want).


What's the correct way to do it. Eclipse seems to ignore the finalName
attribute.


Thank you.

Reply via email to