structure has no member named `kp_eproc'
Petr Janda
elekktretterr at exemail.com.au
Mon May 14 18:25:53 PDT 2007
Erik Wikström wrote:
On 2007-05-14 17:48, Petr Janda wrote:
Hi,
I'm trying to compile net-snmp from SVN applying the pkgsrc patches
and I can't seem to figure out why its failing on this error. What's
the meaning of this error and how to fix it?
So when you try to compile the code that assumes that the struct has a
member kp_eproc but in reality it does not you get that error message.
A question: If you applied patches from pkgsrc does that mean that the
program is in pkgsrc and in that case, why not use it?
Hi Erik,
This is the full message,
host/hr_swrun.c: In function `var_hrswrun':
host/hr_swrun.c:603: error: structure has no member named `kp_eproc'
host/hr_swrun.c:604: error: structure has no member named `kp_eproc'
host/hr_swrun.c:605: error: structure has no member named `kp_eproc'
host/hr_swrun.c:730: error: structure has no member named `kp_proc'
host/hr_swrun.c:928: error: structure has no member named `kp_proc'
host/hr_swrun.c:972: error: structure has no member named `kp_proc'
host/hr_swrun.c:1079: error: structure has no member named `kp_eproc'
host/hr_swrun.c:1080: error: structure has no member named `kp_eproc'
host/hr_swrun.c:1081: error: structure has no member named `kp_eproc'
host/hr_swrun.c:1171: error: structure has no member named `kp_eproc'
host/hr_swrun.c: In function `Init_HR_SWRun':
host/hr_swrun.c:1349: warning: unused variable `bytes'
host/hr_swrun.c: In function `Get_Next_HR_SWRun':
host/hr_swrun.c:1491: error: structure has no member named `kp_proc'
host/hr_swrun.c:1492: error: structure has no member named `kp_proc'
*** Error code 1
Stop in /root/net-snmp_svn/V5-4-patches/agent/mibgroup.
and this is the part of code from around line 1079:
#elif HAVE_KVM_GETPROCS
#if defined(NOT_DEFINED) && defined(freebsd5) && __FreeBSD_version
>= 500014
/* XXX: Accessing ki_paddr causes sig10 ...
long_return = proc_table[LowProcIndex].ki_paddr->p_uticks +
proc_table[LowProcIndex].ki_paddr->p_sticks +
proc_table[LowProcIndex].ki_paddr->p_iticks; */
long_return = 0;
#elif defined(freebsd5)
long_return = proc_table[LowProcIndex].ki_runtime / 100000;
#elif defined(dragonfly)
long_return = proc_table[LowProcIndex].kp_eproc.e_uticks +
proc_table[LowProcIndex].kp_eproc.e_sticks +
proc_table[LowProcIndex].kp_eproc.e_iticks;
#else
long_return = proc_table[LowProcIndex].kp_proc.p_uticks +
proc_table[LowProcIndex].kp_proc.p_sticks +
proc_table[LowProcIndex].kp_proc.p_iticks;
#endif
The reason I am doing this is because I am trying to get NET-SNMP
supported upstream (at the moment its broken in pkgsrc stable and current)
Thanks
Petr
More information about the Users
mailing list