Building RPMs from spec file

This forum is intended for the discussion of Nagios plugin development. Feature requests, patches, bug fixes, and all types of development-related discussions are welcome!

NOTE: The SourceForge.net nagiosplug-devel mailing list has been deprecated in favor of this forum in order to expedite support and provide additional features not available on the old mailing list.

Building RPMs from spec file

Postby danieljamesscott » Fri Jan 27, 2017 4:31 am

Hi,

I'm trying to build the RPMs using the included spec file. I receive the following error:

Code: Select all
RPM build errors:
  File not found: /var/lib/mysql/build/rpmbuild/BUILDROOT/nagios-plugins-2.1.4-1.x86_64/usr/lib/nagios/plugins/check_dhcp
  File not found: /var/lib/mysql/build/rpmbuild/BUILDROOT/nagios-plugins-2.1.4-1.x86_64/usr/lib/nagios/plugins/check_icmp
  File not found: /var/lib/mysql/build/rpmbuild/BUILDROOT/nagios-plugins-2.1.4-1.x86_64/usr/lib/nagios/plugins/check_ldaps


I've fixed the ldap issue by installing the openssl-devel package, although I'm not sure why it would be trying to install something which wasn't built.

I managed to fix the dhcp and icmp issue by adding 'install root' to the 'make' line 165:

Code: Select all
make AM_INSTALL_PROGRAM_FLAGS="" DESTDIR=${RPM_BUILD_ROOT} install install-root


Is this a suitable fix?
danieljamesscott
 
Posts: 8
Joined: Fri Jan 27, 2017 4:08 am

Re: Building RPMs from spec file

Postby tmcdonald » Fri Jan 27, 2017 11:12 am

That's a good question. This is getting a little more into the weeds of the build process than we typically see on the forums. If you have a GitHub account, a good place to ask/post would be our project page:

https://github.com/nagios-plugins/nagios-plugins

This will go right to our devs faster than through the forums.

Otherwise I can relay this to our dev team and see what they have to say.
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
tmcdonald
Support Lead / Operations Engineer
 
Posts: 8618
Joined: Mon Sep 23, 2013 8:40 am

Re: Building RPMs from spec file

Postby danieljamesscott » Mon Jan 30, 2017 4:47 pm

tmcdonald wrote:That's a good question. This is getting a little more into the weeds of the build process than we typically see on the forums. If you have a GitHub account, a good place to ask/post would be our project page:

https://github.com/nagios-plugins/nagios-plugins

This will go right to our devs faster than through the forums.

Otherwise I can relay this to our dev team and see what they have to say.


Thanks, but I tried there first... :)

https://github.com/nagios-plugins/nagio ... issues/229

I guess I could add what I've discovered to my issue report. I'll try that and see what happens.

Dan
danieljamesscott
 
Posts: 8
Joined: Fri Jan 27, 2017 4:08 am

Re: Building RPMs from spec file

Postby dwhitfield » Mon Jan 30, 2017 5:53 pm

danieljamesscott wrote:Is this a suitable fix?


Are you asking if this is something they will build in or something that will work for you?

I guess more to the point of the support forums: are you currently experiencing an issue? If not, github is probably the place. plugins 2.2.0 came out on January 19, so I suspect it won't be long before they swing around to the outstanding issues for 2.2.1.
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
dwhitfield
The Doctor
 
Posts: 3486
Joined: Wed Sep 21, 2016 10:29 am
Location: Nagios Enterprises, LLC

Re: Building RPMs from spec file

Postby danieljamesscott » Thu Feb 02, 2017 10:48 am

dwhitfield wrote:
Are you asking if this is something they will build in or something that will work for you?

I guess more to the point of the support forums: are you currently experiencing an issue? If not, github is probably the place. plugins 2.2.0 came out on January 19, so I suspect it won't be long before they swing around to the outstanding issues for 2.2.1.


More the latter - I guess I'm really asking if there is any reason that we couldn't add that change to the spec file going forward. So I'll focus my efforts on the github repo.

