Win a copy of 97 Things Every Java Programmer Should Know this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Paul Clapham
  • Jeanne Boyarsky
  • Junilu Lacar
  • Henry Wong
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Frits Walraven
  • Tim Holloway
  • Carey Brown
Bartenders:
  • Piet Souris
  • salvin francis
  • fred rosenberger

Sonar - Native Plugin

 
Greenhorn
Posts: 17
Oracle Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have successfully integrate a Java Project with the Sonar Server and was able to view the dashboard.
Now I am trying to integrate C/C++ projects with Sonar.
I read from the net about "native plugin (nar plugin)" and we need to create a nar file
(hence i mentioned <packaging>nar</packaging> in my pom.xml)

But when I try to run 'mvn clean install', it shows BUILD FAILURE with the message
“ Cannot find life cycle mapping for packaging: 'nar'. “

It would be great help if somebody can throw some light into this issue.

Thanks in advance,
Suhas
 
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Maven uses the packaging type to determine how to go about building the artifact. The error means that Maven does not know how to build a "nar" artifact.

What plugin are you using to build the "nar" artifact? Did you remember to add the <extensions> argument to that plugin?

If this doesn't help, please post the pom.xml.
 
Suhas Saheer
Greenhorn
Posts: 17
Oracle Spring Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I used freehep nar plugin and later i tried with codehaus mojo nar plugin as well.
Both couldn't build.

I did use <extension>true</extension>

Please see below the pom.xml for the freehep plugin


 
Peter Johnson
author
Posts: 5856
7
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Wait a minute, the pom.xml you posted has this packaging type:



Are you sure your posted the correct pom.xml? I expect that your pom.xml would have had this instead:



Also, take the plugins out of the <pluginManagement> section. I think that section is only for submodules, and your pom.xml doesn't have any submodules nor is it configured as a parent POM.
 
Evildoers! Eat my justice! And this tiny ad's justice too!
Devious Experiments for a Truly Passive Greenhouse!
https://www.kickstarter.com/projects/paulwheaton/greenhouse-1
    Bookmark Topic Watch Topic
  • New Topic