[pkg-java] r13770 - in trunk/maven-debian-helper: bin debian maven-packager-utils/src/main/java/org/debian/maven/packager share/cdbs/1/class
Damien Raude-Morvan
drazzib at alioth.debian.org
Wed Jun 8 22:17:11 UTC 2011
Author: drazzib
Date: 2011-06-08 22:17:10 +0000 (Wed, 08 Jun 2011)
New Revision: 13770
Modified:
trunk/maven-debian-helper/bin/mh_resolve_dependencies
trunk/maven-debian-helper/debian/changelog
trunk/maven-debian-helper/maven-packager-utils/src/main/java/org/debian/maven/packager/DependenciesMojo.java
trunk/maven-debian-helper/share/cdbs/1/class/maven-vars.mk
trunk/maven-debian-helper/share/cdbs/1/class/maven.mk
Log:
mh_resolve_dependencies: New --javadoc param, send from maven.mk CDBS file
to automatically compute Javadoc dependencies when there is some *-doc
package. Closes: #628703.
Modified: trunk/maven-debian-helper/bin/mh_resolve_dependencies
===================================================================
--- trunk/maven-debian-helper/bin/mh_resolve_dependencies 2011-06-08 21:36:06 UTC (rev 13769)
+++ trunk/maven-debian-helper/bin/mh_resolve_dependencies 2011-06-08 22:17:10 UTC (rev 13770)
@@ -18,6 +18,7 @@
echo -e "\t-V --version: show the version"
echo -e "\t-p<package> --package=<package>: name of the package"
echo -e "\t-a --ant: use Ant for the packaging instead of Maven"
+ echo -e "\t-j --javadoc: resolve the Javadoc dependencies"
echo -e "\t-n --non-interactive: non interactive mode, don't ask questions"
echo -e "\t-o --offline: don't ever connect to the internet, for Debian build"
echo -e "\t compatibility."
@@ -37,10 +38,11 @@
exit 1
}
-ARGS="p package a ant v verbose n non-interactive o offline" parseargs "$@"
+ARGS="p package a ant d javadoc v verbose n non-interactive o offline" parseargs "$@"
PACKAGE=$(getarg p package)
ANT=$(getarg a ant)
+GEN_JAVADOC=$(getarg j javadoc)
NON_INTERACTIVE=$(getarg n non-interactive)
OFFLINE=$(getarg o offline)
VERBOSE=$(getarg v verbose)
@@ -66,6 +68,6 @@
fi
fi
-mvn org.debian.maven:maven-packager-utils:$MH_VERSION:dependencies -Dpackage="$PACKAGE" ${ANT:+-DpackageType=ant} -Dmaven.repo.local=/usr/share/maven-repo ${NON_INTERACTIVE:+-Dinteractive=false} ${OFFLINE:+-Doffline=true} ${VERBOSE:+-Dverbose=true} --offline
+mvn org.debian.maven:maven-packager-utils:$MH_VERSION:dependencies -Dpackage="$PACKAGE" ${ANT:+-DpackageType=ant} ${GEN_JAVADOC:+-DresolveJavadoc=true} -Dmaven.repo.local=/usr/share/maven-repo ${NON_INTERACTIVE:+-Dinteractive=false} ${OFFLINE:+-Doffline=true} ${VERBOSE:+-Dverbose=true} --offline
perl -p -i -e 's/maven\./maven:/' debian/${PACKAGE}.substvars
Modified: trunk/maven-debian-helper/debian/changelog
===================================================================
--- trunk/maven-debian-helper/debian/changelog 2011-06-08 21:36:06 UTC (rev 13769)
+++ trunk/maven-debian-helper/debian/changelog 2011-06-08 22:17:10 UTC (rev 13770)
@@ -11,8 +11,11 @@
* SysInstallDocMojo, SysInstallMojo: Drop initProperties method and only rely
on Maven mojo attributes injection of "debianPackage" and "destPackage".
Closes: #628693.
+ * mh_resolve_dependencies: New --javadoc param, send from maven.mk CDBS file
+ to automatically compute Javadoc dependencies when there is some *-doc
+ package. Closes: #628703.
- -- Damien Raude-Morvan <drazzib at debian.org> Wed, 08 Jun 2011 23:22:11 +0200
+ -- Damien Raude-Morvan <drazzib at debian.org> Thu, 09 Jun 2011 00:11:08 +0200
maven-debian-helper (1.4.2) unstable; urgency=low
Modified: trunk/maven-debian-helper/maven-packager-utils/src/main/java/org/debian/maven/packager/DependenciesMojo.java
===================================================================
--- trunk/maven-debian-helper/maven-packager-utils/src/main/java/org/debian/maven/packager/DependenciesMojo.java 2011-06-08 21:36:06 UTC (rev 13769)
+++ trunk/maven-debian-helper/maven-packager-utils/src/main/java/org/debian/maven/packager/DependenciesMojo.java 2011-06-08 22:17:10 UTC (rev 13770)
@@ -71,6 +71,11 @@
*/
protected String packageType;
/**
+ * Should we also resolve Javadoc dependencies
+ * @parameter expression="${resolveJavadoc}" default-value="false"
+ */
+ protected boolean resolveJavadoc;
+ /**
* Location for the list of POMs file.
* @required
* @parameter expression="debian/${package}.poms"
@@ -122,6 +127,7 @@
solver.setOutputDirectory(outputDirectory);
solver.setPackageName(packageName);
solver.setPackageType(packageType);
+ solver.setGenerateJavadoc(resolveJavadoc);
solver.setInteractive(interactive);
solver.setOffline(offline);
solver.setListOfPoms(listOfPoms);
Modified: trunk/maven-debian-helper/share/cdbs/1/class/maven-vars.mk
===================================================================
--- trunk/maven-debian-helper/share/cdbs/1/class/maven-vars.mk 2011-06-08 21:36:06 UTC (rev 13769)
+++ trunk/maven-debian-helper/share/cdbs/1/class/maven-vars.mk 2011-06-08 22:17:10 UTC (rev 13770)
@@ -67,6 +67,9 @@
# Extra arguments for the mh_patchpoms command line
DEB_PATCHPOMS_ARGS =
+# Extra arguments for the mh_resolve_dependencies command line
+DEB_RESOLVEDEP_ARGS =
+
# If true, install the Maven jars to /usr/share/java automatically
DEB_MAVEN_INSTALL_TO_USJ = true
Modified: trunk/maven-debian-helper/share/cdbs/1/class/maven.mk
===================================================================
--- trunk/maven-debian-helper/share/cdbs/1/class/maven.mk 2011-06-08 21:36:06 UTC (rev 13769)
+++ trunk/maven-debian-helper/share/cdbs/1/class/maven.mk 2011-06-08 22:17:10 UTC (rev 13770)
@@ -106,10 +106,14 @@
# extra arguments for the installation step
PLUGIN_ARGS = -Ddebian.dir=$(CURDIR)/debian -Ddebian.package=$(DEB_JAR_PACKAGE) -Dmaven.repo.local=$(DEB_MAVEN_REPO) -Dinstall.to.usj=$(DEB_MAVEN_INSTALL_TO_USJ)
+ifneq (, $(DEB_DOC_PACKAGE))
+DEB_RESOLVEDEP_ARGS += --javadoc
+endif
+
common-install-arch common-install-indep:: common-install-impl
common-install-impl::
$(if $(DEB_MAVEN_INSTALL_TARGET),$(DEB_MAVEN_INVOKE) $(PLUGIN_ARGS) $(DEB_MAVEN_INSTALL_TARGET), at echo "DEB_MAVEN_INSTALL_TARGET unset, skipping default maven.mk common-install target")
- $(if $(cdbs_use_maven_substvars), mh_resolve_dependencies --non-interactive --offline -p$(DEB_JAR_PACKAGE))
+ $(if $(cdbs_use_maven_substvars), mh_resolve_dependencies --non-interactive --offline -p$(DEB_JAR_PACKAGE) $(DEB_RESOLVEDEP_ARGS) )
ifeq (,$(findstring nocheck,$(DEB_BUILD_OPTIONS)))
common-build-arch common-build-indep:: debian/stamp-maven-check
More information about the pkg-java-commits
mailing list