[ http://jira.codehaus.org/browse/MWEBSTART-37?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_95530 ]
Stephane Nicoll commented on MWEBSTART-37: ------------------------------------------ Oh sorry you're right. This is commons-configuration s**i that brings servlet-api with compile scope. It does not handle system dependencies properly though. You can have a look to various plugin such as the maven-ear-plugin which gives you a way to defined a filter that will handle that for you. Something like {code:java} ScopeArtifactFilter filter = new ScopeArtifactFilter( Artifact.SCOPE_RUNTIME ); for ( Iterator iter = artifacts.iterator(); iter.hasNext(); ) { Artifact artifact = (Artifact) iter.next(); // If the artifact's type is POM, ignore and continue // since it's used for transitive deps only. if ( "pom".equals( artifact.getType() ) ) { continue; } if ( filter.include( artifact ) ) { // Here you go (takes compile & runtime ; reject optional, provided, system, test) } } {code} Also, please note that the exclude filter only work against compile-scope dependencies so the only way to get rid of the system scope jar is to actually use an exclusion on the dependency (since it's coming transitively). > Webstart packages provided/system dependencies and exclude filter matches > against compiled-scope dep only > --------------------------------------------------------------------------------------------------------- > > Key: MWEBSTART-37 > URL: http://jira.codehaus.org/browse/MWEBSTART-37 > Project: Maven 2.x Webstart Plugin > Issue Type: Bug > Affects Versions: 1.0-alpha-2 > Reporter: Stephane Nicoll > Priority: Blocker > > The webstart plugin packages all dependencies, even those with > system/provided scope. > I have a project that depends on the sun tools.jar to compile. This project > is an indirect (transient) dep of the project and I have tools.jar packaged > in the bundle !!! (same for servlet-api which is flagged properly as > provided). > The exclude filter however only matches dependencies with scope compile. > So there is no way to exclude those (They should not be packaged in a first > place) -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe from this list please visit: http://xircles.codehaus.org/manage_email