Hi,

I am trying to build ambari from code. I am able to successfully package
the application using mvn install. But to generate the RPM when I try to run

I am able to run man clean install for whole project.


When I run

mvn -B clean install package rpm:rpm -Drat.skip -DskipTests
–Dpython.ver="python >= 2.6" -Preplaceurl


I set ambari-version to 2.4.0.0-snapshot.

I get following  error: I thought it is coming because of fingbugs trying
to convert report from XML to HTML so I removed the XML-conversion plugin
from ambari-server pom.xml.  But I get same error as below except the first
line given by xml-maven-plugin. I verified rpm-build package is installed
on the machine.




Failed to execute goal org.codehaus.mojo:xml-maven-plugin:1.0:transform
(default) on project ambari-server: Failed to transform input file
/mnt/tmp/jenkins-continuous_approval-868/opensource/ambari/ambari-server/target/findbugs/findbugsXml.html:
The entity name must immediately follow the '&' in the entity reference. ->
[Help 1]


[ERROR] Failed to execute goal org.codehaus.mojo:rpm-maven-plugin:2.1.4:rpm
(default-cli) on project ambari-agent: RPM build execution returned: '1'
executing '/bin/sh -c cd
'/mnt/tmp/jenkins-continuous_approval-868/opensource/ambari/ambari-agent/target/rpm/ambari-agent/SPECS'
&& 'rpmbuild' '-bb' '--target' 'x86_64-redhat-linux' '--buildroot'
'/mnt/tmp/jenkins-continuous_approval-868/opensource/ambari/ambari-agent/target/rpm/ambari-agent/buildroot'
'--define' '_topdir
/mnt/tmp/jenkins-continuous_approval-868/opensource/ambari/ambari-agent/target/rpm/ambari-agent'
'--define' '_build_name_fmt
%%{ARCH}/%%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm' '--define'
'_builddir %{_topdir}/BUILD' '--define' '_rpmdir %{_topdir}/RPMS'
'--define' '_sourcedir %{_topdir}/SOURCES' '--define' '_specdir
%{_topdir}/SPECS' '--define' '_srcrpmdir %{_topdir}/SRPMS'
'ambari-agent.spec'' -> [Help 1]


[ERROR] Failed to execute goal
org.codehaus.mojo:rpm-maven-plugin:2.1-alpha-2:rpm (default-cli) on project
python-client: RPM build execution returned: '1' executing '/bin/sh -c

cd
/mnt/tmp/jenkins-continuous_approval-868/opensource/ambari/ambari-client/python-client/target/rpm/python-client/SPECS
&& rpmbuild -bb --buildroot /mnt/tmp/jenkins-continuous_a

pproval-868/opensource/ambari/ambari-client/python-client/target/rpm/python-client/buildroot
--define '_topdir
/mnt/tmp/jenkins-continuous_approval-868/opensource/ambari/ambari-c

lient/python-client/target/rpm/python-client' --target x86_64-redhat-linux
python-client.spec


*After commenting XML maven plugin, rpm build still fails : *


Failed to execute goal org.codehaus.mojo:rpm-maven-plugin:2.1.4:rpm
(default-cli) on project ambari-server: RPM build execution returned:
'1' executing '/bin/sh -c cd '/m

nt/tmp/jenkins-continuous_approval-868/opensource/ambari/ambari-server/target/rpm/ambari-server/SPECS'
&& 'rpmbuild' '-bb' '--target' 'x86_64-redhat-linux' '--buildroot'
'/mnt/tm

p/jenkins-continuous_approval-868/opensource/ambari/ambari-server/target/rpm/ambari-server/buildroot'
'--define' '_topdir
/mnt/tmp/jenkins-continuous_approval-868/opensource/amba

ri/ambari-server/target/rpm/ambari-server' '--define' '_build_name_fmt
%%{ARCH}/%%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm' '--define'
'_builddir %{_topdir}/BUILD' '--define'

'_rpmdir %{_topdir}/RPMS' '--define' '_sourcedir %{_topdir}/SOURCES'
'--define' '_specdir %{_topdir}/SPECS' '--define' '_srcrpmdir
%{_topdir}/SRPMS' 'ambari-server.spec'' -> [Hel

p 1]



Can anyone please help in building the rpm of ambari.


Thanks

Amey

Reply via email to