Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Building SPIM_Registration 962f13903887260cff8f48e8792fbf27c66e53e6 #8

Closed
psteinb opened this issue Dec 15, 2014 · 9 comments
Closed

Comments

@psteinb
Copy link

psteinb commented Dec 15, 2014

Hi to all,

I am trying to build 962f139 in order to test some ways to speed-up the runtime of it and keep stumbling over the following error message:

[INFO] Restricted to JDK 1.6 yet com.sun:tools:jar:1.4.2:system contains sun/tools/asm/SwitchDataEnumeration.class targeted to JDK 1.7
[WARNING] Rule 2: org.apache.maven.plugins.enforcer.EnforceBytecodeVersion failed with message:
Found Banned Dependency: com.sun:tools:jar:1.4.2
Use 'mvn dependency:tree' to locate the source of the banned dependencies.

and further down:

[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1:40.858s
[INFO] Finished at: Mon Dec 15 09:43:48 CET 2014
[INFO] Final Memory: 209M/1188M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:1.3.1:enforce (enforce-rules) on project SPIM_Registration: Some Enforcer rules have failed. Look above for specific messages explaining why the rule failed. -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:1.3.1:enforce (enforce-rules) on project SPIM_Registration: Some Enforcer rules have failed. Look above for specific messages explaining why the rule failed.
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:216)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
        at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
        at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
        at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
        at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:317)
        at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:152)
        at org.apache.maven.cli.MavenCli.execute(MavenCli.java:555)
        at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
        at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
        at java.lang.reflect.Method.invoke(Method.java:601)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
        at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
        at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
        at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.MojoExecutionException: Some Enforcer rules have failed. Look above for specific messages explaining why the rule failed.
        at org.apache.maven.plugins.enforcer.EnforceMojo.execute(EnforceMojo.java:209)
        at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:106)
        at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
        ... 19 more

Any idea, how to fix this?
Best,
Peter

@tpietzsch
Copy link
Member

Hi Peter,

running maven with the -Denforcer.skip flag should make this go away
(Another option would be to run maven with jdk 1.6)

best regards,
Tobias

On 15 Dec 2014, at 10:57, Peter Steinbach notifications@github.com wrote:

Hi to all,

I am trying to build 962f139 in order to test some ways to speed-up the runtime of it and keep stumbling over the following error message:

[INFO] Restricted to JDK 1.6 yet com.sun:tools:jar:1.4.2:system contains sun/tools/asm/SwitchDataEnumeration.class targeted to JDK 1.7
[WARNING] Rule 2: org.apache.maven.plugins.enforcer.EnforceBytecodeVersion failed with message:
Found Banned Dependency: com.sun:tools:jar:1.4.2
Use 'mvn dependency:tree' to locate the source of the banned dependencies.
and further down:

[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1:40.858s
[INFO] Finished at: Mon Dec 15 09:43:48 CET 2014
[INFO] Final Memory: 209M/1188M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:1.3.1:enforce (enforce-rules) on project SPIM_Registration: Some Enforcer rules have failed. Look above for specific messages explaining why the rule failed. -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.apache.maven.plugins:maven-enforcer-plugin:1.3.1:enforce (enforce-rules) on project SPIM_Registration: Some Enforcer rules have failed. Look above for specific messages explaining why the rule failed.
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:216)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:84)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:59)
at org.apache.maven.lifecycle.internal.LifecycleStarter.singleThreadedBuild(LifecycleStarter.java:183)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:161)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:317)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:152)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:555)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:214)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:158)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: org.apache.maven.plugin.MojoExecutionException: Some Enforcer rules have failed. Look above for specific messages explaining why the rule failed.
at org.apache.maven.plugins.enforcer.EnforceMojo.execute(EnforceMojo.java:209)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:106)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 19 more
Any idea, how to fix this?
Best,
Peter


Reply to this email directly or view it on GitHub.

@psteinb
Copy link
Author

psteinb commented Dec 15, 2014

thanks tobi, the enforcer.skip flag works! (I am such a java noob: how would I run maven with jdk 1.6?)

@axtimwalde
Copy link
Member

Side note to complete this thread: since pom-fiji 6.1.1, the enforcer rule permits building with Java >= 1.6.

@ctrueden
Copy link
Member

Thanks @axtimwalde. Agreed that the components in question should be upgraded to use pom-fiji version 6.1.1 to avoid this. We really, really want the enforcer config to not get in the way, but instead catch real problems with the build. If you find yourself using enforcer.skip all the time, let me know and we'll figure something out.

@tpietzsch
Copy link
Member

@axtimwalde @ctrueden thanks, good to know! I’ll upgrade the BDV projects to that new version.

On 15 Dec 2014, at 16:57, Curtis Rueden notifications@github.com wrote:

Thanks @axtimwalde. Agreed that the components in question should be upgraded to use pom-fiji version 6.1.1 to avoid this. We really, really want the enforcer config to not get in the way, but instead catch real problems with the build. If you find yourself using enforcer.skip all the time, let me know and we'll figure something out.


Reply to this email directly or view it on GitHub.

@tpietzsch
Copy link
Member

@psteinnb: I think to run mvn with jdk1.6 you just have to install jdk 1.6 and point $JAVA_HOME to it.

@ctrueden
Copy link
Member

@tpietzsch @psteinb Yep. Here is how I do it on OS X. And on Ubuntu Linux you can use update-java-alternatives.

@StephanPreibisch
Copy link
Member

Hi @psteinb,

does it work now for you? With the finished restructuring of Fiji which includes the release version of ImgLib2 it should work easier now as well thanks to Curtis's efforts ...

Cheers,
Stephan

@psteinb
Copy link
Author

psteinb commented Jan 5, 2015

works now!

@psteinb psteinb closed this as completed Jan 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants