Package: maven-debian-helper Severity: normal Tags: patch
Hi, in dh build, path to debian/maven.properties file in 'properties.file.manual' should be passed to Maven as a JVM system property, but the perl script simply appends it at the end of the command line, making it a Maven property. Because of this misplacement, content of d/maven.properties is ignored by dh build. Please see attached patch. Regards, Jakub
>From 3f377ddcb852522438609bfcf93a729c6473b2ac Mon Sep 17 00:00:00 2001 From: Jakub Adam <jakub.a...@ktknet.cz> Date: Tue, 28 May 2013 12:52:06 +0200 Subject: [PATCH] maven.pm: pass properties.file.manual as JVM system property Because it was passed as Maven property, content of d/maven.properties was ignored in dh build. --- share/perl/maven.pm | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/share/perl/maven.pm b/share/perl/maven.pm index adfaed0..00520df 100644 --- a/share/perl/maven.pm +++ b/share/perl/maven.pm @@ -36,16 +36,18 @@ sub new { push(@classpath, "$java_home/lib/tools.jar"); } + my @jvmopts = ('-noverify', '-cp', join(':',@classpath), + "-Dclassworlds.conf=$classconf"); + if (-e "$this->{cwd}/debian/maven.properties") { + push (@jvmopts, "-Dproperties.file.manual=$this->{cwd}/debian/maven.properties"); + } + @{$this->{maven_cmd}} = ($java_home . '/bin/java', - '-noverify', '-cp', join(':',@classpath), - "-Dclassworlds.conf=$classconf", + @jvmopts, "org.codehaus.classworlds.Launcher", "-s/etc/maven2/settings-debian.xml", "-Ddebian.dir=$this->{cwd}/debian", "-Dmaven.repo.local=$this->{cwd}/debian/maven-repo"); - if (-e "$this->{cwd}/debian/maven.properties") { - push (@{$this->{maven_cmd}}, "-Dproperties.file.manual=$this->{cwd}/debian/maven.properties"); - } return $this; } -- 1.7.10.4