Summary: | net-misc/iputils-20070202 does not build with sys-kernel/linux-headers-2.6.23 | ||
---|---|---|---|
Product: | Gentoo Linux | Reporter: | Markus Meier <maekke> |
Component: | Current packages | Assignee: | Gentoo's Team for Core System packages <base-system> |
Status: | RESOLVED FIXED | ||
Severity: | normal | CC: | didier.fabert, email, jdaluz, nick, romangarnett, ryan, yuya |
Priority: | High | ||
Version: | unspecified | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Package list: | Runtime testing required: | --- | |
Attachments: | Patch for removed OPEN_MAX constant in linux kernel |
Description
Markus Meier
![]() I believe this is caused by linux-headers-2.6.23 removing the OPEN_MAX definition from /usr/include/linux/limits.h. I found a random post on a random mailing list that suggested replacing the limits.h stuff with this: #include <unistd.h> #define OPEN_MAX (sysconf(_SC_OPEN_MAX)) I tried it on iputils (rdisc.c) and it seemed to fix the problem, however I'm not sure how it would act on earlier linux-headers revisions. ~ Nick one issue per bug it's better to simply rewrite code that relies on constants ... the POSIX standard explicitly allows omitting the OPEN_MAX define as a workaround, dropping in: #define OPEN_MAX (sysconf(_SC_OPEN_MAX)) should work fine when OPEN_MAX is used dynamically and not as an actual hard constant (like an array size) fixed in cvs Created attachment 133584 [details, diff] Patch for removed OPEN_MAX constant in linux kernel This is a better fix for the problem (taken from http://www.redhat.com/archives/fedora-extras-commits/2007-August/msg01642.html). *** Bug 196001 has been marked as a duplicate of this bug. *** *** Bug 196049 has been marked as a duplicate of this bug. *** |