[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Packages required for trunk build of OpenMRS with MavenBuilder - next steps?




Hello Misha,

I am the author of Maven builder, so I hope I can help here.

First, the tools are still under development, they are usable for simple libraries and Maven plugins, but not quite yet for big projects.

You will have more luck by taking the latest versions of maven-repo-helper and maven-debian-helper at my repository:
https://launchpad.net/~ludovicc/+archive/ppa/

To build OpenMRS for Debian, we will need to package all dependencies and plugins in Debian. Some are already there and an apt-get install away:

libmaven-javadoc-plugin-java contains org.apache.maven.plugins:maven-javadoc-plugin:2.6.1,
libantlr-maven-plugin-java contains org.codehaus.mojo:antlr-maven-plugin:2.1
libmaven-antrun-plugin-java contains org.apache.maven.plugins:maven-antrun-plugin:1.4 libspring-java (in experimental) contains org.springframework:spring-test:3.0.2.RELEASE

The other dependencies are not packaged in Debian (as far as I can tell), but it should be quite easy to do the packaging yourself using mh_make. You need to file an ITP (Intention to package) bug request following the guidelines at http://www.debian.org/devel/wnpp/. Or file a RFP (request for package) at the same place, hoping that somebody else will do the job (hint: some requests are more than 1000 days old) but I will try to help you of course. Consider also joining the pkg-java team, you don't need to be a Debian Developer to participate. http://pkg-java.alioth.debian.org/

I will animate a little workshop on Maven & packaging at the Debian mini Debconf on Oct 30th, I'll try to publish some material after that and bring the wiki pages up to date.

Ludovic

On 10/15/2010 05:51 PM, Misha Koshelev wrote:

Dear All:

I am currently working with the Debian Med team, who has been very
helpful, to package OpenMRS. Please see http://www.openmrs.org and
svn://cvs.alioth.debian.org/svn/debian-med/trunk/packages/openmrs/trunk

Fortunately, the latest release version is an ant build and works well
with the dh $@ command in the Makefile (debhelper).

Unfortunately, for the Maven build on the trunk version, it is not so
simple. The biggest problem, if using the
http://wiki.debian.org/Java/MavenBuilder
tool, is that some of the plugins and dependencies are not currently
in the Debian package repository:

pom.xml: Plugin is not packaged in the Maven repository for Debian:
org.openmrs.codehaus.mojo:buildnumber-maven-plugin:1.0-beta-4-mod
pom.xml: Plugin is not packaged in the Maven repository for Debian:
org.apache.maven.plugins:maven-javadoc-plugin:2.6.1
test/pom.xml: Dependency is not packaged in the Maven repository for
Debian: org.springframework:spring-test:3.0.2.RELEASE
api/pom.xml: Dependency is not packaged in the Maven repository for
Debian: org.azeckoski:reflectutils:0.9.14
api/pom.xml: Plugin is not packaged in the Maven repository for
Debian: org.codehaus.mojo:antlr-maven-plugin:2.1
web/pom.xml: Dependency is not packaged in the Maven repository for
Debian: org.openmrs.api:openmrs-api:1.8.0-SNAPSHOT
webapp/pom.xml: Plugin is not packaged in the Maven repository for
Debian: org.apache.maven.plugins:maven-antrun-plugin:1.4

(this is also listed on http://tickets.openmrs.org/browse/TRUNK-1811)

With the acception of org.openmrs.api:openmrs-api:1.8.0-SNAPSHOT,
which is provided in a maven module that is being compiled within
trunk, the others would be in need of packaging.

This is complicated by the fact that we are using our own maven repo as well:
	<distributionManagement>
		<repository>
			<id>openmrs-repo-releases</id>
			<name>OpenMRS Nexus Releases</name>
			<url>http://mavenrepo.openmrs.org/nexus/content/repositories/releases</url>
		</repository>
		<snapshotRepository>
			<id>openmrs-repo-snapshots</id>
			<name>OpenMRS Nexus Snapshots</name>
			<url>http://mavenrepo.openmrs.org/nexus/content/repositories/snapshots</url>
		</snapshotRepository>
	</distributionManagement>
which, to my understanding, has some packages that are not included in
the main Maven repos.

In any case, I was wondering:
a) is my understanding correct that, indeed, the above plug-ins and
dependencies (or _any_ we use) have to be in Debian repositories
before a proper _trunk_ package with the Maven build would be
accepted?
b) how would one go about getting these dependencies into Debian repo?
Do I file a bug somewhere, etc?

Thank you
Misha

p.s. Lastly, I was wondering if Maven support actually is supposed to
work with javahelper
http://wiki.debian.org/Java/Packaging

There is this mysterious section on that page:
"Maven

We need some information about Maven here."

and I did an
apt-get source javahelper

which showed that jh_makepkg (I believe sorry do not have available at
the moment) actually does have some calls to mvn, but in my brief
testing it did not actually do anything for a Maven build :(

Thank you

Yours
Misha




Reply to: