>
> First off - it looks like you have added your extension directory inside
> the
> merlin directory - which is definately *not* a good thing to do!  You
> should
> locate this somewhere independent of the merlin source tree.
    I've done it. I created my own project with the following structure:

/MyMerlin
    /api
        /src
            /java
    /impl
        /conf
            jemos-hello.block
        /src
            /java
                /<<mypackage>>
                    HelloComponent.java
                    HelloComponent.xinfo
            /test
        project.properties     (under /impl)
        project.xml              (under /impl)

I defined project.xml as follows:

<?xml version="1.0" encoding="ISO-8859-1"?>
<project>
<extend>${merlin.root.dir}/project.xml</extend>
<groupId>jemos/avalon/merlin</groupId>
<id>jemos-hello</id>
<name>Jemos Hello Trial</name>
<package>org.jemos.avalon.merlin</package>
<currentVersion>1.0</currentVersion>
<inceptionYear>2003</inceptionYear>
<shortDescription>Jemos Hello Trial</shortDescription>
<description>
'Hello' Jemos Trial
</description>
<dependencies>
<dependency>
<groupId>avalon-framework</groupId>
<artifactId>avalon-framework-api</artifactId>
<version>4.1.5</version>
</dependency>
<dependency>
<groupId>merlin</groupId>
<artifactId>merlin-unit</artifactId>
<version>3.2.6-dev</version>
</dependency>
</dependencies>
</project>


I defined the project as extending the avalon CVS distribution (copied from
the hello example). The only thing I defined a merlin.root.dir pointing to
the avalon CVS source directory, as my project is completely independent
from the avalon tree (as suggested by you). I copied brutally the .xinfo and
.block file from the Merlin documentation
(http://avalon.apache.org/merlin/starting/tutorial/creation.html). I didn't
specified a project.xml file under /api as this example doesn't have any
interface/exception.

When I run "maven" from MyMerlin/impl I obtain the following error:

D:\Projects\myMerlin\impl>maven
 __  __
|  \/  |__ _Apache__ ___
| |\/| / _` \ V / -_) ' \  ~ intelligent projects ~
|_|  |_\__,_|\_/\___|_||_|  v. 1.0-rc1-SNAPSHOT

Starting the reactor...
Our processing order:
Starting the reactor...
Our processing order:
Starting the reactor...
Our processing order:
merlin:build:
merlin:plugin:


xinstall:
    [mkdir] Created dir: D:\Projects\myMerlin\impl\target\merlin
    [mkdir] Created dir: D:\Projects\myMerlin\impl\target\merlin\ext
    [mkdir] Created dir: D:\Projects\myMerlin\impl\target\merlin\bin\lib

BUILD FAILED
File...... file:/D:/Projects/myMerlin/impl/
Element... ant:copy
Line...... 97
Column.... 50
Warning: Could not find file
D:\Projects\myMerlin\impl\kernel\cli\target\merlin-cli-3.2-dev.jar to c
opy.
Total time: 2 seconds
Finished at: Tue Dec 16 23:18:33 GMT 2003

D:\Projects\myMerlin\impl> Now, I can understand that the extended project
will look for local folders (/impl/kernel/...). My question is: how could I
obtain a component to test from a project outside the main CVS tree? (as you
predicted, this was the next step).

Also, I noted that by extending the root project, my project.xml doesn't
define the build section, therefore if I wouldn't specify a super-project,
my project couldn't compile, unless I would define the build section.

The other question is: what do I really need to create the testable
component? Do I need to compile and create a jar? Do I need something else?
The Merlin documentation at the above address talks about the avalon:meta
plugin to build automatically the .xinfo files, but it doesn't explain how
to use it. I had a look at the maven documentation but I'm not experienced
yet.

Any help would be appreciated.

Thanks,

Marco


>Once you have
> got your package out of the merlin tree you need to do the following:
>
> 1. add a project.xml file into the api directory and another in the impl
>    directory.
> 2. make sure these two project.xml files contain the correct dependencies
>    for each subproject (the errors you posted are a result of not
including
>    an avalon-framework-api dependency - take a look at the hello example
>    project.xml for details)
> 3. once you get both the api amd impl suprojects building nicely you may
>    want to put in place a parent project.xml and play around with the
>    things you can do with a parent maven.xml to automate the build of
>    both your api and impl subprojects (but worry about this later)
>




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to