Read kernel symbols from /dev/ksyms; this way lsof works with kernels with

any names, compressed or not.  Closes PR 2361
This commit is contained in:
pvalchev 2002-01-29 19:40:51 +00:00
parent 719b98ce8b
commit cd454f7e48
3 changed files with 28 additions and 2 deletions

View File

@ -1,10 +1,10 @@
# $OpenBSD: Makefile,v 1.38 2002/01/25 00:58:18 pvalchev Exp $
# $OpenBSD: Makefile,v 1.39 2002/01/29 19:40:51 pvalchev Exp $
COMMENT= "list information about open files"
VERSION= 4.61
DISTNAME= lsof_${VERSION}
PKGNAME= ${DISTNAME:S/_/-/}
PKGNAME= ${DISTNAME:S/_/-/}p1
CATEGORIES= sysutils
NEED_VERSION= 1.504
MASTER_SITES= ftp://vic.cc.purdue.edu/pub/tools/unix/lsof/ \

View File

@ -0,0 +1,12 @@
$OpenBSD: patch-Configure,v 1.6 2002/01/29 19:40:51 pvalchev Exp $
--- Configure.orig Tue Jan 29 12:14:08 2002
+++ Configure Tue Jan 29 12:14:59 2002
@@ -2301,7 +2301,7 @@ kernel generation process.
exit 1
;;
esac # }
- LSOF_CFGF="-DOPENBSDV=$LSOF_VERS -DN_UNIXV=/bsd"
+ LSOF_CFGF="-DOPENBSDV=$LSOF_VERS"
if test -r ${LSOF_INCLUDE}/nfs/nfsproto.h # {
then
LSOF_CFGF="$LSOF_CFGF -DHASNFSPROTO"

View File

@ -0,0 +1,14 @@
$OpenBSD: patch-dialects_n+obsd_dlsof_h,v 1.1 2002/01/29 19:40:51 pvalchev Exp $
--- dialects/n+obsd/dlsof.h.orig Mon Jan 14 08:55:48 2002
+++ dialects/n+obsd/dlsof.h Tue Jan 29 12:12:09 2002
@@ -262,9 +262,7 @@ typedef u_long KA_T;
#define MALLOC_P void
#define FREE_P MALLOC_P
#define MALLOC_S size_t
-#define N_UNIX_TMP(x) #x
-#define N_UNIX_STR(x) N_UNIX_TMP(x)
-#define N_UNIX N_UNIX_STR(N_UNIXV)
+#define N_UNIX "/dev/ksyms"
#define QSORT_P void
#define READLEN_T int
#define STRNCPY_L size_t