maven-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ron Wheeler <rwhee...@artifact-software.com>
Subject Re: importing dependencies without inheritance
Date Wed, 06 Oct 2010 19:52:39 GMT
  The POMs look good to me.
I would move the <repositories/> to a parent POM with the compile 
plug-in just to reduce the size of the project POMs but that is not what 
is affecting your build.

Log from the build of B ?

Ron


On 06/10/2010 3:37 PM, thisguy wrote:
> ok I've pruned out the rest of the dependencies but left everything else in
> here:
>
> Project A:
>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
> http://maven.apache.org/xsd/maven-4.0.0.xsd">
>    <modelVersion>4.0.0</modelVersion>
>    <groupId>myorg</groupId>
>    <artifactId>myjar</artifactId>
>    <version>1.0.0.0</version>
>    <name>myjar</name>
>    <repositories>
>    	<repository>
>    		<id>public</id>
>    		<url>http://blah:8081/nexus/content/groups/public/</url>
>    	</repository>
>    </repositories>
> <dependencies>
>
> <dependency>
>    		<groupId>postgresql</groupId>
>    		<artifactId>postgresql</artifactId>
>    		<version>8.2-507.jdbc3</version>
>    		<type>jar</type>
>    		<scope>compile</scope>
>    	</dependency>
> </dependencies>
>   <properties>
>      <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
>    </properties>
>     <build>
>    	<plugins>
>    		<plugin>
>    			<groupId>org.apache.maven.plugins</groupId>
>    			<artifactId>maven-compiler-plugin</artifactId>
>    			<version>2.3.2</version>
>    			<configuration>
> 					<source>1.6</source>
> 					<target>1.6</target>
> 				</configuration>
>    		</plugin>
>    		<plugin>
> 	<artifactId>maven-assembly-plugin</artifactId>
> 	<version>2.2-beta-5</version>
> 	<configuration>
> 	<descriptorRefs>
> 	<descriptorRef>jar-with-dependencies</descriptorRef>
> 	</descriptorRefs>
> 	</configuration>
> 	<executions>
>            <execution>
>              <id>make-my-jar-with-dependencies</id>
>              <phase>package</phase>
>              <goals>
>                <goal>single</goal>
>              </goals>
>            </execution>
>          </executions>
> 	
> 	  	</plugin>	
>    	</plugins>
>
> Then in project B:
>
> <project xmlns="http://maven.apache.org/POM/4.0.0"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
> http://maven.apache.org/xsd/maven-4.0.0.xsd">
>
>    <modelVersion>4.0.0</modelVersion>
>    <groupId>myorg</groupId>
>    <artifactId>mywebapp</artifactId>
>    <version>1.0.0.0</version>
> <packaging>war</packaging>
>    <name>mywebapp</name>
>    <repositories>
>    	<repository>
>    		<id>public</id>
>    		<url>http://blah:8081/nexus/content/groups/public/</url>
>    	</repository>
>    </repositories>
>    <dependencies>
> 	<dependency>
> 	  		<groupId>myorg</groupId>
> 	  		<artifactId>myjar</artifactId>
> 	  		<version>1.0.0.0</version>
> 	  		<type>jar</type>
> 	  		<scope>compile</scope>
> 	  	</dependency>
>   </dependencies>
>    <build>
>    	<plugins>
>    		<plugin>
>    			<groupId>org.apache.maven.plugins</groupId>
>    			<artifactId>maven-compiler-plugin</artifactId>
>    			<version>2.3.2</version>
>    			<configuration>
> 					<source>1.6</source>
> 					<target>1.6</target>
> 				</configuration>
>    		</plugin>
>    	</plugins>
>    </build>
>
>    <properties>
>      <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
>    </properties>
> </project>
>
> I don't have the log from maven install because I manually uploaded the
> "myjar" into nexus.  Eclipse found it ok so I assumed it is fine in the
> repository.  Let me know if I should look for something in particular in the
> POM generated by nexus or whatever.  Thanks.


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


Mime
View raw message