I see there are some other posts on here which are discussing RPM builds - I'll keep an eye on those too.

Thanks,

Dan
danieljamesscott
 
Posts: 8
Joined: Fri Jan 27, 2017 4:08 am

Re: Building RPMs from spec file

Postby dwhitfield » Thu Feb 02, 2017 11:08 am

What OS are you running? I know one of our devs is looking to become a CentOS maintainer but I don't have an ETA on that.

There's also repo.nagios.com. I'm not 100% sure what all is included, but it might be another source of information.

The maintenance branch on github hasn't had any changes since the 2.2.0 release, so I think we're just in wait-and-see mode right now. I know the devs are working hard on Core right now. I guess what I would say is that if you notice Core coming out and then in the next week you see no movement on plugins, update this thread and we'll see what's going on.
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
dwhitfield
The Doctor
 
Posts: 3486
Joined: Wed Sep 21, 2016 10:29 am
Location: Nagios Enterprises, LLC

Re: Building RPMs from spec file

Postby danieljamesscott » Thu Feb 02, 2017 11:27 am

Unfortunately, it's Amazon Linux, which is sort of CentOS 6 + extra bits and updates.

Thanks, I'll keep an eye out.
danieljamesscott
 
Posts: 8
Joined: Fri Jan 27, 2017 4:08 am

Re: Building RPMs from spec file

Postby dwhitfield » Thu Feb 02, 2017 11:31 am

The following are at http://repo.nagios.com/nagios/6/, but as you can see, they are built for XI, not core. I suspect your solution will be better suited than trying to modify what we have, but it's there for you to take a look for ideas.

Code: Select all
[ ]   nagiosxi-nagiosplugins-5-2.9.el6.i386.rpm   22-Jun-2016 14:45    3.0M   
[ ]   nagiosxi-nagiosplugins-5-2.9.el6.x86_64.rpm   22-Jun-2016 14:53    3.2M   
[ ]   nagiosxi-nagiosplugins-5-3.3.el6.i386.rpm   21-Nov-2016 15:37    3.0M   
[ ]   nagiosxi-nagiosplugins-5-3.3.el6.x86_64.rpm   10-Jan-2017 14:53    3.2M   
[ ]   nagiosxi-nagiosplugins-5-4.0.1.el6.i386.rpm   12-Jan-2017 17:45    3.0M   
[ ]   nagiosxi-nagiosplugins-5-4.0.1.el6.x86_64.rpm   12-Jan-2017 17:48    3.2M   
[ ]   nagiosxi-nagiosplugins-5-4.0.2.el6.i386.rpm   13-Jan-2017 12:00    3.0M   
[ ]   nagiosxi-nagiosplugins-5-4.0.2.el6.x86_64.rpm   13-Jan-2017 12:00    3.2M   
[ ]   nagiosxi-nagiosplugins-5-4.0.el6.i386.rpm   10-Jan-2017 16:27    1.4M   
[ ]   nagiosxi-nagiosplugins-5-4.0.el6.x86_64.rpm   10-Jan-2017 15:52    1.5M   
Be sure to check out our Knowledgebase for helpful articles and solutions!
User avatar
dwhitfield
The Doctor
 
Posts: 3486
Joined: Wed Sep 21, 2016 10:29 am
Location: Nagios Enterprises, LLC

Re: Building RPMs from spec file

Postby danieljamesscott » Thu Feb 02, 2017 11:34 am

Great, thanks for your help.
danieljamesscott
 
Posts: 8
Joined: Fri Jan 27, 2017 4:08 am

Re: Building RPMs from spec file

Postby rkennedy » Thu Feb 02, 2017 11:45 am

I'll leave this open should you have further questions!
rkennedy
 
Posts: 6562
Joined: Mon Oct 05, 2015 11:45 am

Next

Return to Nagios Plugin Development

Who is online

Users browsing this forum: Yahoo [Bot] and 3 guests