Re: Maven 2 and C/C++ Testing Framework

2009-03-04 Thread Rémy Sanlaville
Hi Dan,

The mentioned test phase is for java test.

True and it why i was surprise that native-maven-plugin is linked to it.


  Take a look at jade native
 maven plugin, it is an spin off of native plugin and  covers cppunit
 test

Thanks, I wasn't aware of this plugin. We will have a look.

I wonder also how to manage C interfaces (.h) with this plugin.
As I can see in configuration example (cf. [1] and [2]), we have to include
them in the source path:
   source
   directory${native.source.dir}/include/directory
   /source

I don't like it to much because we have to specify a path directory.
I rather prefer to use a dependency (it's really better if you have
different modules/projects).
Isn't it possible ?


Rémy

[1]
http://mojo.codehaus.org/maven-native/native-maven-plugin/examples/share-lib.html
[2]
http://www.jfrog.org/sites/jade-plugins/1.3/jade-plugin-parent/jade-build-plugin-parent/jade-native-plugin/examples/static-lib-ranlib.html


Re: Maven 2 and C/C++ Testing Framework

2009-03-04 Thread Dan Tran
having  .h files as dependencies is not possible as this moment. The
main problem here is how you would know which one is really include
files, user may want .c, .hpp as include file as well.
Also the pom will be polluted with lots of .h dep

One work around is to package .h files in a compressed form to be your
pom dependency file and use maven-dependency-plugin to unpack them
into a location under target directory, then reference the native
source path to pick them up.

-D

On Wed, Mar 4, 2009 at 12:41 AM, Rémy Sanlaville
remy.sanlavi...@gmail.com wrote:
 Hi Dan,

 The mentioned test phase is for java test.

 True and it why i was surprise that native-maven-plugin is linked to it.


  Take a look at jade native
 maven plugin, it is an spin off of native plugin and  covers cppunit
 test

 Thanks, I wasn't aware of this plugin. We will have a look.

 I wonder also how to manage C interfaces (.h) with this plugin.
 As I can see in configuration example (cf. [1] and [2]), we have to include
 them in the source path:
   source
       directory${native.source.dir}/include/directory
   /source

 I don't like it to much because we have to specify a path directory.
 I rather prefer to use a dependency (it's really better if you have
 different modules/projects).
 Isn't it possible ?


 Rémy

 [1]
 http://mojo.codehaus.org/maven-native/native-maven-plugin/examples/share-lib.html
 [2]
 http://www.jfrog.org/sites/jade-plugins/1.3/jade-plugin-parent/jade-build-plugin-parent/jade-native-plugin/examples/static-lib-ranlib.html


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org



Re: Maven 2 and C/C++ Testing Framework

2009-03-04 Thread Rémy Sanlaville
 having  .h files as dependencies is not possible as this moment. The
 main problem here is how you would know which one is really include
 files, user may want .c, .hpp as include file as well.
 Also the pom will be polluted with lots of .h dep


Isn't it possible to use dependencies directly in the plugin ?
For instance
build
  plugins
plugin
  groupIdorg.jfrog.jade.plugins/groupId
  artifactIdjade-native-plugin/artifactId
  extensionstrue/extensions
  configuration
...
  /configuration
  dependencies
dependency
  groupIdmy_groupid/groupId
  artifactIdmy_h_dep/artifactId
  versionmy_version/version
  type?/type
  scopecompile/scope
/dependency
  /dependencies
/plugin
  /plugins
/build



 One work around is to package .h files in a compressed form to be your
 pom dependency file and use maven-dependency-plugin to unpack them
 into a location under target directory, then reference the native
 source path to pick them up.


It's the workaround we thought to use.

Thanks,

Rémy


Re: Maven 2 and C/C++ Testing Framework

2009-03-03 Thread Dan Tran
The mentioned test phase is for java test.  Take a look at jade native
maven plugin, it is an spin off of native plugin and  covers cppunit
test

-D

On Tue, Mar 3, 2009 at 7:59 AM, Rémy Sanlaville
remy.sanlavi...@gmail.com wrote:
 Hi,

 I am looking for using C/C++ Testing Framework (like CppUnit, CxxTest or
 googletest) with maven 2.
 Does anybody already done it ?

 We are using native-maven-plugin for the compilation.
 But I am quite surprise that the native build lifecycle for this plugin
 consists of the following phases with corresponding goals (cf. [1]):
  test-compile    org.apache.maven.plugins:maven-compiler-plugin:testCompile
  test                org.apache.maven.plugins:maven-surefire-plugin:test

 I don't think that surefire support such of Testing Framework.
 It seems that we will have to bind :
   - an execution of the native-maven-plugin to the test-compile phase
   - an execution of the maven-antrun-plugin to the test phase

 Rémy

 [1] http://mojo.codehaus.org/maven-native/native-maven-plugin/lifecycle.html


-
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org