pkgsrc-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
pkg/37939: sysutils/lsof fails to build on current
>Number: 37939
>Category: pkg
>Synopsis: sysutils/lsof fails to build on current
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Fri Feb 01 17:00:00 +0000 2008
>Originator: Yakovetsky Vladimir
>Release: NetBSD 4.99.51
>Environment:
System: NetBSD lrou.x.ua 4.99.51 NetBSD 4.99.51 (lrou-1.880) #0: Tue Jan 29
17:27:05 EET 2008 Yakovetsky Vladimir
<yx%x.ua@localhost>@lrou.x.ua:/sys/arch/i386/compile/lrou i386
Architecture: i386
Machine: i386
>Description:
sysutils/lsof fails to build since
sys/arch/i386/include/cpufunc.h,v 1.39 2007/09/26
sys/sys/vnode.h,v 1.186 2008/01/24
sys/miscfs/specfs/specdev.h,v 1.34 2008/01/24
>How-To-Repeat:
% uname -srm
NetBSD 4.99.51 i386
% cd sysutils/lsof && make
(1)
cc -O2 -march=pentium4 -finline-functions -fomit-frame-pointer -ffast-math
-fstack-protector -Wstack-protector --param ssp-buffer-size=1
-DNETBSDV=4099000 -DHASGETBOOTFILE -DHASKVMGETPROC2 -DHASNFSPROTO -DHASIPv6
-DHASFDESCFS=1 -DHASFDLINK -DHASNULLFS -DHASPROCFS -DHASPROCFS_PFSROOT
-DHASBUFQ_H -DHAS9660FS=1 -DHASMSDOSFS=1 -DHASKERNFS -DHASKERNFS_KFS_KT
-DHASI_FFS1 -DHASEFFNLINK=i_ffs_effnlink -DHASEXT2FS -DHASI_E2FS_PTR -DHASLFS
-DHASPTYFS -DHASTMPFS -DHASNFSVATTRP -DHAS_ADVLOCK_ARGS -DHAS_LWP_H
-DHASCWDINFO -DHAS_SYS_PIPEH -DHASSTATVFS -DUVM
-I/usr/obj/sysutils/lsof/work/lsof_4.78/lsof_4.78_src/dialects/n+obsd/include
-DHAS_UVM_INCL -DLSOF_VSTR="4.99.51" -DLSOF_MORE_SECURE=0
-DLSOF_LESS_SECURE_SOCKETS=0 -D_FORTIFY_SOURCE=2 -c dvch.c
In file included from /usr/include/x86/lock.h:74,
from /usr/include/machine/lock.h:3,
from /usr/include/sys/lock.h:81,
from /usr/include/sys/mount.h:48,
from ../dlsof.h:98,
from ../lsof.h:191,
from dvch.c:43:
/usr/include/machine/cpufunc.h:3:25: error: x86/cpufunc.h: No such file or
directory
In file included from ../lsof.h:191,
from dvch.c:43:
../dlsof.h:288:1: warning: "P_PID" redefined
In file included from /usr/include/sys/lwp.h:47,
from ../dlsof.h:58,
from ../lsof.h:191,
from dvch.c:43:
/usr/include/sys/pset.h:42:1: warning: this is the location of the previous
definition
*** Error code 1
Stop.
workaround:
copy /sys/arch/x86/include/cpufunc.h to /usr/include/x86
or
re`make includes' in /sys/arch/x86/include with
--- sys/arch/x86/include/Makefile.orig
+++ sys/arch/x86/include/Makefile
@@ -5,13 +5,14 @@
INCS= aout_machdep.h \
bootinfo.h bus.h \
cacheinfo.h \
+ cpufunc.h \
cputypes.h \
cpuvar.h \
float.h \
ieee.h ieeefp.h \
intr.h intrdefs.h \
lock.h \
- math.h mutex.h mtrr.h \
+ math.h mtrr.h mutex.h \
pio.h \
pmap.h \
pmap_pv.h \
(2)
cc -O2 -march=pentium4 -finline-functions -fomit-frame-pointer -ffast-math
-fstack-protector -Wstack-protector --param ssp-buffer-size=1
-DNETBSDV=4099000 -DHASGETBOOTFILE -DHASKVMGETPROC2 -DHASNFSPROTO -DHASIPv6
-DHASFDESCFS=1 -DHASFDLINK -DHASNULLFS -DHASPROCFS -DHASPROCFS_PFSROOT
-DHASBUFQ_H -DHAS9660FS=1 -DHASMSDOSFS=1 -DHASKERNFS -DHASKERNFS_KFS_KT
-DHASI_FFS1 -DHASEFFNLINK=i_ffs_effnlink -DHASEXT2FS -DHASI_E2FS_PTR -DHASLFS
-DHASPTYFS -DHASTMPFS -DHASNFSVATTRP -DHAS_ADVLOCK_ARGS -DHAS_LWP_H
-DHASCWDINFO -DHAS_SYS_PIPEH -DHASSTATVFS -DUVM
-I/usr/obj/sysutils/lsof/work/lsof_4.78/lsof_4.78_src/dialects/n+obsd/include
-DHAS_UVM_INCL -DLSOF_VSTR=\"4.99.51\" -DLSOF_MORE_SECURE=0
-DLSOF_LESS_SECURE_SOCKETS=0 -D_FORTIFY_SOURCE=2 -c dnode.c
In file included from lsof.h:191,
from dnode.c:39:
dlsof.h:288:1: warning: "P_PID" redefined
In file included from /usr/include/sys/lwp.h:47,
from dlsof.h:58,
from lsof.h:191,
from dnode.c:39:
/usr/include/sys/pset.h:42:1: warning: this is the location of the previous
definition
dnode.c: In function 'process_node':
dnode.c:287: error: storage size of 'si' isn't known
dnode.c:828: error: 'union <anonymous>' has no member named 'vu_specinfo'
dnode.c:829: error: 'union <anonymous>' has no member named 'vu_specinfo'
*** Error code 1
Stop.
fix:
--- dialects/n+obsd/dnode.c~
+++ dialects/n+obsd/dnode.c
@@ -284,7 +284,11 @@
#if defined(HASPTYFS)
struct ptyfsnode pt;
+# if defined(NETBSDV) && __NetBSD_Version__ >= 499005000
+ struct specnode sn;
+# else
struct specinfo si;
+# endif
#endif /* defined(HASPTYFS) */
#if defined(HASNULLFS)
@@ -825,9 +829,15 @@
#if defined(HASPTYFS)
case PTYFSNODE:
+# if defined(NETBSDV) && __NetBSD_Version__ >= 499005000
+ if (v->v_un.vu_specnode
+ && !kread((KA_T)v->v_un.vu_specnode, (char *)&sn, sizeof(sn))) {
+ rdev = sn.sn_rdev;
+# else
if (v->v_un.vu_specinfo
&& !kread((KA_T)v->v_un.vu_specinfo, (char *)&si, sizeof(si))) {
rdev = si.si_rdev;
+# endif
rdevs = 1;
}
if (vfs) {
>Fix:
:r $LOCALPATCHES/sysutils/lsof/patch-ah
--- dialects/n+obsd/dnode.c~
+++ dialects/n+obsd/dnode.c
@@ -284,7 +284,11 @@
#if defined(HASPTYFS)
struct ptyfsnode pt;
+# if defined(NETBSDV) && __NetBSD_Version__ >= 499005000
+ struct specnode sn;
+# else
struct specinfo si;
+# endif
#endif /* defined(HASPTYFS) */
#if defined(HASNULLFS)
@@ -825,9 +829,15 @@
#if defined(HASPTYFS)
case PTYFSNODE:
+# if defined(NETBSDV) && __NetBSD_Version__ >= 499005000
+ if (v->v_un.vu_specnode
+ && !kread((KA_T)v->v_un.vu_specnode, (char *)&sn, sizeof(sn))) {
+ rdev = sn.sn_rdev;
+# else
if (v->v_un.vu_specinfo
&& !kread((KA_T)v->v_un.vu_specinfo, (char *)&si, sizeof(si))) {
rdev = si.si_rdev;
+# endif
rdevs = 1;
}
if (vfs) {
Home |
Main Index |
Thread Index |
Old Index