OpenPKG CVS Repository
http://cvs.openpkg.org/
____________________________________________________________________________
Server: cvs.openpkg.org Name: Torsten Homeyer
Root: /v/openpkg/cvs Email: [EMAIL PROTECTED]
Module: openpkg-src Date: 10-Feb-2006 19:29:39
Branch: HEAD Handle: 2006021018293800
Added files:
openpkg-src/lsof lsof.patch
Modified files:
openpkg-src/lsof lsof.spec
Log:
modifying package: lsof-4.76 20051010 -> 20060210
Summary:
Revision Changes Path
1.8 +76 -0 openpkg-src/lsof/lsof.patch
1.58 +3 -1 openpkg-src/lsof/lsof.spec
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: openpkg-src/lsof/lsof.patch
============================================================================
$ cvs diff -u -r0 -r1.8 lsof.patch
--- /dev/null 2006-02-10 19:29:29 +0100
+++ lsof.patch 2006-02-10 19:29:38 +0100
@@ -0,0 +1,76 @@
+Index: lsof_4.76_src/dialects/freebsd/dlsof.h
+--- lsof_4.76_src/dialects/freebsd/dlsof.h.orig 2005-08-08 21:49:26
+0200
++++ lsof_4.76_src/dialects/freebsd/dlsof.h 2006-02-10 19:24:29 +0100
+@@ -297,6 +297,10 @@
+ #define MALLOC_DECLARE(type) extern struct malloc_type type[1]
+ /* to pacify <sys/lockf.h> */
+ #define _KERNEL
++#if FREEBSDV>=6000
++#include <sys/sx.h>
++#include <fs/devfs/devfs_int.h>
++#endif /* FREEBSDV>=6000 */
+ #include <fs/devfs/devfs.h>
+ #undef _KERNEL
+ # endif /* FREEBSDV>=5000 */
+Index: lsof_4.76_src/dialects/freebsd/dmnt.c
+--- lsof_4.76_src/dialects/freebsd/dmnt.c.orig 2005-08-08 21:49:27
+0200
++++ lsof_4.76_src/dialects/freebsd/dmnt.c 2006-02-10 19:25:57 +0100
+@@ -78,8 +78,24 @@
+ struct stat sb;
+ static ss = 0;
+
+- if (ss)
+- return(c->si_inode ^ s);
++# if defined(HAS_SI_PRIV)
++/*
++ * If the cdev structure has a private sub-structure, read it.
++ */
++ struct cdev_priv sp;
++
++ if (!c->si_priv || kread((KA_T)c->si_priv, (char *)&sp, sizeof(sp)))
++ return(0);
++#endif /* defined(HAS_SI_PRIV) */
++
++ if (ss) {
++# if defined(HAS_SI_PRIV)
++ return(sp.cdp_inode ^ s);
++# else /* !defined(HAS_SI_PRIV) */
++ return(c->si_inode ^ s);
++#endif /* defined(HAS_SI_PRIV) */
++ }
++
+ /*
+ * Determine the random udev seed from stat(2) operations on "/" and
+ * its device.
+@@ -160,8 +176,14 @@
+ * If the device seed is known, return its application to the cdev
structure's
+ * inode.
+ */
+- if (ss)
+- return(c->si_inode ^ s);
++ if (ss) {
++# if defined(HAS_SI_PRIV)
++ return(sp.cdp_inode ^ s);
++# else /* !defined(HAS_SI_PRIV) */
++ return(c->si_inode ^ s);
++#endif /* defined(HAS_SI_PRIV) */
++ }
++
+ (void) fprintf(stderr, "%s: can't determine user device random
seed.\n", Pn);
+ Exit(1);
+ }
+Index: lsof_4.76_src/dialects/freebsd/machine.h
+--- lsof_4.76_src/dialects/freebsd/machine.h.orig 2005-08-29 12:21:48
+0200
++++ lsof_4.76_src/dialects/freebsd/machine.h 2006-02-10 19:24:29 +0100
+@@ -427,6 +427,11 @@
+ */
+
+ /* #define HASSECURITY 1 */
++#if FREEBSDV>=6000
++#define HASSECURITY 1
++#define HAS_SI_PRIV 1
++#endif /* FREEBSDV>=6000 */
++
+
+
+ /*
@@ .
patch -p0 <<'@@ .'
Index: openpkg-src/lsof/lsof.spec
============================================================================
$ cvs diff -u -r1.57 -r1.58 lsof.spec
--- openpkg-src/lsof/lsof.spec 1 Jan 2006 13:16:17 -0000 1.57
+++ openpkg-src/lsof/lsof.spec 10 Feb 2006 18:29:38 -0000 1.58
@@ -33,10 +33,11 @@
Group: Filesystem
License: BSD
Version: 4.76
-Release: 20051010
+Release: 20060210
# list of sources
Source0:
ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_%{version}.tar.gz
+Patch0: lsof.patch
# build information
Prefix: %{l_prefix}
@@ -60,6 +61,7 @@
%prep
%setup -q -n lsof_%{version}
%{l_tar} xf lsof_%{version}_src.tar
+ %patch -p0
%build
cd lsof_%{version}_src
@@ .
______________________________________________________________________
The OpenPKG Project www.openpkg.org
CVS Repository Commit List [email protected]