How should one handle 3rd party libraries in Maven2..
Hi, A question I'm sure have been on the mailing-lists before (but I could not find it) regarding how to handle 3rd party JARs: I am using some 3rd party JARs which does not exsist in the global Maven2 repository ( http://repo1.maven.org/maven2/). I've found some references on the web to using mvn install:install-file or mvn deploy:deploy-file to add these jars to my repository. The mvn install:install-file works OK to install in my local repository, but when I try installing to our company-wide repository using mvn deploy:deploy-file and an FTP-URL, I get an error about missing Wagon for FTP. Ideally, I would have liked to set up a Maven2 project holding the JAR in question (almost as a source), setting up all I need (groupID, artifactID, version etc.) in the project pom, and then do mvn deploy on the project, resulting in the correct JAR beeing deployed to our thirdparty repository. Whenever the thirdparty library changes (new version released etc.), I could download the new Jar, updated the version in my pom, and do a mvn deploy. This would mean a maven2 project with no source (java source). Would this work, and if so, how should I set up such a project ? ..or am I totally on the wrong path here ? Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What format is recommended for documentation when using mvn site ?
Hi all, Thanks for the input. I've browsed the net, and checked the supplied links too, and I think my conclusion on this issue is that this is an area still not very well covered in Maven2. I think I'll have a look at the Doxia plugin, to try to keep as Maven2 standardized as possible for now. I see that DocBook now is supported (both parser and sink) with the Doxia plugin, so I might try this first. Anyway, thank you all for the inputs! Arne I've also seen mentioned that there is work going on to create PDF from apt and xdoc. I also saw that for maven1, the xdoc format was the recomended format to use for any user specific documentation. What is the status for xdoc and Maven2 ? Do you know ? I am not the responsible of the doxia project and I don't know it too much. For the moment I use the xdoc format. I was also expecting a generated PDF output but It seems that feature is not available at the moment. But I hope that the docbook format and plugin will provide a good solution for this. It's will be nice if you can test it et get a feed back. I have a friend that work on it. Rémy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What format is recommended for documentation when using mvn site ?
Do you know anything about the LaTeX plugin that used to be supported in Maven1 ? LaTeX seams to be the favoured format for scientific documentation still, and it would be nice if this was supported By the way, what SW do you use to read these mailing lists ? Arne I've also seen mentioned that there is work going on to create PDF from apt and xdoc. I also saw that for maven1, the xdoc format was the recomended format to use for any user specific documentation. What is the status for xdoc and Maven2 ? Do you know ? I am not the responsible of the doxia project and I don't know it too much. For the moment I use the xdoc format. I was also expecting a generated PDF output but It seems that feature is not available at the moment. But I hope that the docbook format and plugin will provide a good solution for this. It's will be nice if you can test it et get a feed back. I have a friend that work on it. Rémy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
What format is recommended for documentation when using mvn site ?
Hi, We have a large multimodule project using maven2, and Continuum. We've just started to look into the site-goal, and if I've understood correctly, it is possible to also create project documentation/system documentation that will be generated when running the site goal. According to the doc of maven2, the formats apt, xdoc and fml are supported. LaTeX used to be supported, but has been removed (anyone knows why?). With project documentation I mean design specifications, technical documents etc., other than the reports that can be automatically generated (like javadoc, xref etc.). What is the common practice here, and which format is recommended ? APT seams to me to be a bit to unstructured for larger documents... Also it would be nice if it was possible to generate both html and PDF-files from the same source. Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: What format is recommended for documentation when using mvn site ?
Hi Remy, Thanks. I'll check it out. I've also seen mentioned that there is work going on to create PDF from apt and xdoc. I also saw that for maven1, the xdoc format was the recomended format to use for any user specific documentation. What is the status for xdoc and Maven2 ? Do you know ? Arne Have a look at the docbook format http://www.nabble.com/forum/Search.jtp?forum=178local=yquery=docbook and the corresponding plugin named docbkx-tools ( http://code.google.com/p/docbkx-tools/) http://www.nabble.com/Any-tool-available-for-generating-docs-from-pom.xml--td1 5036590s177.html#a15061807 Rémy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Where should I place UML-models in a Maven2 structure..
Hi Milos, Thanks for confirming my own thoughts ;-) I totally agree that the UML-model should be just another aspect of the project. That would have made it much more structured. Do you know of any other UML modelling tool that does integrate well with the Maven2 structure ? Thanks! Arne On 12/1/07 9:33 AM, Milos Kleint [EMAIL PROTECTED] wrote: Hello, src/main/uml is fin I guess. Please be aware of the fact that the netbeans UML integration creates an UML project there. Then for example when you commit your changes to the maven project to svn, the uml part won't be picked up automatically (as it belongs to another project). It would be much better if UML were just an additional aspect of any project type in Netbeans but it's not that way. I haven't used UML+maven extensibly, there used to some problems back in 5.0/5.5 times I think but everything seems to work without problems in 6.0. Milos Kleint On Nov 30, 2007 2:43 PM, Arne Styve [EMAIL PROTECTED] wrote: Hi, I want to use the UML-editor in Netbeans 6.0RC2 to model my application. I use the Mevenide-plugin, and have created my Java-project according to the Maven2 directory structure. My question is then, where should the UML-model files be placed in the Maven2 Structure ? Under src/main/uml for instance ? Anyone having used the UML-editor in Netbeans together with a Maven2 project ?? And just for the record: I am talking about real UML-modelling, as part of Roundtrip Engineering, not the generation of UML-diagrams as part of the Javadoc, just so that is clear :-) Looking forward to here some ecxperiences :-) Kind regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Where should I place UML-models in a Maven2 structure..
Hi, I want to use the UML-editor in Netbeans 6.0RC2 to model my application. I use the Mevenide-plugin, and have created my Java-project according to the Maven2 directory structure. My question is then, where should the UML-model files be placed in the Maven2 Structure ? Under src/main/uml for instance ? Anyone having used the UML-editor in Netbeans together with a Maven2 project ?? And just for the record: I am talking about real UML-modelling, as part of Roundtrip Engineering, not the generation of UML-diagrams as part of the Javadoc, just so that is clear :-) Looking forward to here some ecxperiences :-) Kind regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: M2: how to create jni .jar .so file from same pom.xml
Hi Joe, There is an alternative to the native-maven-plugin: http://java.freehep.org/freehep-nar-plugin/index.html I had a look at both a while ago, and concluded that the NAR-approach was a better way of doing it than the native-maven-plugin approach. Don't know if that is still valid though, but it is worth having a look. Regards Arne Hi I attempting to migrate from maven to maven2. I have an existing project which creates a jar file and a corresponding .so file I'd like to be avoid changing the existing directory structure which looks like project - (pom.xml ) project/src/java - (*.java) project/src/unix - (*.c *.h) the pom.xml is below if I set the packaging to jar. it creates the jar file if I set it to .so it creates the .so file how do i get it to do both at the same time thanks! --joe - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Can properties in settings.xml be used inside settings.xml ?
Hi A quick semi-newbie question: If I define a property within settings.xml (the one found at maven_home/conf), can that property be used within the same setting.xml file ? Example: settings xmlns=http://m. profiles profile idtest/id !-- Some properties -- properties !-- The root domain -- server.rootportal.mycompany.com/server.osc.root !-- The HTTP URL to the Company Maven2 repositories -- mavenrepos.httpurlhttp://${server.root}/maven2/mavenrepos.httpurl /properties .. repositories repository idmycompany.thirdparty/id nameMyCompany Internal Thirdparty Repository/name url${mavenrepos.httpurl}/Thirdparty/url layoutdefault/layout /repository /repositories ... /profile /profiles . /setting I've tried this, and it seems that the properties are not substituted with their values when I use ${mavenrepos.httpurl} as in the repositories-section. Is this correct, or have I missed out on something here ? Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Parent POM and versions...
Hi, I have a question related to the use of a company POM. In Better builds with Maven there is a description of how to set up a POM regime for a company, where we can have say 3 levels of POM's: one companywide POM, one department wide POM and one projectspecific POM. Lets call these with the following geoupId com.mycompany and Artifact Ids: Company pom : mycompany Department pom : mydepartment Project pom: someproject The company pom will be something like: project modelversion... groupIdcom.mycompany/groupId artifactIdmycomapny/artifactId version1version . /project The department pom would initially be something like: project modelversion... parent groupIdcom.mycompany/groupId artifactIdmycomapny/artifactId version1version /parent groupIdcom.mycompany/groupId artifactIdmydepartment/artifactId version1version . /project and finally, the project POM would initially be something like project modelversion... parent groupIdcom.mycompany/groupId artifactIdmydepartment/artifactId version1version /parent groupIdcom.mycompany/groupId artifactIdsomeproject/artifactId version1.0-SNAPSHOTversion . /project Now, what happens if I need to update the company POM ? I will update it, and set it to version 2. How can I then ensure that all my current projects will be using the new version of my company POM (available, offcourse from our company repository) ? Do I have to update the department pom so that it's parent now becomes v2 of the company POM, or will Maven use version 1 or whichever is newer of the company POM (ie. the v2) ? The same goes for the project POM. I recon if I need to update the department POM as a result of haveing updated the company POM, I also need to update the project POM to use version 2 of the department POM ? Is there no way of saying that I want the latest version of a POM to be the parent POM ? Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Version Management
Hi Hermant, No, Maven cannot be used as a Version management tool. Maven is a build tool, an advanced build tool. You can, however, interact with a version management tool (like Subversion) from within Maven, so that Maven performs checking in and checking out (commit and update) to and from Subversion for you as part of the automated build process. Regards Arne -Original Message- From: Hemant Ved [mailto:[EMAIL PROTECTED] Sent: 16. august 2007 12:59 To: [EMAIL PROTECTED] Subject: Version Management Hi Can Maven be used as a Version mangement tool? Is it possible to automate the Version management using Maven? Thanks and Regards Hemant Ved - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Anyone used the NAR plugin for native code ?
Hi, I'm currently looking into the NAR plugin from the FreeHEP site (http://java.freehep.org/freehep-nar-plugin/), and have some questions regarding the use of this plugin. I'm building a JNI-library from a Java class, on a x86-Windows platform. Currently I have two issues: 1. When I use Microsoft C++ compiler and linker (msvc), I can build my project from the Visual Studio 2005 commandline window, but not from any command window, neither from within the Netbeans (v5.5.1) IDE I'm using. Any ideas why ? 2. When I use the g++ compiler, the NAR-plugin doesn't seem to find the C++ source file to compile. I get 0 total files to be compiled: [INFO] [freehep-nar:nar-javah] [INFO] Running javah compiler on 1 classes... [INFO] [freehep-nar:nar-compile] [INFO] Project base dir set to: C:\Documents and Settings\asty\Skrivebord\linemodel [INFO] 0 total files to be compiled. [INFO] Starting link (3.4.4 -shared -lstdc++ -shared-libgcc) [INFO] gcc -shared -o liblinemodel-1.0-SNAPSHOT.so -lstdc++ -shared-libgcc [INFO] [resources:testResources] [INFO] Using default encoding to copy filtered resources. [INFO] [compiler:testCompile] Finally, my C++ implementation of the JNI library is dependent on a third party DLL (or LIB) not found in any repository. Where in the directorystructure should I place this DLL (or LIB) for the C++ linker to find it and include it ? Regards Arne
How do I set up a project for my root POM ?
Hi, We have setup our development system based on a companywide root POM which is stored in our company repository. When we first created this root POM, I created the POM and deployed it to the company repository from the commandline on the server hosting the company repository. HREowever, it would be nice to create a Maven2 project which had the root POM as source so that when I deploy the project, the root POM would be deploied to the company repository using FTP like any other of our Maven2 projects. How do I set up a project where the result is a POM, and where do I place the root POM (as source) ? I.e. I end up with two POM's, one beeing the root POM itself as a source, and the other the POM for the project... Any ideas ? Regards Arne
RE: How do I set up a project for my root POM ?
Hi Kristian, -Original Message- From: Kristian Nordal [mailto:[EMAIL PROTECTED] Sent: 11. juni 2007 12:11 To: Maven Users List Subject: Re: How do I set up a project for my root POM ? Hi, On 6/11/07, Arne Styve [EMAIL PROTECTED] wrote: Hi, We have setup our development system based on a companywide root POM which is stored in our company repository. When we first created this root POM, I created the POM and deployed it to the company repository from the commandline on the server hosting the company repository. HREowever, it would be nice to create a Maven2 project which had the root POM as source so that when I deploy the project, the root POM would be deploied to the company repository using FTP like any other of our Maven2 projects. How do I set up a project where the result is a POM, and where do I place the root POM (as source) ? I.e. I end up with two POM's, one beeing the root POM itself as a source, and the other the POM for the project... Set the packaging element in the pom.xml to pom. See: http://maven.apache.org/guides/introduction/introduction-to-th e-pom.html#Super%20POM You should be able to deploy this module (with only a pom.xml) like any other module. You are so right. By performing a mvn deploy the pom in question was deploied to the company repository. Thanks! By the way, what client do you use to read this mailinglist ? Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SV: Maven, DLLs and repositories...how ?
Hi Jason, Thanks for your input. I'll give this a try. However, how do you then use the JAR containing all the DLLs and .so's ? As far as I've understood, you cannot access a DLL that is inside a JAR, and hence you have to extract the DLLs from the JAR in order to use the DLL. Is this correct ? Regards Arne On Tue, June 5, 2007 10:07 am, Arne Styve wrote: I have a question related to using DLLs with Maven. We colaborate with a company that develops parts of our system. They deliver their component as a set of DLLs. I've used JNI to create a Java interface to these DLL, so that I can use Java to develop the software that will use the DLLs. How can I set up a Maven2 project that takes these DLLs and deploy them correctly to our company repository, so that I in my project, where I am going to use the DLLs, can add dependencies to the DLLs the usual Maven2 way ? I.e. this project will not have any sourcefiles, only the 4 DLLs. We faced the same problem. Originally we tried to publish the DLL artifact into the repository directly, but this caused problems for us, as our JNI native code had to run on Windows, Linux and Solaris, and maintaining the proper naming conventions and suffixes was a pain. We eventually opted to wrap the JNI DLLs / .so files inside a jar, and publish the jar in the repository, including a classifier to show both the platform (windows / linux / solaris) and architecture (x86, amd64, etc). From that point on we only needed to worry about the name of the jar, which was consistent across platforms. When you have multiple DLLs, putting them in a jar reduces them down from many artifacts to one artifact, which is easier to deal with. This is the pom we use, it should give some clues. The DLLs are built by ant using the antrun plugin, and maven worries about the packaging and deployment: project xmlns=http://maven.apache.org/POM/4.0.0; xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance; xsi:schemaLocation=http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd; modelVersion4.0.0/modelVersion parent artifactIdalchemy-ii-native/artifactId groupIdalchemy/groupId version4.0.30-SNAPSHOT/version /parent artifactIdalchemy-cdo/artifactId packagingjar/packaging nameAlchemy Native CDO/name descriptionPlaceholder for the CDO stuff from London/description build extensions extension groupIdorg.apache.maven.wagon/groupId artifactIdwagon-webdav/artifactId version1.0-beta-2/version /extension /extensions sourceDirectorysrc/main/java/sourceDirectory !--testSourceDirectorysrc/testSourceDirectory-- resources resource directorytarget/build/directory includes include*.dll/include /includes /resource resource directorytarget/build/directory includes include*.dylib/include /includes /resource resource directorytarget/build/directory includes include*.so/include /includes /resource resource directorysrc/main/resources/directory filteringtrue/filtering includes includealchemy-cdo-version.properties/include /includes /resource /resources plugins plugin groupIdorg.codehaus.mojo/groupId artifactIdnative-maven-plugin/artifactId extensionstrue/extensions !-- Generate JNI header files based on a list of class name on the classpath -- !-- The generated include directory is automatically added to include path at compile phase -- !-- Ensure to have appropriate denpendency jar file(s) in your pom -- executions execution idjavah/id phasegenerate-sources/phase configuration classNames classNamealchemy.cdo.measure.CDOTranche/className /classNames !-- | Note: |1. Without classNames, javah mojo will search for all JNI classes | in your dependency list. -- /configuration goals goaljavah/goal /goals /execution /executions /plugin !-- trigger the ant build -- plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution id2antrun/id phaseprocess-sources/phase!-- needs to run BEFORE resources -- configuration tasks ant target=compile-cc-${os-platform} / /tasks /configuration goals goalrun/goal /goals /execution /executions dependencies dependency groupIdant-contrib/groupId
RE: SV: Maven, DLLs and repositories...how ?
On Wed, June 6, 2007 8:50 am, Arne Styve wrote: Thanks for your input. I'll give this a try. However, how do you then use the JAR containing all the DLLs and .so's ? As far as I've understood, you cannot access a DLL that is inside a JAR, and hence you have to extract the DLLs from the JAR in order to use the DLL. Is this correct ? In our case, we create a final assembly that either copies or unpacks the various artifacts and places them where they need to be in the assembly. We have Matlab produced artifacts (which aren't unpacked) and DLLs-wrapped-in-jars (which are unpacked) that go into the assembly, which we then give to the production guys for deployment. A second approach which we also use in one or two places is to use the dependency plugin to copy and or unpack jars, and place them in various places where necessary. Great, thanks Graham ! Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Maven, DLLs and repositories...how ?
Hi, I have a question related to using DLLs with Maven. We colaborate with a company that develops parts of our system. They deliver their component as a set of DLLs. I've used JNI to create a Java interface to these DLL, so that I can use Java to develop the software that will use the DLLs. How can I set up a Maven2 project that takes these DLLs and deploy them correctly to our company repository, so that I in my project, where I am going to use the DLLs, can add dependencies to the DLLs the usual Maven2 way ? I.e. this project will not have any sourcefiles, only the 4 DLLs. Regards Arne
SV: Problems finding custom archetype...
Hi again Wendy, You made my day ;-) I had version 1.0-alpha-3. Upgraded to 1.0-alpha-4, and it worked. Thank you very much!! Regards Arne Fra: Wendy Smoak [mailto:[EMAIL PROTECTED] Sendt: må 14.05.2007 18:08 Til: Maven Users List Emne: Re: Problems finding custom archetype... On 5/14/07, Arne Styve [EMAIL PROTECTED] wrote: Hi Wendy, Her is the command and the resulting output. Would be greate if you are able to spot the error: ... [INFO] Failed to resolve artifact. GroupId: no.offsimcentre ArtifactId: osc-archetype-simple Version: 1.0-SNAPSHOT Reason: Unable to download the artifact from any repository Try downloading the file manually from the project website. Then, install it using the command: mvn install:install-file -DgroupId=no.offsimcentre -DartifactId=osc-archetype-simple \ -Dversion=1.0-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file no.offsimcentre:osc-archetype-simple:jar:1.0-SNAPSHOT from the specified remote repositories: central (http://repo1.maven.org/maven2) It's not checking your internal repository. The remoteRepositories parameter was added at some point... what version of the archetype plugin are you using? mvn help:describe -Dplugin=archetype Try adding -U on the command line to get Maven to update its plugins. -- Wendy - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Problems finding custom archetype...
Hi, I've tried to build my own archetype to use when new projects are to be created here at our company. I've followed the recepie at http://maven.apache.org/plugins/maven-archetype-plugin/examples/archetype.html, and my new archetype works fine when running it from the same machine as it was created (and installed in the local repository). I then deploy the artifact to our company repository (snapshot). When I now try to create a new project on a different PC, using the newly created archetype, Maven is not able to find the archetype. I have included the pluginRepositories-tag in my settings.xml file, and I am using the same Maven2 repository for plugins as for other artifacts. What might the problem bee ? Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
SV: Problems finding custom archetype...
Hi Wendy, I then deploy the artifact to our company repository (snapshot). When I now try to create a new project on a different PC, using the newly created archetype, Maven is not able to find the archetype. I have included the pluginRepositories-tag in my settings.xml file, and I am using the same Maven2 repository for plugins as for other artifacts. What might the problem be ? Use -DremoteRepositories on the command line, as described here: http://maven.apache.org/plugins/maven-archetype-plugin/examples/remote-repositories.html I've tried this too, but still it will not work. When I chekout the archetype project (that is used to create the archetype), and do a mvn install, then creating a new project using the new archetype works fine on this PC too. Arne
SV: Problems finding custom archetype...
Hi Wendy, Her is the command and the resulting output. Would be greate if you are able to spot the error: C:\tmpmvn archetype:create \ -DgroupId=no.offsimcentre \ -DartifactId=testing \ -DarchetypeGroupId=no.offsimcentre \ -DarchetypeArtifactId=osc-archetype-simple \ -DarchetypeVersion=1.0-SNAPSHOT \ -DremoteRepositories=http://osc.hials.no/maven2/Snapshots [INFO] Scanning for projects... [INFO] Searching repository for plugin with prefix: 'archetype'. [INFO] - --- [INFO] Building Maven Default Project [INFO]task-segment: [archetype:create] (aggregator-style) [INFO] - --- [INFO] Setting property: classpath.resource.loader.class = 'org.codehaus.plexus .velocity.ContextClassLoaderResourceLoader'. [INFO] Setting property: resource.loader = 'classpath'. [INFO] ** [INFO] Starting Jakarta Velocity v1.4 [INFO] RuntimeInstance initializing. [INFO] Default Properties File: org\apache\velocity\runtime\defaults\velocity.properties [INFO] Default ResourceManager initializing. (class org.apache.velocity.runtime.resource.ResourceManagerImpl) [INFO] Resource Loader Instantiated: org.codehaus.plexus.velocity.ContextClassLoaderResourceLoader [INFO] ClasspathResourceLoader : initialization starting. [INFO] ClasspathResourceLoader : initialization complete. [INFO] ResourceCache : initialized. (class org.apache.velocity.runtime.resource.ResourceCacheImpl) [INFO] Default ResourceManager initialization complete. [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Literal [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Macro [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Parse [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Include [INFO] Loaded System Directive: org.apache.velocity.runtime.directive.Foreach [INFO] Created: 20 parsers. [INFO] Velocimacro : initialization starting. [INFO] Velocimacro : adding VMs from VM library template : VM_global_library.vm [ERROR] ResourceManager : unable to find resource 'VM_global_library.vm' in any resource loader. [INFO] Velocimacro : error using VM library template VM_global_library.vm : org.apache.velocity.exception.ResourceNotFoundException: Unable to find resource 'VM_global_library.vm' [INFO] Velocimacro : VM library template macro registration complete. [INFO] Velocimacro : allowInline = true : VMs can be defined inline in templates [INFO] Velocimacro : allowInlineToOverride = false : VMs defined inline may NOT replace previous VM definitions [INFO] Velocimacro : allowInlineLocal = false : VMs defined inline will be global in scope if allowed. [INFO] Velocimacro : messages on : VM system will output logging messages [INFO] Velocimacro : autoload off : VM system will not automatically reload global library macros [INFO] Velocimacro : initialization complete. [INFO] Velocity successfully started. [INFO] [archetype:create] [INFO] Defaulting package to group ID: no.offsimcentre [INFO] [ERROR] BUILD ERROR [INFO] [INFO] Failed to resolve artifact. GroupId: no.offsimcentre ArtifactId: osc-archetype-simple Version: 1.0-SNAPSHOT Reason: Unable to download the artifact from any repository Try downloading the file manually from the project website. Then, install it using the command: mvn install:install-file -DgroupId=no.offsimcentre -DartifactId=osc-archetype-simple \ -Dversion=1.0-SNAPSHOT -Dpackaging=jar -Dfile=/path/to/file no.offsimcentre:osc-archetype-simple:jar:1.0-SNAPSHOT from the specified remote repositories: central (http://repo1.maven.org/maven2) [INFO] [INFO] For more information, run Maven with the -e switch [INFO] [INFO] Total time: 1 second [INFO] Finished at: Mon May 14 17:44:34 CEST 2007 [INFO] Final Memory: 4M/7M [INFO] C:\Documents and Settings\asty\Skrivebord
RE: Problems with maven-assembly-plugin from Netbeans 5.5...
Hi Antonio I'm trying to use the maven-assembly-plugin from within Netbeans 5.5 (with Mavenide installed), but when executing the goal assembly:assembly, I get the following message when using the predefined descriptor jar-with-dependencies: Embedded error: C:\Programfiler\netbeans-5.5\target\classes isn't a directory. but my project is not placed under the C:\Programfiler\netbeans-5.5 -folder. I think that it is a bug in assembly plugin version 2.1. We had a similar problem with Tiles. Try using the 2.2-SNAPSHOT version of the assembly plugin. Antonio I tried adding version2.2-SNAPSHOT/version to the module plugin, but it didn't find it. How should I og about getting the 2.2 version ? Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Ant generated JAR file to be handeled with Maven...how?
Hi Kevin -Original Message- From: Kevin Stembridge [mailto:[EMAIL PROTECTED] Sent: 20. april 2007 14:19 To: Maven Users List Subject: RE: Ant generated JAR file to be handeled with Maven...how? Hi Arne, I've never used it, but this plugin sounds like it might be what you want. http://mojo.codehaus.org/build-helper-maven-plugin/ Thanks Kevin. That is absolutely an alternative. I'll have a look at it. Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Ant generated JAR file to be handeled with Maven...how?
Hi I have a project based on an Ant build.xml file. I want to keep this build-file, and keep building the project it self using this build-file and Ant, but to wrap Maven2 around it. I've managed to call the ant-build file (build.xml) from my POM, and it works fine. However, the Ant script produses a JAR not known to Maven, and Maven ends up creating a JAR on its own, which is empty. I want to take the JAR file generated by Ant, making Maven aware of it, and deploy it (from my POM) in our company Maven2 repo using the groupId-artifactId-version concept. How do I go about to get this to work ? Any ideas ? Maybe this: http://maven.apache.org/ant-tasks.html will help you? Regards, Tomek Thanks, but it was not quite what I was looking for, rather the other way around. I do not want to do anything with my exsisting Ant-file (since this is a project and hence an ant file delvirered by some third party). All the handling of the JAR-file must be performed from within the POM. I have partly solved it by including build plugins : plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-jar-plugin/artifactId configuration classesDirectory${basedir}/build/classes/classesDirectory /configuration /plugin /plugins /build Where I tell Maven where to look for the class-files for Maven to build the JAR. The class-files are a result of the Ant-script. It might happen that this is the preferred way of doing it, since I will end up with a Maven-generated JAR which better matches the Maven2 repo concept (since the JAR generated from Maven contains both pom.properties and the pom.xml, which the Ant generated JAR file does not.)... Any thoughts on this ? Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Javadoc for dependent libraries in Netbeans...
Hi again, I got the ant-script running from the POM now, partly. When I get to the javac-task in my build.xml ant file, I get the following error: [INFO]Error executing ant tasks Embedded error: The following error occurred while executing this line: [INFO]C:\Documents and Settings\asty\Skrivebord\CommonComponents\Jamod\build.xml:121: Unable to find a javac compiler; com.sun.tools.javac.Main is not on the classpath. Perhaps JAVA_HOME does not point to the JDK In my POM I have the following: plugin groupIdorg.apache.maven.plugins/groupId artifactIdmaven-antrun-plugin/artifactId executions execution idcompile/id phasecompile/phase configuration tasks ant antfile=${basedir}/build.xml inheritAll=false inheritRefs=false target name=jar/ /ant /tasks /configuration goals goalrun/goal /goals /execution /executions dependencies dependency groupIdant/groupId artifactIdant-antlr/artifactId version1.6.5/version /dependency dependency groupIdantlr/groupId artifactIdantlrall/artifactId version2.7.4/version /dependency /dependencies /plugin I had to set inheritAll to false, otherwise the ant script didn't seem to be able to use the ant-defined properties (defined in the build.xml-file) Any ideas ? Regards Arne -Original Message- From: Arne Styve [mailto:[EMAIL PROTECTED] Sent: 18. april 2007 15:36 To: 'Maven Users List' Subject: RE: RE: Javadoc for dependent libraries in Netbeans... Hi Thorsten, By the way, do you know how to call an ANT-file from the POM ? I have a project with a build.xml ant file that I would like to keep but want to call from a POM. I've searched the net, but found only hints about executing ant-statements from within the pom, and not calling an ant file. I guess this is what you're looking for (see the second example): http://maven.apache.org/plugins/maven-antrun-plugin/classpaths.html HTH Thorsten Just what I was looking for :-) Thanks ! Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: RE: Javadoc for dependent libraries in Netbeans...
Hi I got the ant-script running from the POM now, partly. When I get to the javac-task in my build.xml ant file, I get the following error: [INFO]Error executing ant tasks Embedded error: The following error occurred while executing this line: [INFO]C:\Documents and Settings\asty\Skrivebord\CommonComponents\Jamod\build.xml:121: Unable to find a javac compiler; com.sun.tools.javac.Main is not on the classpath. Perhaps JAVA_HOME does not point to the JDK Perhaps you have to add another dependency for tools.jar to the plugin configuration...? That did the trick. Thank you very much ! Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Javadoc for dependent libraries in Netbeans...
Hi Milos, Thanks for your answer. It did help some, but it would be nice if you could give me an example. Say I have a library called jamod.jar v1.2. It is installed in our company maven2 repo as groupId=jamod, artifactId=jamod, Version=1.2 as type=jar. In the directorystructure of my local repository .m2, this will then appear as .m2\repository\jamod\jamod\1.2\jamod-1.2.jar What should the respective source and doc-files be called ? And should they be .JAR or .ZIP-files ? And for the javadoc jar/zip-file, should the index.html be on the root of the zipped file, or should there be a directory called api under which the index.html file should be (inside the zip/jar-file) ? As you might have understood by know, I am a bit new to Maven2, so please bear with me if my questions are a bit newbie. Kind regards Arne -Original Message- From: Milos Kleint [mailto:[EMAIL PROTECTED] Sent: 17. april 2007 16:07 To: Maven Users List Subject: Re: Javadoc for dependent libraries in Netbeans... hello, download javadocsources checks the remote repos for artifacts with -source or -javadoc classifiers and downloads them. The IDE then designates them as containing source/javadoc and they are sued for hyperlinking the sources or for code completion. However unfortunatelly most artifacts in the central repo don't have javadoc or sources on display. I'm not sure about the 2.3 version of mevenide (that one works with 5.5 and later builds) but the 3.0.2 version (that works only with the 6.0 M8+ netbeans builds) has also actions install local sources and install local javadoc that takes a local zip of sources/javadoc and puts them in the correct place in local repo for you. Does it help? or is the problem somewhere else? Regards Milos On 4/17/07, Styve Arne [EMAIL PROTECTED] wrote: Hi, I'm using the mevenide plugin to Netbeans from codehause. This works fine in most cases. However, when having added a dependency (by right-clicking on the Dependencies node of the project tree (in Projects view)), I can then right-click on the JAR I've included and get a menue saying Download Javadoc Source. But this has never worked. I've tried placing both sourcefiles (as JAR or ZIP) and API-doc in my local repository, but it still dont want to be integrated with Netbeans. I was hoping that the Download Javadoc and Source would enable the direct access to the API doc of the included JAR from within the editor. Am I wrong ? If not, how do I set up the repository (locally, and our company repo), and how do I write my POM to get this working ? Thanks! Arne Styve - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Javadoc for dependent libraries in Netbeans...
Thanks again Milos, I'll give it a try :-) By the way, do you know how to call an ANT-file from the POM ? I have a project with a build.xml ant file that I would like to keep but want to call from a POM. I've searched the net, but found only hints about executing ant-statements from within the pom, and not calling an ant file. Regards Arne -Original Message- From: Milos Kleint [mailto:[EMAIL PROTECTED] Sent: 18. april 2007 11:36 To: Maven Users List; [EMAIL PROTECTED] Subject: Re: Javadoc for dependent libraries in Netbeans... On 4/18/07, Arne Styve [EMAIL PROTECTED] wrote: Hi Milos, Thanks for your answer. It did help some, but it would be nice if you could give me an example. Say I have a library called jamod.jar v1.2. It is installed in our company maven2 repo as groupId=jamod, artifactId=jamod, Version=1.2 as type=jar. In the directorystructure of my local repository .m2, this will then appear as .m2\repository\jamod\jamod\1.2\jamod-1.2.jar the sources jar/zip (as jar is technically a zip) will be placed at .m2\repository\jamod\jamod\1.2\jamod-1.2-sources.jar and javadoc at .m2\repository\jamod\jamod\1.2\jamod-1.2-javadoc.jar What should the respective source and doc-files be called ? And should they be .JAR or .ZIP-files ? And for the javadoc jar/zip-file, should the index.html be on the root of the zipped file, or should there be a directory called api under which the index.html file should be (inside the zip/jar-file) ? the maven javadoc plugin creates one with api folder inside, the maven repo however has many that have the index.html right in the root. The netbeans integrationshould survive both options. Milos As you might have understood by know, I am a bit new to Maven2, so please bear with me if my questions are a bit newbie. Kind regards Arne -Original Message- From: Milos Kleint [mailto:[EMAIL PROTECTED] Sent: 17. april 2007 16:07 To: Maven Users List Subject: Re: Javadoc for dependent libraries in Netbeans... hello, download javadocsources checks the remote repos for artifacts with -source or -javadoc classifiers and downloads them. The IDE then designates them as containing source/javadoc and they are sued for hyperlinking the sources or for code completion. However unfortunatelly most artifacts in the central repo don't have javadoc or sources on display. I'm not sure about the 2.3 version of mevenide (that one works with 5.5 and later builds) but the 3.0.2 version (that works only with the 6.0 M8+ netbeans builds) has also actions install local sources and M8+ install local javadoc that takes a local zip of sources/javadoc and puts them in the correct place in local repo for you. Does it help? or is the problem somewhere else? Regards Milos On 4/17/07, Styve Arne [EMAIL PROTECTED] wrote: Hi, I'm using the mevenide plugin to Netbeans from codehause. This works fine in most cases. However, when having added a dependency (by right-clicking on the Dependencies node of the project tree (in Projects view)), I can then right-click on the JAR I've included and get a menue saying Download Javadoc Source. But this has never worked. I've tried placing both sourcefiles (as JAR or ZIP) and API-doc in my local repository, but it still dont want to be integrated with Netbeans. I was hoping that the Download Javadoc and Source would enable the direct access to the API doc of the included JAR from within the editor. Am I wrong ? If not, how do I set up the repository (locally, and our company repo), and how do I write my POM to get this working ? Thanks! Arne Styve - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Javadoc for dependent libraries in Netbeans...
Hi again Milos, I tried your suggestion, created a JAR file of the Javadoc, and placed it in our company repo as jamod-1.2-javadoc.jar Then rightclicked the dependencynode in the Netbeans project, and selected Download javadoc and source. A small green indicator appeared next to the jar, indicating that the javadoc had been downloaded and set up. However, when i rightclick the jamod-node now, and select View Javadoc, IE opens up with the following URL: jar:file:/C:/Documents%20and%20Settings/asty/.m2/repository/jamod/jamod/1.2/ jamod-1.2-javadoc.jar!/apidocs/index.html With the message: This page cannot be shown. I don't get the javadoc integrated with the editor either. Notice that Netbeans seams to expect the javadoc to start at /apidocs/... Any ideas ? Regards Arne -Original Message- From: Milos Kleint [mailto:[EMAIL PROTECTED] Sent: 18. april 2007 11:36 To: Maven Users List; [EMAIL PROTECTED] Subject: Re: Javadoc for dependent libraries in Netbeans... On 4/18/07, Arne Styve [EMAIL PROTECTED] wrote: Hi Milos, Thanks for your answer. It did help some, but it would be nice if you could give me an example. Say I have a library called jamod.jar v1.2. It is installed in our company maven2 repo as groupId=jamod, artifactId=jamod, Version=1.2 as type=jar. In the directorystructure of my local repository .m2, this will then appear as .m2\repository\jamod\jamod\1.2\jamod-1.2.jar the sources jar/zip (as jar is technically a zip) will be placed at .m2\repository\jamod\jamod\1.2\jamod-1.2-sources.jar and javadoc at .m2\repository\jamod\jamod\1.2\jamod-1.2-javadoc.jar What should the respective source and doc-files be called ? And should they be .JAR or .ZIP-files ? And for the javadoc jar/zip-file, should the index.html be on the root of the zipped file, or should there be a directory called api under which the index.html file should be (inside the zip/jar-file) ? the maven javadoc plugin creates one with api folder inside, the maven repo however has many that have the index.html right in the root. The netbeans integrationshould survive both options. Milos As you might have understood by know, I am a bit new to Maven2, so please bear with me if my questions are a bit newbie. Kind regards Arne -Original Message- From: Milos Kleint [mailto:[EMAIL PROTECTED] Sent: 17. april 2007 16:07 To: Maven Users List Subject: Re: Javadoc for dependent libraries in Netbeans... hello, download javadocsources checks the remote repos for artifacts with -source or -javadoc classifiers and downloads them. The IDE then designates them as containing source/javadoc and they are sued for hyperlinking the sources or for code completion. However unfortunatelly most artifacts in the central repo don't have javadoc or sources on display. I'm not sure about the 2.3 version of mevenide (that one works with 5.5 and later builds) but the 3.0.2 version (that works only with the 6.0 M8+ netbeans builds) has also actions install local sources and M8+ install local javadoc that takes a local zip of sources/javadoc and puts them in the correct place in local repo for you. Does it help? or is the problem somewhere else? Regards Milos On 4/17/07, Styve Arne [EMAIL PROTECTED] wrote: Hi, I'm using the mevenide plugin to Netbeans from codehause. This works fine in most cases. However, when having added a dependency (by right-clicking on the Dependencies node of the project tree (in Projects view)), I can then right-click on the JAR I've included and get a menue saying Download Javadoc Source. But this has never worked. I've tried placing both sourcefiles (as JAR or ZIP) and API-doc in my local repository, but it still dont want to be integrated with Netbeans. I was hoping that the Download Javadoc and Source would enable the direct access to the API doc of the included JAR from within the editor. Am I wrong ? If not, how do I set up the repository (locally, and our company repo), and how do I write my POM to get this working ? Thanks! Arne Styve - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: RE: Javadoc for dependent libraries in Netbeans...
Hi Thorsten, By the way, do you know how to call an ANT-file from the POM ? I have a project with a build.xml ant file that I would like to keep but want to call from a POM. I've searched the net, but found only hints about executing ant-statements from within the pom, and not calling an ant file. I guess this is what you're looking for (see the second example): http://maven.apache.org/plugins/maven-antrun-plugin/classpaths.html HTH Thorsten Just what I was looking for :-) Thanks ! Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Javadoc for dependent libraries in Netbeans...
Hi again, works for me in the Netbeans 6.0 M8 build and the respective mevenide 3.0.2 version (from the Netbeans Development Update Center). It's possible that the 2.3 version that works with 5.5 has a bug in there, that I fixed in the source code. Both the View Javadoc popup action and the code completion's javadoc popup work for me. Milos Good news. The Javadoc works :-) It turned out that the Neatbeans required the javadoc JAR-file to have the index.html in a directory called apidocs to be recognized. No it's the sourcecode. I managed to create a JAR file called jamod-1.2-sources.jar, but again it looks like Netbeans expects a certain directory structure inside the JAR-file. Have tried Using the directory src as the root inside the JAR file, and I have tried without using a root. Do you know what it should be ? Thanks for helping me out with this. Regards Arne - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: Adding JARs and DLLs to a repository (RXTX)...
Hi Damien, Thanks for your answer. It works fine ! Arne -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Damien Lecan Sent: 12. april 2007 18:27 To: Maven Users List Subject: Re: Adding JARs and DLLs to a repository (RXTX)... Hello, Add your dll in repository without pom, as dll type Then, use maven-dependency-plugin to get and copy dll were you want. Exemple : plugin artifactId-maven-dependency-plugin/artifactId executions execution idcopy/id phaseprocess-resources/phase goals goalcopy/goal /goals configuration artifactItems artifactItem groupIdcompany/groupId artifactIdjni-portcomm-wince/artifactId version1.0/version typedll/type outputDirectory ${project.build.outputDirectory} /outputDirectory destFileNameJNI_PortComm.dll/destFileName /artifactItem artifactItem groupIdcompany/groupId artifactIdjni-portcommsimu-wince/artifactId version1.0/version typedll/type outputDirectory ${project.build.outputDirectory} /outputDirectory destFileNameJNI_PortCommSimu.dll/destFileName /artifactItem /artifactItems /configuration /execution /executions /plugin Damien 2007/4/12, Arne Styve [EMAIL PROTECTED]: Hi, I'm relativly new to maven2, but have set up a company repository to store 3rd party JARs not found (or that I haven't been able to find) in the central repository, as well as our own JAR-files that w use accross projects. This works fine for any 100% Pure Java JARs, but I have some problems figuring out how to store JARs that comes with a DLL or two, like the RxTx-library for serial communication (RS232). Anyone got any good suggestions on how to store both the JAR-file (rxtx-2.1.jar) and it's two DLLs (rxtxSerial.dll and rxtxParallell.dll) in a maven2 repository ? Also how do I get Maven to fetch the DLLs in addition to the JAR file from the repository ? And finally, when deploying the final application, how do I get the DLLs to end up in the correct place ? (Is it possible to pack the DLLs into my JAR file ? Any input would be of great help! Thanks! Regards Arne Styve - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Adding JARs and DLLs to a repository (RXTX)...
Hi, I'm relativly new to maven2, but have set up a company repository to store 3rd party JARs not found (or that I haven't been able to find) in the central repository, as well as our own JAR-files that w use accross projects. This works fine for any 100% Pure Java JARs, but I have some problems figuring out how to store JARs that comes with a DLL or two, like the RxTx-library for serial communication (RS232). Anyone got any good suggestions on how to store both the JAR-file (rxtx-2.1.jar) and it's two DLLs (rxtxSerial.dll and rxtxParallell.dll) in a maven2 repository ? Also how do I get Maven to fetch the DLLs in addition to the JAR file from the repository ? And finally, when deploying the final application, how do I get the DLLs to end up in the correct place ? (Is it possible to pack the DLLs into my JAR file ? Any input would be of great help! Thanks! Regards Arne Styve - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]