Subject: Re: lsof won't build
To: None <mason@primenet.com.au>
From: Steven M. Bellovin <smb@cs.columbia.edu>
List: current-users
Date: 11/06/2005 19:31:39
In message <slrndmt78l.lel.mason@g.primenet.com.au>, Geoff Wing writes:
>Steven M. Bellovin <smb@cs.columbia.edu> typed:
>: On an up-to-date -current system with up-to-date pkgsrc, I can't build 
>: lsof.  It complains:
>:
>: In file included from ../dlsof.h:73,
>:                  from ../lsof.h:190,
>:                  from dvch.c:43:
>: /usr/include/sys/buf.h:83:27: sys/workqueue.h: No such file or directory
>:
>: I suspect this is due to some changes in buf.h 1.83, but I'm less clear 
>: on what to do about it, given that this is a pkgsrc problem.
>
>The following will let it build.
>
>Regards,
>Geoff
>
>--- dlsof.h.org	2005-08-09 05:53:27.000000000 +1000
>+++ dlsof.h	2005-11-07 11:13:44.000000000 +1100
>@@ -70,7 +70,11 @@
> 	   || (defined(NETBSDV) && __NetBSD_Version__>=106060000) */
> 
> # if	defined(NETBSDV)
>+#undef _KERNEL
> #include <sys/buf.h>
>+#  if (__NetBSD_Version__>=106060000)
>+#define _KERNEL
>+#  endif
> # endif	/* defined(NETBSDV) */
> 
> # if	(defined(OPENBSDV) && OPENBSDV>=3030) \
>

Thanks; that did it.  Is someone going to commit that to pkgsrc?

		--Steven M. Bellovin, http://www.cs.columbia.edu/~smb