[SOLVED] apcupsd configure: error: gethostbyname_r is required
SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
apcupsd configure: error: gethostbyname_r is required
I've downloaded the apcupsd 3.14.13 tarfile. I've built and installed it on 3 of 4 Slackware computers, 3 of which are 14.1 and the 4th is 13.37.0. (the install is great, btw. It knows this is Slackware and creates a correct /etc/rc.d/rc.apcupsd! Not many packages care about Slackware anymore)
2 of the 14.1 systems are both 64bit and I thought were basically identical. I've kept them both up-to-date with slackpkg. One of these installed without problem. The other, at the ./configure step, give me:
configure: error: gethostbyname_r is required
I don't know how all the other hosts managed to get this function and the failed host did not, but can someone tell me how to get gethostbyname_r?
Possibly I can [re]install the package that is suppose to contain it?
Have a look in the config.log, as it will probably give you more info where it's trying to find that information. Looking at http://packages.slackware.com, it seems the ruby package contains the following files, which are the only matches to the filename gethostbyname, but it's possible that it is something declared in a file, and looking at the config.log could help find that file.
Well, I'm missing something. When I installed the glibc packages it installed several 4 packages and failed (MD5SUM) to install glibc-zoneinfo. Basically, all glibc's were missing. In comparing installed packages on the hosts that work with the one that does not, the working hosts have 1163 and 1177 packages installed, respectively. The 'bad' host has only 127 packages installed. Clearly, the bad host has "issues".
I'm going to try to clean up the installed packages, then re-try the apcupsd thing.
Meanwhile, how about some actual apcupsd advice ...
Since glorsplitz has "been using various versions of apcupsd for years", and you others likely also have experience, perhaps you can help me out while I work on the package problem. I have 2 hosts connected to the same UPS. Of course, I only want one to be the master. As I understand the configs, I can use netort for the slave to get "orders" from the master. Have you done this? Do you have example configs for master/slave for this arrangement? I'm kind of confused between the USPTYE, DEVICE net:ip, NETSERVER, NISP and NISPORT directives.
btw - never could get the builds to work on the one computer. I copies the scripts, executables, configs and man pages from the "good" computer and all seems to run well.
I don't have the experience to help you with your glibc issue, but couldn't you just installpkg the slackbuild on the computer that won't let it compile? It won't solve your compilation problem, but it will get the package installed for you.
Well, the slackbuild package I retrieved (linked by glorsplitz) did not have binaries. It fetched the source and tried to compile. It therefore failed. That's were I got the "libwrap missing" error.
Probably doesn't matter. I copied all binaries, configs, scripts and man pages from the "good" computer to corresponding locations on the "bad" computer, and it seems to run just fine.
The missing components is a bit of a puzzle, but I did hose up the slackpkg config when I initially installed version 14.1. I clobbered things, which I whined about in http://www.linuxquestions.org/questi...em-4175544846/. I thought I had recovered from that, but apparently not. I guess I'll just have to do a clean install one of these days.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.