I am going to package nagios-plugins-2.0.2 via rpmbuild tool, but failed, it always says:
cp: cannot stat `command.cfg': No such file or directory
error: Bad exit status from /var/tmp/rpm-tmp.tL1Y37 (%doc)
RPM build errors:
File not found: /root/rpmbuild/BUILDROOT/nagios-plugins-2.0.2-1.x86_64/etc/nagios/command.cfg
Bad exit status from /var/tmp/rpm-tmp.tL1Y37 (%doc)
command is: # rpmbuild -ta nagios-plugins-2.0.2.tar.gz
My host information : CentOS 6.4 x86_64 SMP
For more informations please look at the attachement.
Failed to package nagios-plugins-2.0.2 via rpmbuild tool
Failed to package nagios-plugins-2.0.2 via rpmbuild tool
- Attachments
-
- rpmbuild nagios-plugins-2.0.2.txt
- (156.97 KiB) Downloaded 513 times
-
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: Failed to package nagios-plugins-2.0.2 via rpmbuild tool
The quick answer is to:
** I should note that you might run into an issue with %doc on 188, if so simply remove command.cfg from that line also.
The long answer, is that this has been removed via gitignore, and is os and path dependent so the main maintainers (ubuntu and fedora) have their own versions of the command.cfg. Additionally, we need to rework the spec file a bit. This particular command.cfg is really only used for documentation and if nagios has not already installed a commands file.
Code: Select all
tar xzf nagios-plugins-2.0.2.tar.gz
vim nagios-plugins-2.0.2/nagios-plugins.spec
Remove line 186 that starts with %config
tar czf nagios-plugins-2.0.2.tar.gz nagios-plugins-2.0.2/
rpmbuild -ta nagios-plugins-2.0.2.tar.gz
The long answer, is that this has been removed via gitignore, and is os and path dependent so the main maintainers (ubuntu and fedora) have their own versions of the command.cfg. Additionally, we need to rework the spec file a bit. This particular command.cfg is really only used for documentation and if nagios has not already installed a commands file.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.