Jeroen van der Meer wrote:
L.S.
FYI
I tried to compile mmbase(HEAD) on a debian box with j2sdk1.5.0_04 using
maven.
There was a library missing so I had to add it to maven-base/project.xml
197,202d196
< <groupId>commons-fileupload</groupId>
< <artifactId>commons-fileupload</artifactId>
< <version>1.0</version>
< <type>jar</type>
< </dependency>
< <dependency>
Then it compiled with maven:war and deployed it with maven
jboss:deploy-warfile
The deploying was not a great succes because the web.xml is missing in
the warfile.
Hello Jeroen,
"maven war" is not going to work, because it is a mmbase-module artifact
structure and not a maven war structure. There is not yet a maven
project to build a war file. I will make some time this week to create a
maven project which will create a war file similar to the binary
distribution. You can then use that as an example (starting point) for
your own mmbase web application.
Attached are some files I already created, which are not finished yet.
Nico
PS. What do I have to do to get a maven repository on the mmbase
machines for the mmbase maven artifacts? A maven repository is just a
normal directory in a http server.
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns:j="jelly:core"
xmlns:ant="jelly:ant"
xmlns:util="jelly:util"
xmlns:artifact="artifact"
xmlns:maven="jelly:maven">
<postGoal name="war:webapp">
<attainGoal name="mmbase-module:obtain-modules"/>
</postGoal>
<preGoal name="war:war">
<util:available file="${maven.war.webapp.dir}/WEB-INF/lib">
<fileScanner var="libScanner">
<fileset dir="${maven.war.webapp.dir}/WEB-INF/lib"/>
</fileScanner>
<j:forEach var="library" items="${libScanner.iterator()}">
<ant:unjar src="${library}" dest="${maven.war.webapp.dir}/WEB-INF/classes">
<patternset>
<include name="org/mmbase/config/**"/>
</patternset>
</ant:unjar>
</j:forEach>
</util:available>
<util:available file="${maven.war.webapp.dir}/WEB-INF/classes/org/mmbase/config/applications">
<fileScanner var="scanner">
<fileset dir="${maven.war.webapp.dir}/WEB-INF/classes/org/mmbase/config/applications"/>
</fileScanner>
<j:forEach var="dir" items="${scanner.directories()}">
<j:if test="${dir.path.endsWith('builders')}">
<ant:copy todir="${maven.war.webapp.dir}/WEB-INF/classes/org/mmbase/config/builders/applications">
<ant:fileset dir="${dir.path}"/>
</ant:copy>
</j:if>
</j:forEach>
</util:available>
<util:available file="${maven.war.webapp.dir}/WEB-INF/config/applications">
<fileScanner var="scanner">
<fileset dir="${maven.war.webapp.dir}/WEB-INF/config/applications"/>
</fileScanner>
<j:forEach var="dir" items="${scanner.directories()}">
<j:if test="${dir.path.endsWith('builders')}">
<ant:copy todir="${maven.war.webapp.dir}/WEB-INF/config/builders/applications">
<ant:fileset dir="${dir.path}"/>
</ant:copy>
</j:if>
</j:forEach>
</util:available>
</preGoal>
</project>#The artifact type that is produced when multiproject:deploy is run
maven.multiproject.type=war
# Override the value set in maven-base
war.bundle=true
maven.tomcat.precompile=false
maven.license.licenseFile=${basedir}/../maven-base/MPL10.txt<?xml version="1.0" encoding="UTF-8"?>
<!--
This software is OSI Certified Open Source Software.
OSI Certified is a certification mark of the Open Source Initiative.
The license (Mozilla version 1.0) can be read at the MMBase site.
See http://www.MMBase.org/license
-->
<project>
<extend>${basedir}/../maven-base/project.xml</extend>
<artifactId>example</artifactId>
<shortDescription>MMbase example web application</shortDescription>
<dependencies>
<dependency>
<groupId>mmbase</groupId>
<artifactId>mmbase</artifactId>
<version>${mmbase.version}</version>
<type>mmbase-module</type>
</dependency>
<dependency>
<groupId>mmbase</groupId>
<artifactId>mmbase-cloudcontext</artifactId>
<version>${mmbase.version}</version>
<type>mmbase-module</type>
<properties>
<mmbase.templates.path>mmbase/security</mmbase.templates.path>
</properties>
</dependency>
<dependency>
<groupId>mmbase</groupId>
<artifactId>mmbase-editwizard</artifactId>
<version>${mmbase.version}</version>
<type>mmbase-module</type>
<properties>
<mmbase.templates.path>mmbase/edit/wizard</mmbase.templates.path>
</properties>
</dependency>
<dependency>
<groupId>mmbase</groupId>
<artifactId>mmbase-dove</artifactId>
<version>${mmbase.version}</version>
<type>jar</type>
<properties>
<war.bundle>${war.bundle}</war.bundle>
</properties>
</dependency>
<dependency>
<groupId>mmbase</groupId>
<artifactId>mmbase-taglib</artifactId>
<version>${mmbase.version}</version>
<type>jar</type>
<properties>
<war.bundle>${war.bundle}</war.bundle>
</properties>
</dependency>
</dependencies>
</project>_______________________________________________
Developers mailing list
[email protected]
http://lists.mmbase.org/mailman/listinfo/developers