Import lsof_4.91+dfsg-1.debian.tar.xz
authorAndres Salomon <dilinger@debian.org>
Sat, 12 Jan 2019 09:23:59 +0000 (09:23 +0000)
committerAndres Salomon <dilinger@debian.org>
Sat, 12 Jan 2019 09:23:59 +0000 (09:23 +0000)
[dgit import tarball lsof 4.91+dfsg-1 lsof_4.91+dfsg-1.debian.tar.xz]

22 files changed:
README.Debian [new file with mode: 0644]
README.Debian-source [new file with mode: 0644]
README.source [new file with mode: 0644]
changelog [new file with mode: 0644]
compat [new file with mode: 0644]
control [new file with mode: 0644]
copyright [new file with mode: 0644]
docs [new file with mode: 0644]
examples [new file with mode: 0644]
install [new file with mode: 0644]
manpages [new file with mode: 0644]
patches/examples [new file with mode: 0644]
patches/manpage [new file with mode: 0644]
patches/obsolete [new file with mode: 0644]
patches/preset-ccdate [new file with mode: 0644]
patches/series [new file with mode: 0644]
patches/tests [new file with mode: 0644]
repack.local [new file with mode: 0644]
repack.stub [new file with mode: 0644]
rules [new file with mode: 0755]
source/format [new file with mode: 0644]
watch [new file with mode: 0644]

diff --git a/README.Debian b/README.Debian
new file mode 100644 (file)
index 0000000..d59e7db
--- /dev/null
@@ -0,0 +1,11 @@
+lsof for DEBIAN
+----------------------
+
+This version of the debian package no longer supports 2.0.x kernels
+It now uses the /proc filesystem and should work on any kernel 2.2.x 
+or 2.4.x
+
+To use the example scripts from /usr/share/doc/lsof/examples, run
+perl <(zcat /usr/share/doc/lsof/examples/foo.perl.gz)
+
+Norbert Tretkowski <nobse@debian.org>  Mon, 15 May 2006 17:56:08 -0500
diff --git a/README.Debian-source b/README.Debian-source
new file mode 100644 (file)
index 0000000..d6f8e39
--- /dev/null
@@ -0,0 +1,26 @@
+lsof (4.77.dfsg.1-1) unstable; urgency=low
+
+  * Most problematic code was removed upstream, there are only two files
+    left which need to be removed:
+    + dialects/uw/uw7/sys/fs/namenode.h
+    + dialects/uw/uw7/sys/fs/fifonode.h
+
+ -- Norbert Tretkowski <nobse@debian.org>  Wed, 10 May 2006 10:28:03 -0500
+
+lsof (4.76.dfsg.1-1) unstable; urgency=low
+
+  * Because some files in the original tarball contained files with comments
+    like "THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE", it was necessary to
+       remove those files. This did not affect any of the Debian supported
+       platforms. These files have been removed:
+       + dialects/sun/include/sys/auxv.h
+       + dialects/uw/uw21/fs/proc/prdata.h
+       + dialects/uw/uw21/sys/fs/fifonode.h
+       + dialects/uw/uw21/sys/fs/namenode.h
+       + dialects/uw/uw7/sys/fs/namenode.h
+       + dialects/uw/uw7/sys/fs/fifonode.h
+       + dialects/ou/ou8/sys/fs/namenode.h
+       + dialects/ou/ou8/sys/fs/fifonode.h
+       + dialects/ou/ou8/sys/fs/memfs_mnode.h
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sun, 23 Apr 2006 21:58:35 +0200
diff --git a/README.source b/README.source
new file mode 100644 (file)
index 0000000..be2c5b4
--- /dev/null
@@ -0,0 +1,125 @@
+The Git Repository
+==================
+
+Git allows repositories to have a number of formats and a number of ways
+of working so there is a need to document the working practice.
+What follows is largely drawn from the Debian Perl Group's git guide:
+http://pkg-perl.alioth.debian.org/git.html .
+
+The repository can be browsed at:
+http://anonscm.debian.org/gitweb/?p=collab-maint/lsof.git;a=summary
+
+The latest version of this file can be found at:
+http://anonscm.debian.org/gitweb/?p=collab-maint/lsof.git;a=blob_plain;f=debian/README.source;hb=HEAD
+
+A key point is that using a repository like this means that there is no
+need for using mentors or any other upload site.  We just use the 
+repository to communicate.
+
+Layout
+------
+The repository has three branches: "master", "upstream" and "pristine-tar".
+You always work in "master" and the other branches are maintained behind the
+scenes by the various tools. The "upstream" branch represents the contents
+of the "orig" tarball - that is after the non-DFSG source has been removed.
+The "pristine-tar" branch contains housekeeping data in a binary format.
+
+So the "upstream" branch never contains the debian directory. Also at the point
+of writing the upstream branch contains unpatched files (e.g. scripts/00README),
+but the master branch contains patched files. However when we switch to the
+modern package layout, the Debian Perl Group practice would be for the master 
+branch to also contain unpatched files with the patches in quilt format in
+debian/patches. This practice works well with dpkg-buildpackage but not from
+what I have seen with git-buildpackage. So beware.
+
+Also note that there are two parallel series of tags: one for the upstream code and
+one for the package as a whole.
+
+Requirements
+------------
+First of all you need to register an alioth account:
+https://alioth.debian.org/account/register.php .
+
+Then you need to join the collab-maint:
+https://alioth.debian.org/projects/collaba-maint/
+
+To work on this package you need the following packages:
+    git-buildpackage
+    pristine-tar
+    pbuilder (or sbuild or cowbuilder)
+
+Initial checkout
+----------------
+This command creates an "lsof" directory with all the appropriate git trimmings:
+$ gbp-clone --all --pristine-tar ssh://git.debian.org/git/collab-maint/lsof.git
+
+Upgrading to a new upstream source
+----------------------------------
+I would like to be able to say that the first step is usually:
+$ git-import-orig --uscan --pristine-tar  # DO NOT DO THIS!
+
+However we are suffering under #635920. It may be that the latest release
+has no non-DFSG material in which case we can move in that direction.
+In the meantime the sequence seems to be:
+
+$ uscan --verbose 
+$ git fetch origin upstream:upstream pristine-tar:pristine-tar
+$ git-import-orig --pristine-tar ../lsof_X_orig.tar.gz
+
+Assuming that this is a clean upgrade requiring no other changes, you 
+do the following:
+
+$ dch -vX
+[ Make sure that the debian/changelog file is okay.]
+$ dch -r        # Updates the timestamp and sets the distribution to unstable
+$ debcommit -a -r # Checks in the code and takes the git commit messages from the changelog
+$ git push 
+$ git push --tag
+
+That is as much as you can do as a non-DD.
+
+Other changes
+-------------
+It is a good idea to use the "dch" command to change the changelog. It does
+the following (at least if done right which I am not actually 100% sure about. ;-( )
+- Sets the distribution to UNRELEASED showing that the package is not yet ready.
+With the -r option it sets it "unstable". This is about communicating the 
+status of the package in a clear way.
+- It updates the timestamp.
+- It handles the situation where two people are working on different aspects of the
+package.
+
+Having made a change and described it in the changelog you do
+$ debcommit -a
+This checks the code in taking the git comment from the changelog.
+
+To push the code upto the server do
+$ git push
+
+I like this flow of debian/changelog driving the git comments. It feels natural 
+to me. However others swear by the alternative git comments driving the changelog
+which feels unnatural to me - checkout the "git-dch" command.
+
+If you need to make a change but there can be no corresponding changelog
+entry, do:
+$ git commit -a
+
+Also sometimes you need to add files:
+$ git add [file]
+
+And to check on the status of your working area:
+$ git status
+
+On a separate but related issue, it clearly is good practice to try to
+maintain a 1-1 correspondence between changes and commits. It would
+make it easier to backport a specific fix. However this is an ideal
+and noone should ever make an issue of this.
+
+Finishing off a release
+-----------------------
+Again when a release is ready for review (and after you have run 
+all the lintian and pbuilder checks) you indicate its readiness with:
+$ dch -r
+$ debcommit -a -r
+$ git push
+$ git push --tag
diff --git a/changelog b/changelog
new file mode 100644 (file)
index 0000000..54c6b1c
--- /dev/null
+++ b/changelog
@@ -0,0 +1,410 @@
+lsof (4.91+dfsg-1) unstable; urgency=low
+
+  * New upstream release (closes: #911818).
+    - fixes build failures with newer glibc (closes: #916160).
+    - debian/repack.local: Adjust for 4.91.
+  * Ack NMU (closes: #798315).
+  * Take over maintenance with Norbert's permission. Thanks for your
+    work, Norbert! (closes: #917937).
+  * Fix synopsis to start with lowercase letter (closes: #803973).
+
+ -- Andres Salomon <dilinger@debian.org>  Sat, 12 Jan 2019 09:23:59 +0000
+
+lsof (4.89+dfsg-0.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  [ Nicholas Bamber ]
+  * Corrected copright stanza
+  * Added patch to modernize Perl usage
+  * Dropped Perl dependency to Suggests (Closes: #694351)
+
+  [ Laurent Bigonville ]
+  * New upstream release (Closes: #764417)
+    - Refresh debian/patches/manpage
+  * debian/control: Add libselinux1-dev to the build-dependencies for linux
+    architectures (Closes: #751967)
+  * debian/repack.local: Adjust the file to be able to import version 4.89
+  * debian/control: Bump Standards-Version to 3.9.6 (no further changes)
+  * debian/control: Update the VCS URL to please lintian
+  * debian/control: Remove Nicholas Bamber from the uploaders list (Closes:
+    #739359)
+  * debian/copyright: Use BSD-4-clause has short name instead of just BSD
+  * debian/rules: Fix cross-compilation, thanks to Colin Watson for the patch
+    (Closes: #694914)
+  * debian/patches/preset-ccdate, debian/rules: Prevent recording of details
+    of the build environment to ensure build reproducibility (Closes: #762433)
+  * debian/control: Remove Raoul Gunnar Borenius from the Uploaders list per
+    his request
+
+ -- Laurent Bigonville <bigon@debian.org>  Sun, 13 Sep 2015 23:40:56 +0200
+
+lsof (4.86+dfsg-1) unstable; urgency=low
+
+  [ Nicholas Bamber ]
+  * Imported into git.debian.org and documented procedures in README.source
+
+  [ Raoul Gunnar Borenius ]
+  * New upstream release (Closes: #596393) and (Closes: #520587)
+  * packaging is now done with plain debhelper.
+  * updated debian/control (added Uploaders:, include
+    upstream homepage, bumped standards version, etc.)
+  * changed debian/copyright to latest format
+  * added debian/patches/examples to correct path to perl interpreter 
+  * added debian/patches/manpage to add missing escape signs in
+    manpage 
+  * added watch file and uscan helper files (repack.stub, repack.local)
+    in preparation for downloading and dfsg-repackaging of the newest source. 
+
+  [ Nicholas Bamber ]
+  * New upstream release (4.86) and refreshed manpage patch
+  * Added additional mirrors to watch file
+  * Marked examples patch as not requiring forwarding
+  * Removed obsolete debian/control clauses
+  * Enabled all tests apart from the NFS based test
+  * Passed '-n freebsd' to ./Configure on freebsd builds (cf. #589103)
+  * Added main comment to debian/copyright explaining modifications
+    to upstream tarball and added missing copyright stanzas
+
+ -- Nicholas Bamber <nicholas@periapt.co.uk>  Wed, 25 Apr 2012 07:11:12 +0100
+
+lsof (4.81.dfsg.1-1.1) unstable; urgency=low
+
+  * Non-maintainer upload.
+  * changed path to perl interpreter in examples (Closes: #544533) 
+
+ -- Raoul Gunnar Borenius <borenius@dfn.de>  Sun, 26 Feb 2012 00:20:17 +0100
+
+lsof (4.81.dfsg.1-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Wed, 18 Feb 2009 13:38:26 +0100
+
+lsof (4.80.dfsg.1-1) experimental; urgency=low
+
+  * New upstream release.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Thu, 04 Sep 2008 17:35:52 +0200
+
+lsof (4.79~J-1) experimental; urgency=low
+
+  * New upstream prerelease with support for file offsets.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Thu, 04 Oct 2007 20:08:23 +0200
+
+lsof (4.78.dfsg.1-3) unstable; urgency=low
+
+  [ Justin Pryzby ]
+  * Fix FTBFS if built twice in a row. (closes: #424550)
+  * Fix dh_install in debian/rules to get proper permissions of the
+    lsof binary. (closes: #427683)
+  * Fix incorrect handling of nostrip build option. (closes: #437539)
+
+  [ Norbert Tretkowski ]
+  * Include upstream changelog. (closes: #377598)
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sat, 08 Sep 2007 19:00:47 +0200
+
+lsof (4.78.dfsg.1-2) unstable; urgency=low
+
+  * Finally set myself as maintainer.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Mon,  7 May 2007 20:04:41 +0200
+
+lsof (4.78.dfsg.1-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sat,  5 May 2007 18:37:18 +0200
+
+lsof (4.77.dfsg.1-3) unstable; urgency=low
+
+  * Readded scripts which got lost with the upload of 4.77.dfsg.1-1.
+  * Documented the usage of example scripts. (closes: #184491)
+
+ -- Norbert Tretkowski <nobse@debian.org>  Mon, 15 May 2006 18:08:45 -0500
+
+lsof (4.77.dfsg.1-2) unstable; urgency=low
+
+  * Removed lsof-2.2 dummy package. (closes: #302732, #367269)
+  * Updated standards-version to 3.7.2.0, no changes required.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sun, 14 May 2006 19:07:12 -0500
+
+lsof (4.77.dfsg.1-1) unstable; urgency=low
+
+  * Complete rewrite of build-sytem based on debhelper.
+  * New upstream release. (closes: #365095)
+    + No longer fails on mmaped files whose names contains spaces.
+      (closes: #323333)
+  * Documented the reason for repackaging the original upstream tarball.
+    (closes: #364348)
+
+ -- Norbert Tretkowski <nobse@debian.org>  Wed, 10 May 2006 10:29:48 -0500
+
+lsof (4.76.dfsg.1-1) unstable; urgency=low
+
+  * New upstream release.
+  * Updated standards-version to 3.6.2.0, no changes required.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Fri,  2 Sep 2005 09:09:16 +0200
+
+lsof (4.75.dfsg.1-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Wed,  8 Jun 2005 19:29:42 +0200
+
+lsof (4.74.dfsg.3-2) unstable; urgency=medium
+
+  * Removed conflicts from lsof-2.2 package.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Tue, 22 Mar 2005 13:09:25 +0100
+
+lsof (4.74.dfsg.3-1) unstable; urgency=high
+
+  * Removed line in package description about supported kernels.
+    (closes: #276117)
+  * Re-added support for non-Linux ports. (closes: #300171)
+
+ -- Norbert Tretkowski <nobse@debian.org>  Fri, 18 Mar 2005 10:13:25 +0100
+
+lsof (4.74.dfsg.2-1) unstable; urgency=high
+
+  * Removed all subdirectories from dialects/ except the Linux one, by
+    request of Vic Abell <abe@purdue.edu>, lsof upstream.
+  * Changed priority of lsof-2.2 package from standard to extra.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Thu, 17 Mar 2005 11:54:36 +0100
+
+lsof (4.74.dfsg.1-1) unstable; urgency=high
+
+  * Removed non-free "unpublished proprietary code" from source tarball,
+    thanks to Peter Rockai for reporting. (closes: #299063)
+
+ -- Norbert Tretkowski <nobse@debian.org>  Mon, 14 Mar 2005 22:15:36 +0100
+
+lsof (4.74-1) unstable; urgency=low
+
+  * New upstream release.
+  * Raised version of debhelper build-dependency.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sat, 05 Feb 2005 23:31:25 +0100
+
+lsof (4.73-1) unstable; urgency=low
+
+  * New upstream release.
+  * Added lsof-2.2 upgrade package. (closes: #108341)
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sat, 27 Nov 2004 21:56:33 +0100
+
+lsof (4.72-1) unstable; urgency=low
+
+  * New upstream release.
+  * Bumped up standards-version, no changes needed.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Mon, 02 Aug 2004 23:46:33 +0200
+
+lsof (4.71-1) unstable; urgency=low
+
+  * New upstream release.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sat, 03 Apr 2004 17:32:46 +0200
+
+lsof (4.70-1) unstable; urgency=medium
+
+  * New upstream release. (closes: #199017)
+  * Removed lsof-2.2 provides. (closes: #223908)
+  * New co-maintainer: Norbert Tretkowski <nobse@debian.org>.
+  * Added debian/watch file, thanks to Filippo Giunchedi.
+  * Bumped up standards-version, no changes needed.
+
+ -- Norbert Tretkowski <nobse@debian.org>  Sun, 22 Feb 2004 23:33:16 +0100
+
+lsof (4.64-1) unstable; urgency=low
+
+  * New upstream version (Closes: #152196)
+  * Fixed grammar in description (Closes: #145387)
+  * Moved to /usr/bin (with link to /usr/sbin) to 
+    conform with FSSTND and traceroute (Closes: #55587)
+
+ -- Jim Mintha <jmintha@debian.org>  Thu, 18 Jul 2002 01:28:50 +0200
+
+lsof (4.57-1) unstable; urgency=low
+
+  * New upstream version.
+
+ -- Jim Mintha <jmintha@debian.org>  Sun, 22 Jul 2001 03:21:07 +0200
+
+lsof (4.55-2) unstable; urgency=low
+
+  * Add Provides for lsof-2.2 (Closes: Bug#94922)
+
+ -- Jim Mintha <jmintha@debian.org>  Mon, 23 Apr 2001 01:45:03 +0200
+
+lsof (4.55-1) frozen unstable; urgency=low
+
+  * New upstream version (Closes: Bug#57203)
+  * Rename package back to just lsof (Closes: Bug#91231, Bug#87403)
+  * Fixes not showing flock type locks (Closes: Bug#67236)
+
+ -- Jim Mintha <jmintha@debian.org>  Thu, 12 Apr 2001 03:41:42 +0200
+
+lsof (4.48-1) frozen unstable; urgency=medium
+
+  * New upstream version
+  * compatible with linux 2.3.x kernels (#55242)
+  * -r doesn't hang anymore (#44573)
+  * /proc based lsof doesn't need setgid kmem
+  * fix grammer error in description (#56872)
+  
+ -- Jim Mintha <jmintha@debian.org>  Mon, 31 Jan 2000 00:43:03 +0100
+
+lsof (4.43-1) unstable; urgency=low
+
+  * New upstream version.
+  * Dynamically create the control file based on kernel version
+  * create a virtual package lsof that the different kernel version
+    will provide and conflict with.
+  * Support of 2.2 kernels (/proc based so don't need a verson for
+    each kernel
+  * This should build on glibc 2.1 systems (tested on SPARC)
+
+ -- Jim Mintha <jmintha@debian.org>  Sat, 15 May 1999 22:50:27 +0200
+
+lsof (4.37-4) stable; urgency=low
+
+  * Add control file to build for 2.0.36 kernel version
+
+ -- Jim Mintha <jmintha@debian.org>  Wed, 14 Apr 1999 01:04:09 +0200
+
+lsof (4.37-3) unstable stable frozen; urgency=high
+
+  * Patched to get rid of buffer overflow security problem (#33538)
+
+ -- Jim Mintha <jmintha@debian.org>  Thu, 18 Feb 1999 08:28:57 -0800
+
+lsof (4.37-2) unstable; urgency=low
+
+  * Binary wasn't being installed sgid kmem (#28548)
+  * .dsc file has lsof2.0.25 instead of lsof-2.0.35 (#28546)
+
+ -- Jim Mintha <jmintha@debian.org>  Mon, 26 Oct 1998 22:42:21 +0100
+
+lsof (4.37-1) unstable; urgency=low
+
+  * New upstream version.
+  * Change to use debhelper scripts
+  * Binary packages now contain kernel version number
+
+ -- Jim Mintha <jmintha@debian.org>  Wed, 14 Oct 1998 23:32:46 +0200
+
+lsof (4.28-2) frozen unstable; urgency=medium
+
+  * Change package name to include kernel version (#24327)
+  * Small patch to build with new glibc stuff.
+
+ -- Jim Mintha <jmintha@debian.org>  Thu, 16 Jul 1998 05:01:38 -0700
+
+lsof (4.28-1) unstable; urgency=low
+
+  * New upstream version.
+  * Fixed example scripts to call perl in the proper location
+
+ -- Jim Mintha <jmintha@debian.org>  Sun, 15 Mar 1998 04:42:33 -0800
+
+lsof (4.26-1) unstable; urgency=low
+
+  * New upstream version.
+  * Update docs to warn about kernel version dependencies (#17614)
+
+ -- Jim Mintha <jmintha@debian.org>  Mon, 23 Feb 1998 00:05:52 -0800
+
+lsof (4.25-1) unstable; urgency=low
+
+  * New upstream version.
+  * Patch to read /boot/System.map-`uname -r` now in upstream version.
+
+ -- Jim Mintha <jmintha@debian.org>  Thu, 12 Feb 1998 01:06:57 -0800
+
+lsof (4.23-1) unstable; urgency=low
+
+  * New upstream version.
+  * added patch by upstream maintainer to read /boot/System.map-`uname -r`
+    instead of /System.map. (#16972)
+
+ -- Jim Mintha <jmintha@debian.org>  Sun, 18 Jan 1998 18:21:14 -0800
+
+lsof (4.22-1) unstable; urgency=low
+
+  * New upstream version.
+  * build with newer version of deb-make (#15410)
+  * don't include automatically built files in the diff.
+  * New maintainer.
+
+ -- Jim Mintha <jmintha@debian.org>  Thu, 15 Jan 1998 04:20:43 -0800
+
+lsof (4.18-1) unstable; urgency=low
+
+  * New upstream version
+  * Rebuild with libc6 (#11715).
+  * Include scripts as examples.
+
+ -- Michael Meskes <meskes@debian.org>  Tue, 28 Oct 1997 12:11:06 +0100
+
+lsof (4.15-1) unstable; urgency=low
+
+  * New upstream version (#7551).
+  * Compiled with support for kernel 2.1.* (#8270).
+    this also fixes (#10160)
+  * New maintainer.
+
+ -- Michael Meskes <meskes@topsystem.de>  Fri, 29 Aug 1997 10:22:00 +0200
+
+lsof (3.65-5) frozen unstable; urgency=low
+
+  * added patch by Helmut Geyer <Helmut.Geyer@IWR.Uni-Heidelberg.De>
+    to read /boot/System.map-`uname -r` instead of /System.map.
+    This fixes bug#4888. 
+  * changed maintainer address to <dominik@debian.org>.
+
+ -- Dominik Kubla <dominik@debian.org>  Thu, 14 Nov 1996 16:08:30 +0100
+
+lsof (3.65-4) unstable; urgency=low
+
+  * manual pages are now installed in "gzip -9" format as per
+    "Debian Policy Manual", section 3.2.1
+
+  * copyright file is now installed in /usr/doc/lsof as per
+    "Debian Policy Manual", section 3.2.5
+
+  * changelog file is now installed in /usr/doc/lsof as per
+    "Debian Policy Manual", section 3.2.6
+
+  * package is now build with CFLAGS set to '-O2 -g -Wall' as per
+    "Debian Policy Manual", section 4.1
+
+ -- Dominik Kubla <dominik@debian.org>  Thu, 14 Nov 1996 16:08:30 +0100
+
+lsof (3.65-4) unstable; urgency=low
+
+  * manual pages are now installed in "gzip -9" format as per
+    "Debian Policy Manual", section 3.2.1
+
+  * copyright file is now installed in /usr/doc/lsof as per
+    "Debian Policy Manual", section 3.2.5
+
+  * changelog file is now installed in /usr/doc/lsof as per
+    "Debian Policy Manual", section 3.2.6
+
+  * package is now build with CFLAGS set to '-O2 -g -Wall' as per
+    "Debian Policy Manual", section 4.1
+
+ -- Dominik Kubla <Dominik.Kubla@Uni-Mainz.DE>  Sun, 29 Sep 1996 17:14:11 +0200
+
+lsof (3.65-3) unstable; urgency=low
+
+  * Converted to new packaing standards.
+
+ -- Dominik Kubla <Dominik.Kubla@Uni-Mainz.DE>  Fri, 20 Sep 1996 17:00:00 +0200
+
diff --git a/compat b/compat
new file mode 100644 (file)
index 0000000..45a4fb7
--- /dev/null
+++ b/compat
@@ -0,0 +1 @@
+8
diff --git a/control b/control
new file mode 100644 (file)
index 0000000..a50395a
--- /dev/null
+++ b/control
@@ -0,0 +1,19 @@
+Source: lsof
+Section: utils
+Priority: standard
+Maintainer: Andres Salomon <dilinger@debian.org>
+Build-Depends: debhelper (>= 8.0.0), libselinux1-dev [linux-any]
+Standards-Version: 3.9.6
+Homepage: http://people.freebsd.org/~abe/
+Vcs-Git: git://anonscm.debian.org/collab-maint/lsof.git
+Vcs-Browser: https://anonscm.debian.org/cgit/collab-maint/lsof.git
+
+Package: lsof
+Architecture: any
+Depends: ${shlibs:Depends}, ${misc:Depends}
+Suggests: perl
+Description: utility to list open files
+ Lsof is a Unix-specific diagnostic tool.  Its name stands
+ for LiSt Open Files, and it does just that.  It lists
+ information about any files that are open, by processes
+ currently running on the system.  
diff --git a/copyright b/copyright
new file mode 100644 (file)
index 0000000..384effe
--- /dev/null
+++ b/copyright
@@ -0,0 +1,219 @@
+Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
+Upstream-Name: lsof
+Upstream-Contact: https://lists.rcac.purdue.edu/listinfo/lsof-l
+Source: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/
+Comment: The following changes were made to the upstream tarball:
+ 1.) The directory dialects/uw was removed for being non-DFSG
+ and not needed in Debian.
+ 2.) The main source was a tarball within a tarball. Only the innermost
+ tarball has been retained.
+ 3.) The top-level directory has been stripped away as it embedded the
+ version number making packaging more difficult.
+
+Files: *
+Copyright: Purdue Research Foundation, West Lafayette, Indiana 47907 2002 - 2011
+License: Purdue
+
+Files: debian/*
+Copyright:
+ 1996, Dominik Kubla <dominik@debian.org>
+ 1997, Michael Meskes <meskes@debian.org>
+ 1998-2002, Jim Mintha <jmintha@debian.org>
+ 2004-2009, Norbert Tretkowski <nobse@debian.org>
+ 2012, Raoul Gunnar Borenius <borenius@dfn.de>
+ 2012, Nicholas Bamber <nicholas@periapt.co.uk>
+License: BSD-4-clause
+
+Files: dialects/freebsd/include/procfs/pfsnode.h
+Copyright: 1993, Paul Kranenburg
+License: BSD-4-clause
+
+Files: dialects/darwin/libproc/dstore.c dialects/darwin/libproc/ddev.c dialects/darwin/libproc/dsock.c dialects/darwin/libproc/dproc.c dialects/darwin/libproc/dproto.h dialects/darwin/libproc/dlsof.h dialects/darwin/libproc/dfile.c dialects/darwin/libproc/dmnt.c dialects/darwin/libproc/machine.h [portins thereof]
+Copyright: 2005-2007, Apple Computer, Inc.  All rights reserved.
+License: Purdue
+
+Files: dialects/du/ddev.c[portions] dialects/osr/include/sys/cdefs.h
+Copyright: 1983, 1993, The Regents of the University of California
+License: BSD-4-clause
+
+Files: dialects/osr/include/netdb.h
+Copyright: 1980, 1983, 1988, Regents of the University of California.
+License: BSD-4-clause
+
+Files: print.c[portions]
+Copyright: 1983, 1988, 1993, Regents of the University of California.
+License: BSD-4-clause
+
+Files: scripts/sort_res.perl5
+Copyright: 2004, 2005, Fabian Frederick <fabian.frederick@gmx.fr>
+License: GPL-2+
+
+Files: regex.h lib/regex.c [portions thereof]
+Copyright: 1985, 1989-2000, Free Software Foundation, Inc.
+License: LGPL-2+
+
+Files: lib/snpf.c
+Copyright:
+ 1998, Sendmail, Inc.  All rights reserved.
+ 1997, Eric P. Allman.  All rights reserved.
+ 1988, 1993, The Regents of the University of California.  All rights reserved.
+License: sendmail
+ SENDMAIL LICENSE
+ .
+ The following license terms and conditions apply, unless a different
+ license is obtained from Sendmail, Inc., 1401 Park Avenue, Emeryville, CA
+ 94608, or by electronic mail at license@sendmail.com.
+ .
+ License Terms:
+ .
+ Use, Modification and Redistribution (including distribution of any
+ modified or derived work) in source and binary forms is permitted only if
+ each of the following conditions is met:
+ .
+ 1. Redistributions qualify as "freeware" or "Open Source Software" under
+ one of the following terms:
+ .
+ (a) Redistributions are made at no charge beyond the reasonable cost of
+ materials and delivery.
+ .
+ (b) Redistributions are accompanied by a copy of the Source Code or by an
+ irrevocable offer to provide a copy of the Source Code for up to three
+ years at the cost of materials and delivery.  Such redistributions
+ must allow further use, modification, and redistribution of the Source
+ Code under substantially the same terms as this license.  For the
+ purposes of redistribution "Source Code" means the complete source
+ code of sendmail including all modifications.
+ .
+ Other forms of redistribution are allowed only under a separate royalty-
+ free agreement permitting such redistribution subject to standard
+ commercial terms and conditions.  A copy of such agreement may be
+ obtained from Sendmail, Inc. at the above address.
+ .
+ 2. Redistributions of source code must retain the copyright notices as they
+ appear in each source code file, these license terms, and the
+ disclaimer/limitation of liability set forth as paragraph 6 below.
+ .
+ 3. Redistributions in binary form must reproduce the Copyright Notice,
+ these license terms, and the disclaimer/limitation of liability set
+ forth as paragraph 6 below, in the documentation and/or other materials
+ provided with the distribution.  For the purposes of binary distribution
+ the "Copyright Notice" refers to the following language:
+ "Copyright (c) 1998 Sendmail, Inc.  All rights reserved."
+ .
+ 4. Neither the name of Sendmail, Inc. nor the University of California nor
+ the names of their contributors may be used to endorse or promote
+ products derived from this software without specific prior written
+ permission.  The name "sendmail" is a trademark of Sendmail, Inc.
+ .
+ 5. All redistributions must comply with the conditions imposed by the
+ University of California on certain embedded code, whose copyright
+ notice and conditions for redistribution are as follows:
+ .
+ (a) Copyright (c) 1988, 1993 The Regents of the University of
+ California.  All rights reserved.
+ .
+ (b) Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions
+ are met:
+ .
+ (i)   Redistributions of source code must retain the above copyright
+ notice, this list of conditions and the following disclaimer.
+ .
+ (ii)  Redistributions in binary form must reproduce the above
+ copyright notice, this list of conditions and the following
+ disclaimer in the documentation and/or other materials provided
+ with the distribution.
+ .
+ (iii) All advertising materials mentioning features or use of this
+ software must display the following acknowledgement:  "This
+ product includes software developed by the University of
+ California, Berkeley and its contributors."
+ .
+ (iv)  Neither the name of the University nor the names of its
+ contributors may be used to endorse or promote products derived
+ from this software without specific prior written permission.
+ .
+ 6. Disclaimer/Limitation of Liability: THIS SOFTWARE IS PROVIDED BY
+ SENDMAIL, INC. AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED
+ WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+ MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  IN
+ NO EVENT SHALL SENDMAIL, INC., THE REGENTS OF THE UNIVERSITY OF
+ CALIFORNIA OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
+ INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
+ USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
+ .
+ (Version 8.6, last updated 6/24/1998)
+
+License: BSD-4-clause
+ Redistribution and use in source and binary forms, with or without
+ modification, are permitted provided that the following conditions
+ are met:
+ 1. Redistributions of source code must retain the above copyright
+    notice, this list of conditions and the following disclaimer.
+ 2. Redistributions in binary form must reproduce the above copyright
+    notice, this list of conditions and the following disclaimer in the
+    documentation and/or other materials provided with the distribution.
+ 3. All advertising materials mentioning features or use of this software
+    must display the following acknowledgement:
+       This product includes software developed by the University of
+       California, Berkeley and its contributors.
+ 4. Neither the name of the University nor the names of its contributors
+    may be used to endorse or promote products derived from this software
+    without specific prior written permission.
+ .
+ THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
+ ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+ ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
+ OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
+ HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
+ LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
+ OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
+ SUCH DAMAGE.
+
+License: Purdue
+ This software is not subject to any license of the American
+ Telephone and Telegraph Company or the Regents of the
+ University of California.
+ .
+ Permission is granted to anyone to use this software for
+ any purpose on any computer system, and to alter it and
+ redistribute it freely, subject to the following
+ restrictions:
+ .
+ 1. Neither the authors nor Purdue University are responsible
+    for any consequences of the use of this software.
+ .
+ 2. The origin of this software must not be misrepresented,
+    either by explicit claim or by omission.  Credit to the
+    authors and Purdue University must appear in documentation
+    and sources.
+ .
+ 3. Altered versions must be plainly marked as such, and must
+    not be misrepresented as being the original software.
+ .
+ 4. This notice may not be removed or altered.
+
+License: LGPL-2+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU Library General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+ .
+ On Debian systems, the complete text of version 2 of the GNU Library General
+ Public License can be found in `/usr/share/common-licenses/LGPL-2'.
+
+License: GPL-2+
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 2, or (at your option)
+ any later version.
+ .
+ On Debian systems, the complete text of version 2 of the GNU General
+ Public License can be found in `/usr/share/common-licenses/GPL-2'.
diff --git a/docs b/docs
new file mode 100644 (file)
index 0000000..023e878
--- /dev/null
+++ b/docs
@@ -0,0 +1,3 @@
+00FAQ
+00LSOF-L
+00QUICKSTART
diff --git a/examples b/examples
new file mode 100644 (file)
index 0000000..826ac77
--- /dev/null
+++ b/examples
@@ -0,0 +1 @@
+scripts/*
diff --git a/install b/install
new file mode 100644 (file)
index 0000000..d747ca6
--- /dev/null
+++ b/install
@@ -0,0 +1 @@
+lsof usr/bin
diff --git a/manpages b/manpages
new file mode 100644 (file)
index 0000000..fd2dd4d
--- /dev/null
+++ b/manpages
@@ -0,0 +1 @@
+lsof.8
diff --git a/patches/examples b/patches/examples
new file mode 100644 (file)
index 0000000..8f110a3
--- /dev/null
@@ -0,0 +1,112 @@
+Description: set correct path to perl interpreter in examples
+ The supplied expample scipts assume that perl is installed
+ in /usr/local/bin which is not the case in Debian.
+ This patch changes the path to /usr/bin/perl in all supplied
+ example scripts and corrects a comment in scripts/identd.perl5.
+Author: Raoul Gunnar Borenius <borenius@dfn.de>
+Forwarded: not-needed
+Reviewed-by: Nicholas Bamber <nicholas@periapt.co.uk>
+Last-Update: 2012-04-17
+--- a/scripts/00README
++++ b/scripts/00README
+@@ -33,9 +33,9 @@
+       Path to:        Is:
+       =======         ==
+-      Perl 4          /usr/local/bin/perl4
++      Perl 4          /usr/bin/perl
+-      Perl 5          /usr/local/bin/perl
++      Perl 5          /usr/bin/perl
+ If your system doesn't support the command interpreter feature,
+ you'll have to supply the scripts to your Perl interpreter on its
+--- a/scripts/big_brother.perl5
++++ b/scripts/big_brother.perl5
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl -w
++#!/usr/bin/perl -w
+ #+##############################################################################
+ #                                                                              #
+ # File: big_brother.perl                                                       #
+--- a/scripts/count_pf.perl
++++ b/scripts/count_pf.perl
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ #
+ # count_pf.perl-- run lsof in repeat mode and count processes and
+ #               files
+--- a/scripts/count_pf.perl5
++++ b/scripts/count_pf.perl5
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ #
+ # count_pf.perl5 -- run lsof in repeat mode and count processes and
+ #                 files
+--- a/scripts/identd.perl5
++++ b/scripts/identd.perl5
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ ###################################################################
+ # identd.perl5 : An implementation of RFC 1413 Ident Server
+ #                using Vic Abell's lsof.
+@@ -11,7 +11,7 @@
+ # - Multiple instances of the server are not a performance penalty
+ #   since they shall use lsof's cacheing mechanism. (compare with
+ #   Peter Eriksson's pidentd)
+-# - assumes 'lsof' binary in /usr/local/sbin
++# - assumes 'lsof' binary in $PATH
+ # - Command line arguments :
+ #   -t TIMEOUT Number of seconds to wait for a query before aborting.
+ #              Default is 120.
+--- a/scripts/idrlogin.perl
++++ b/scripts/idrlogin.perl
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ #
+ # $Id: idrlogin.perl,v 1.5 2001/11/18 12:20:46 abe Exp $
+ #
+--- a/scripts/idrlogin.perl5
++++ b/scripts/idrlogin.perl5
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ #
+ # $Id: idrlogin.perl5,v 1.5 2001/11/18 12:20:46 abe Exp $
+ #
+--- a/scripts/list_NULf.perl5
++++ b/scripts/list_NULf.perl5
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ #
+ # $Id: list_NULf.perl5,v 1.5 2000/07/14 17:03:37 abe Exp $
+ #
+--- a/scripts/list_fields.perl
++++ b/scripts/list_fields.perl
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl4
++#!/usr/bin/perl
+ #
+ # $Id: list_fields.perl,v 1.5 2000/07/14 17:03:37 abe Exp $
+ #
+--- a/scripts/shared.perl5
++++ b/scripts/shared.perl5
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ #
+ # $Id: shared.perl5,v 1.4 2001/11/18 12:20:46 abe Exp $
+ #
+--- a/scripts/watch_a_file.perl
++++ b/scripts/watch_a_file.perl
+@@ -1,4 +1,4 @@
+-#!/usr/local/bin/perl
++#!/usr/bin/perl
+ #
+ # watch_a_file.perl -- use lsof -F output to watch a specific file
+ #                    (or file system)
diff --git a/patches/manpage b/patches/manpage
new file mode 100644 (file)
index 0000000..f15bbc7
--- /dev/null
@@ -0,0 +1,404 @@
+Description: fix manpage errors
+   a lot of minus sign occurences in the lsof man page are missing the
+   '\' escape sign and would therefore be interpreted as hyphens. This patch
+   adds the escape signs where appropriate.
+Author: Raoul Gunnar Borenius <borenius@dfn.de>
+Reviewed-by: Nicholas Bamber <nicholas@periapt.co.uk>
+Forwarded: no
+Last-Update: 2012-04-17
+Index: lsof_4.91_src/lsof.8
+===================================================================
+--- lsof_4.91_src.orig/lsof.8
++++ lsof_4.91_src/lsof.8
+@@ -12,7 +12,7 @@ lsof \- list open files
+ [
+ .B \-?abChlnNOPRtUvVX
+ ] [
+-.BI -A " A"
++.BI \-A " A"
+ ] [
+ .BI \-c " c"
+ ] [
+@@ -223,19 +223,19 @@ options, or it might represent the
+ field identifier character following the
+ .B \-F
+ option.
+-When ambiguity is possible, start a new option with a `-'
++When ambiguity is possible, start a new option with a `\-'
+ character \- e.g., ``\fB\-F \-n\fP''.
+ If the next option is a file name, follow the possibly ambiguous
+-option with ``--'' \- e.g., ``\fB\-F -- \fIname\fR''.
++option with ``\-\-'' \- e.g., ``\fB\-F \-\- \fIname\fR''.
+ .PP
+ Either the `+' or the `\-' prefix may be applied to a group of options.
+ Options that don't take on separate meanings for each
+ prefix \- e.g., \fB\-i\fP \- may be grouped under either prefix.
+-Thus, for example, ``+M -i'' may be stated as ``+Mi'' and the group
++Thus, for example, ``+M \-i'' may be stated as ``+Mi'' and the group
+ means the same as the separate options.
+ Be careful of prefix grouping when one or more options in the group
+ does take on separate meanings under different prefixes \-
+-e.g., \fB+|\-M\fP; ``-iM'' is not the same request as ``\-i +M''.
++e.g., \fB+|\-M\fP; ``\-iM'' is not the same request as ``\-i +M''.
+ When in doubt, use separate options with appropriate prefixes.
+ .TP \w'names'u+4
+ .B \-? \-h
+@@ -416,9 +416,9 @@ Mixed lists are not permitted.
+ .IP
+ A file descriptor number range may be in the set as long as
+ neither member is empty, both members are numbers, and the ending
+-member is larger than the starting one \- e.g., ``0-7'' or ``3-10''.
++member is larger than the starting one \- e.g., ``0\-7'' or ``3\-10''.
+ Ranges may be specified for exclusion if they have the `^' prefix \-
+-e.g., ``^0-7'' excludes all file descriptors 0 through 7.
++e.g., ``^0\-7'' excludes all file descriptors 0 through 7.
+ .IP
+ Multiple file descriptor numbers are joined in a single ORed set before
+ participating in AND option selection.
+@@ -485,7 +485,7 @@ See the
+ section and the sections that follow it for more information on this
+ option.
+ .IP
+-.B -D
++.B \-D
+ must be followed by a function letter; the function letter may optionally
+ be followed by a path name.
+ .I Lsof
+@@ -737,7 +737,7 @@ When
+ .B \-f
+ is specified by itself, all path name arguments will be taken to be
+ simple files.
+-Thus, for example, the ``\fB\-f\fP\ -- /'' arguments direct lsof to search
++Thus, for example, the ``\fB\-f\fP\ \-\- /'' arguments direct lsof to search
+ for open files with a `/' path name, not all open files in the `/'
+ (root) file system.
+ .IP
+@@ -747,15 +747,15 @@ and
+ .B \-f
+ are properly terminated and aren't followed by a character (e.g., of
+ the file or file system name) that might be taken as a parameter.
+-For example, use ``--'' after
++For example, use ``\-\-'' after
+ .B +f
+ and
+ .B \-f
+ as in these examples.
+ .IP
+ .nf
+-      $ lsof +f -- /file/system/name
+-      $ lsof -f -- /file/name
++      $ lsof +f \-\- /file/system/name
++      $ lsof \-f \-\- /file/name
+ .fi
+ .IP
+ The listing of information from kernel file structures, requested with the
+@@ -1015,7 +1015,7 @@ Here are some sample addresses:
+ .nf
+ .br
+-      -i6 \- IPv6 only
++      \-i6 \- IPv6 only
+ .br
+       TCP:25 \- TCP and port 25
+ .br
+@@ -1028,10 +1028,10 @@ Here are some sample addresses:
+ .br
+       TCP@lsof.itap:513 \- TCP, port 513 and host name lsof.itap
+ .br
+-      tcp@foo:1-10,smtp,99 \- TCP, ports 1 through 10,
++      tcp@foo:1\-10,smtp,99 \- TCP, ports 1 through 10,
+               service name \fIsmtp\fP, port 99, host name foo
+ .br
+-      tcp@bar:1-smtp \- TCP, ports 1 through \fIsmtp\fP, host bar
++      tcp@bar:1\-smtp \- TCP, ports 1 through \fIsmtp\fP, host bar
+ .br
+       :time \- either TCP, UDP or UDPLITE time service port
+ .fi
+@@ -1086,7 +1086,7 @@ inhibits the conversion of user ID numbe
+ It is also useful when login name lookup is working improperly or slowly.
+ .TP \w'names'u+4
+ .BI +|\-L " [l]"
+-enables (`+') or disables (`-') the listing of file link
++enables (`+') or disables (`\-') the listing of file link
+ counts, where they are available \- e.g., they aren't available
+ for sockets, or most FIFOs and pipes.
+ .IP
+@@ -1300,9 +1300,9 @@ Thus, for example, to direct
+ to display offset at all times with a decimal digit count of 10, use:
+ .IP
+ .nf
+-      -o -o 10
++      \-o \-o 10
+ or
+-      -oo10
++      \-oo10
+ .fi
+ .IP
+ The default number of digits allowed after ``0t'' is normally 8,
+@@ -1497,7 +1497,7 @@ Or, for example, to list network files w
+ Idle, use:
+ .IP
+ .nf
+-      \-iUDP -sUDP:Idle
++      \-iUDP \-sUDP:Idle
+ .fi
+ .IP
+ State names vary with UNIX dialects, so it's not possible to
+@@ -1604,7 +1604,7 @@ selection characters \- the displaying o
+ and it must be explicitly selected again in the characters following
+ .BR \-T .
+ (In effect, then, the default is equivalent to
+-.BR -Ts .)
++.BR \-Ts .)
+ For example, if queue lengths and state are desired, use
+ .BR \-Tqs .
+ .IP
+@@ -1715,14 +1715,14 @@ may not report that it failed to find a
+ option or compile\-time option prevents the listing of the open file
+ containing the located search item.
+ .IP
+-For example, ``lsof -V -iTCP@foobar -a -d 999'' may not report a
++For example, ``lsof \-V \-iTCP@foobar \-a \-d 999'' may not report a
+ failure to locate open files at ``TCP@foobar'' and may not list
+ any, if none have a file descriptor number of 999.
+ A similar situation arises when HASSECURITY and HASNOSOCKSECURITY are
+ defined at compile time and they prevent the listing of open files.
+ .TP \w'names'u+4
+ .B +|\-w
+-Enables (\fB+\fP) or disables (\fB-\fP) the suppression of warning messages.
++Enables (\fB+\fP) or disables (\fB\-\fP) the suppression of warning messages.
+ .IP
+ The
+ .I lsof
+@@ -1752,13 +1752,13 @@ links and|or file system mount points en
+ scanning the directory (\fB+d\fP) or directory tree (\fB+D\fP).
+ .IP
+ If
+-.B -x
++.B \-x
+ is specified by itself without a following parameter, cross\-over
+ processing of both symbolic links and file system mount points is
+ enabled.
+ Note that when
+ .B \-x
+-is specified without a parameter, the next argument must begin with '-'
++is specified without a parameter, the next argument must begin with '\-'
+ or '+'.
+ .IP
+ The optional 'f' parameter enables file system mount point cross\-over
+@@ -1948,7 +1948,7 @@ option and before the start of the file
+ These are path names of specific files to list.
+ Symbolic links are resolved before use.
+ The first name may be separated from the preceding options with
+-the ``--'' option.
++the ``\-\-'' option.
+ .IP
+ If a
+ .I name
+@@ -2390,10 +2390,10 @@ option.
+ SECURITY\-CONTEXT
+ is the SELinux security context.
+ This column must be selected with the
+-.B -Z
++.B \-Z
+ option.
+ Note that the
+-.B -Z
++.B \-Z
+ option is inhibited when SELinux is disabled in the running Linux
+ kernel.
+ .TP
+@@ -3008,7 +3008,7 @@ or the name of a character special or bl
+ .IP
+ or the local and remote Internet addresses of a network file;
+ the local host name or IP number is followed by a colon (':'), the
+-port, ``->'', and the two\-part remote address;
++port, ``\->'', and the two\-part remote address;
+ IP addresses may be reported as numbers or names, depending on the
+ .BR +|\-M ,
+ .BR \-n ,
+@@ -3041,13 +3041,13 @@ or the local and remote mount point name
+ .IP
+ or ``STR'', followed by the stream name;
+ .IP
+-or a stream character device name, followed by ``->'' and the stream name
+-or a list of stream module names, separated by ``->'';
++or a stream character device name, followed by ``\->'' and the stream name
++or a list of stream module names, separated by ``\->'';
+ .IP
+ or ``STR:'' followed by the SCO OpenServer stream device and module
+-names, separated by ``->'';
++names, separated by ``\->'';
+ .IP
+-or system directory name, `` -- '', and as many components of the path
++or system directory name, `` \-\- '', and as many components of the path
+ name as
+ .I lsof
+ can find in the kernel's name cache for selected dialects
+@@ -3055,7 +3055,7 @@ can find in the kernel's name cache for
+ .B "KERNEL NAME CACHE"
+ section for more information.);
+ .IP
+-or ``PIPE->'', followed by a Solaris kernel pipe destination address;
++or ``PIPE\->'', followed by a Solaris kernel pipe destination address;
+ .IP
+ or ``COMMON:'', followed by the vnode device information structure's
+ device name, for a Solaris common vnode;
+@@ -3096,7 +3096,7 @@ by the transmit and receive queue sizes,
+ .IP
+ or ``dgram'' or ``stream'' for the type UnixWare 7.1.1 and above in\-kernel
+ UNIX domain sockets, followed by a colon (':') and the local path name
+-when available, followed by ``->'' and the remote path name or kernel
++when available, followed by ``\->'' and the remote path name or kernel
+ socket address in hexadecimal when available;
+ .IP
+ or the association value, association index, endpoint value, local address,
+@@ -3110,9 +3110,9 @@ file to be attached to another with
+ .I lsof
+ will add ``(FA:<address1><direction><address2>)'' to the NAME column.
+ <address1> and <address2> are hexadecimal vnode addresses.
+-<direction> will be ``<-'' if <address2> has been fattach'ed to
++<direction> will be ``<\-'' if <address2> has been fattach'ed to
+ this vnode whose address is <address1>;
+-and ``->'' if <address1>, the vnode address of this vnode, has been
++and ``\->'' if <address1>, the vnode address of this vnode, has been
+ fattach'ed to <address2>.
+ <address1> may be omitted if it already appears in the DEVICE column.
+ .PP
+@@ -3593,7 +3593,7 @@ for file systems from its mount table, u
+ incantation to see if it reports any alternate device numbers:
+ .PP
+ .IP
+-lsof -b
++lsof \-b
+ .PP
+ Look for standard error file warning messages that
+ begin ``assuming "dev=xxxx" from ...''.
+@@ -3612,7 +3612,7 @@ reports the complete paths it finds in t
+ If
+ .I lsof
+ can't report all components in a path, it reports in the NAME column
+-the file system name, followed by a space, two `-' characters, another
++the file system name, followed by a space, two `\-' characters, another
+ space, and the name components it has located, separated by
+ the `/' character.
+ .PP
+@@ -4185,32 +4185,32 @@ lsof
+ .PP
+ To list all open Internet, x.25 (HP\-UX), and UNIX domain files, use:
+ .IP
+-lsof -i -U
++lsof \-i \-U
+ .PP
+ To list all open IPv4 network files in use by the process whose PID is
+ 1234, use:
+ .IP
+-lsof -i 4 -a -p 1234
++lsof \-i 4 \-a \-p 1234
+ .PP
+ Presuming the UNIX dialect supports IPv6, to list only open IPv6
+ network files, use:
+ .IP
+-lsof -i 6
++lsof \-i 6
+ .PP
+ To list all files using any protocol on ports 513, 514, or 515 of host
+ wonderland.cc.purdue.edu, use:
+ .IP
+-lsof -i @wonderland.cc.purdue.edu:513-515
++lsof \-i @wonderland.cc.purdue.edu:513\-515
+ .PP
+ To list all files using any protocol on any port of mace.cc.purdue.edu
+ (cc.purdue.edu is the default domain), use:
+ .IP
+-lsof -i @mace
++lsof \-i @mace
+ .PP
+ To list all open files for login name ``abe'', or user ID 1234, or
+ process 456, or process 123, or process 789, use:
+ .IP
+-lsof -p 456,123,789 -u 1234,abe
++lsof \-p 456,123,789 \-u 1234,abe
+ .PP
+ To list all open files on device /dev/hd4, use:
+ .IP
+@@ -4222,7 +4222,7 @@ lsof /u/abe/foo
+ .PP
+ To send a SIGHUP to the processes that have /u/abe/bar open, use:
+ .IP
+-kill -HUP `lsof -t /u/abe/bar`
++kill \-HUP `lsof \-t /u/abe/bar`
+ .PP
+ To find any open file, including an open UNIX domain socket file,
+ with the name
+@@ -4238,27 +4238,27 @@ the device number for
+ .IR /nfs/mount/point ,
+ use:
+ .IP
+-lsof -b /nfs/mount/point
++lsof \-b /nfs/mount/point
+ .PP
+ To do the preceding search with warning messages suppressed, use:
+ .IP
+-lsof -bw /nfs/mount/point
++lsof \-bw /nfs/mount/point
+ .PP
+ To ignore the device cache file, use:
+ .IP
+-lsof -Di
++lsof \-Di
+ .PP
+ To obtain PID and command name field output for each process, file
+ descriptor, file device number, and file inode number for each file
+ of each process, use:
+ .IP
+-lsof -FpcfDi
++lsof \-FpcfDi
+ .PP
+ To list the files at descriptors 1 and 3 of every process running the
+ .I lsof
+ command for login ID ``abe'' every 10 seconds, use:
+ .IP
+-lsof -c lsof -a -d 1 -d 3 -u abe -r10
++lsof \-c lsof \-a \-d 1 \-d 3 \-u abe \-r10
+ .PP
+ To list the current working directory of processes running a command that
+ is exactly four characters long and has an 'o' or 'O' in character three,
+@@ -4266,31 +4266,31 @@ use this regular expression form of the
+ .BI \-c " c"
+ option:
+ .IP
+-lsof -c /^..o.$/i -a -d cwd
++lsof \-c /^..o.$/i \-a \-d cwd
+ .PP
+ To find an IP version 4 socket file by its associated numeric dot\-form
+ address, use:
+ .IP
+-lsof -i@128.210.15.17
++lsof \-i@128.210.15.17
+ .PP
+ To find an IP version 6 socket file (when the UNIX dialect supports
+ IPv6) by its associated numeric colon\-form address, use:
+ .IP
+-lsof -i@[0:1:2:3:4:5:6:7]
++lsof \-i@[0:1:2:3:4:5:6:7]
+ .PP
+ To find an IP version 6 socket file (when the UNIX dialect supports
+ IPv6) by an associated numeric colon\-form address that has a run of
+ zeroes in it \- e.g., the loop\-back address \- use:
+ .IP
+-lsof -i@[::1]
++lsof \-i@[::1]
+ .PP
+ To obtain a repeat mode marker line that contains the current time, use:
+ .IP
+-lsof -rm====%T====
++lsof \-rm====%T====
+ .PP
+ To add spaces to the previous marker line, use:
+ .IP
+-lsof -r "m==== %T ===="
++lsof \-r "m==== %T ===="
+ .SH BUGS
+ Since
+ .I lsof
diff --git a/patches/obsolete b/patches/obsolete
new file mode 100644 (file)
index 0000000..9640c1c
--- /dev/null
@@ -0,0 +1,81 @@
+Author: Nicholas Bamber <nicholas@periapt.co.uk>
+Subject: trying to modernize Perl so that dependency can be dropped
+Forwarded: not-needed
+Last-Update: 2012-05-05
+--- a/scripts/identd.perl5
++++ b/scripts/identd.perl5
+@@ -18,13 +18,14 @@
+ #
+ # Kapil Chowksey <kchowksey@hss.hns.com>
+ ###################################################################
+-
++use strict;
+ use Socket;
+-require 'getopts.pl';
++use Getopt::Long;
+ # Set path to lsof.
+-if (($LSOF = &isexec("../lsof")) eq "") {     # Try .. first
++my $LSOF;
++if (($LSOF = &isexec("/usr/bin/lsof")) eq "") {       # Try .. first
+     if (($LSOF = &isexec("lsof")) eq "") {    # Then try . and $PATH
+       print "can't execute $LSOF\n"; exit 1
+     }
+@@ -34,18 +35,16 @@
+ close(STDERR);
+ open(STDERR, ">/dev/null");
+-$Timeout = "120";
++my $Timeout = "120";
+-&Getopts('t:');
+-if ($opt_t) {
+-    $Timeout = $opt_t;
+-}
++GetOptions('timeout=i'=>\$Timeout);
+-($port, $iaddr) = sockaddr_in(getpeername(STDIN));
+-$peer_addr = inet_ntoa($iaddr);
++my ($port, $iaddr) = sockaddr_in(getpeername(STDIN));
++my $peer_addr = inet_ntoa($iaddr);
++my $query;
+ # read ident-query from socket (STDIN) with a timeout.
+-$timeout = int($Timeout);
++my $timeout = int($Timeout);
+ eval {
+     local $SIG{ALRM} = sub { die "alarm\n" };
+     alarm $timeout;
+@@ -61,8 +60,8 @@
+ # remove all white-spaces from query
+ $query =~ s/\s//g;
+-$serv_port = "";
+-$cli_port = "";
++my $serv_port = "";
++my $cli_port = "";
+ ($serv_port,$cli_port) = split(/,/,$query);
+ if ($serv_port =~ /^[0-9]+$/) {
+@@ -87,8 +86,8 @@
+ open(LSOFP,"$LSOF -nPDi -T -FLn -iTCP@".$peer_addr.":".$cli_port."|");
+-$user = "UNKNOWN";
+-while ($a_line = <LSOFP>) {
++my $user = "UNKNOWN";
++while (my $a_line = <LSOFP>) {
+     # extract user name.
+     if ($a_line =~ /^L.*/) {
+         ($user) = ($a_line =~ /^L(.*)/);
+--- a/scripts/sort_res.perl5
++++ b/scripts/sort_res.perl5
+@@ -33,7 +33,6 @@
+ #     -removing unuseful line number arg.
+ #     -display global size
+-require 'getopts.pl';
+ my @args = @_;
+ # Set path to lsof.
diff --git a/patches/preset-ccdate b/patches/preset-ccdate
new file mode 100644 (file)
index 0000000..ca25bf8
--- /dev/null
@@ -0,0 +1,235 @@
+Description: Allow LSOF_CCDATE to be overriden by an environment variable
+ Capturing the current time as part of the build process does not make it
+ deterministic. By allowing the LSOF_CCDATE to be externally set, the current
+ time can be removed or preset.
+Author: Jérémy Bobbio <lunar@debian.org>
+Last-Update: 2014-09-22
+
+--- a/dialects/aix/Makefile
++++ b/dialects/aix/Makefile
+@@ -84,7 +84,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_CINFO      "${CINFO}"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+--- a/dialects/darwin/kmem/Makefile
++++ b/dialects/darwin/kmem/Makefile
+@@ -88,7 +88,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_CINFO      "${CINFO}"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+--- a/dialects/darwin/libproc/Makefile
++++ b/dialects/darwin/libproc/Makefile
+@@ -97,7 +97,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_CINFO      "${CINFO}"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+--- a/dialects/du/Makefile
++++ b/dialects/du/Makefile
+@@ -76,7 +76,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+         echo '#define LSOF_HOST       "'`uname -n`'"' >> version.h; \
+--- a/dialects/freebsd/Makefile
++++ b/dialects/freebsd/Makefile
+@@ -76,7 +76,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+         echo '#define LSOF_HOST       "'`uname -n`'"' >> version.h; \
+--- a/dialects/hpux/kmem/Makefile
++++ b/dialects/hpux/kmem/Makefile
+@@ -78,7 +78,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_CINFO      "${CINFO}"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+--- a/dialects/hpux/pstat/Makefile
++++ b/dialects/hpux/pstat/Makefile
+@@ -75,7 +75,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_CINFO      "${CINFO}"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+--- a/dialects/linux/Makefile
++++ b/dialects/linux/Makefile
+@@ -78,7 +78,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_CINFO      "${CINFO}"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+--- a/dialects/n+obsd/Makefile
++++ b/dialects/n+obsd/Makefile
+@@ -81,7 +81,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
+         echo '#define LSOF_HOST       "'`uname -n`'"' >> version.h; \
+--- a/dialects/n+os/Makefile
++++ b/dialects/n+os/Makefile
+@@ -87,7 +87,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_LDFLAGS    "${CFGL}"' >> version.h
+       @if [ "X${LSOF_LOGNAME}" = "X" ]; then \
+--- a/dialects/osr/Makefile
++++ b/dialects/osr/Makefile
+@@ -87,7 +87,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_LDFLAGS    "${CFGL}"' >> version.h
+       @if [ "X${LSOF_LOGNAME}" = "X" ]; then \
+--- a/dialects/sun/Makefile
++++ b/dialects/sun/Makefile
+@@ -75,7 +75,15 @@ version.h:  FRC
+       @echo '#define  LSOF_BLDCMT     "${LSOF_BLDCMT}"' > version.h;
+       @echo '#define  LSOF_CC         "${CC}"' >> version.h
+       @echo '#define  LSOF_CCV        "${CCV}"' >> version.h
+-      @echo '#define  LSOF_CCDATE     "'`date`'"' >> version.h
++      @if [ "X${LSOF_CCDATE}" = "X" ]; then \
++        echo '#define LSOF_CCDATE     "'`date`'"' >> version.h; \
++      else \
++        if [ "${LSOF_CCDATE}" = "none" ]; then \
++          echo '#define       LSOF_CCDATE     ""' >> version.h; \
++        else \
++          echo '#define       LSOF_CCDATE     "${LSOF_CCDATE}"' >> version.h; \
++        fi \
++      fi
+       @echo '#define  LSOF_CCFLAGS    "'`echo ${CFLAGS} | sed 's/\\\\(/\\(/g' | sed 's/\\\\)/\\)/g' | sed 's/"/\\\\"/g'`'"' >> version.h
+       @echo '#define  LSOF_CINFO      "${CINFO}"' >> version.h
+       @if [ "X${LSOF_HOST}" = "X" ]; then \
diff --git a/patches/series b/patches/series
new file mode 100644 (file)
index 0000000..e90bc29
--- /dev/null
@@ -0,0 +1,5 @@
+manpage
+examples
+tests
+obsolete
+preset-ccdate
diff --git a/patches/tests b/patches/tests
new file mode 100644 (file)
index 0000000..33ea165
--- /dev/null
@@ -0,0 +1,61 @@
+Author: Nicholas Bamber <nicholas@periapt.co.uk>
+Subject: test integration
+ We always want to run the tests even if our platform is not 
+ in the database of validated platforms. And the NFS based
+ test has no chance of success in a bare Debian machine.
+Forwarded: not-needed
+Last-Update: 2012-04-18
+--- a/tests/Makefile
++++ b/tests/Makefile
+@@ -10,7 +10,7 @@
+ HDR=  LsofTest.h
+-CKTSTDB= CkTestDB
++CKTSTDB= true
+ CONFCFL= ./config.cflags
+ CONFIG=       ./config.cc ${CONFCFL} ./config.xobj
+ LTOBJ=        LTlib.o
+@@ -19,13 +19,14 @@
+ BASTST=       LTbasic
+ STDTST=       LTnlink LTsock LTszoff LTunix
+-OPTTST=       LTbigf LTdnlc LTlock LTnfs 
++OPTTST=       LTbigf LTdnlc LTlock
+-all:  ${CKTSTDB} ${BASTST} ${STDTST} FRC
+-      @./${CKTSTDB}; xv=$$?; \
++all:  ${BASTST} ${STDTST} FRC
++      @${CKTSTDB}; xv=$$?; \
+       if [ $$xv -ne 0 ]; then \
+         exit 1 ;\
+       fi
++      @pwd
+       @rm -f config.LT*
+       -@err=0; \
+       echo ""; \
+@@ -59,8 +60,8 @@
+ auto: ckDB silent FRC
+-ckDB: ${CKTSTDB} FRC
+-      @echo "" | ./${CKTSTDB}; xv=$$?; \
++ckDB: FRC
++      @echo "" | ${CKTSTDB}; xv=$$?; \
+       if [ $$xv -ne 0 ]; then \
+         exit 1 ;\
+       fi
+@@ -110,7 +111,7 @@
+       `cat config.cc` ${CFLAGS} `cat config.cflags` LTunix.c \
+       ${LIBOBJ} `cat config.xobj` -o LTunix `cat config.ldflags`
+-opt:  ${CKTSTDB} ${OPTTST} FRC
++opt:  ${OPTTST} FRC
+       @rm -f config.LT*
+       -@err=0; \
+       echo ""; \
+@@ -157,3 +158,4 @@
+ std: all
+ test: all
++
diff --git a/repack.local b/repack.local
new file mode 100644 (file)
index 0000000..3ac3d30
--- /dev/null
@@ -0,0 +1,52 @@
+# needs to be incremented if we make changes in the source
+SUFFIX="+dfsg"
+# unpack the tar in the tar
+tar -xf lsof_4.91_src.tar
+rm lsof_4.91_src.tar
+rm lsof_4.91_src.tar.sig
+rm 00.README.FIRST_4.91
+rm README.lsof_4.91
+rm RELEASE.SUMMARY_4.91
+# remove unneeded files with non-free licenses
+rm -r lsof_4.91_src/dialects/uw
+# move files in lsof_4.91_src/ up to current dir so that
+# we do not need to state the version in debian/rules
+mv lsof_4.91_src/00CREDITS .
+mv lsof_4.91_src/00DCACHE .
+mv lsof_4.91_src/00DIALECTS .
+mv lsof_4.91_src/00DIST .
+mv lsof_4.91_src/00FAQ .
+mv lsof_4.91_src/00LSOF-L .
+mv lsof_4.91_src/00MANIFEST .
+mv lsof_4.91_src/00PORTING .
+mv lsof_4.91_src/00QUICKSTART .
+mv lsof_4.91_src/00README .
+mv lsof_4.91_src/00.README.FIRST .
+mv lsof_4.91_src/00TEST .
+mv lsof_4.91_src/00XCONFIG .
+mv lsof_4.91_src/AFSConfig .
+mv lsof_4.91_src/arg.c .
+mv lsof_4.91_src/ChangeLog .
+mv lsof_4.91_src/Configure .
+mv lsof_4.91_src/Customize .
+mv lsof_4.91_src/dialects .
+mv lsof_4.91_src/Inventory .
+mv lsof_4.91_src/lib .
+mv lsof_4.91_src/lsof.8 .
+mv lsof_4.91_src/lsof_fields.h .
+mv lsof_4.91_src/lsof.h .
+mv lsof_4.91_src/lsof.man .
+mv lsof_4.91_src/main.c .
+mv lsof_4.91_src/misc.c .
+mv lsof_4.91_src/node.c .
+mv lsof_4.91_src/print.c .
+mv lsof_4.91_src/proc.c .
+mv lsof_4.91_src/proto.h .
+mv lsof_4.91_src/regex.h .
+mv lsof_4.91_src/scripts .
+mv lsof_4.91_src/store.c .
+mv lsof_4.91_src/tests .
+mv lsof_4.91_src/usage.c .
+mv lsof_4.91_src/util.c .
+mv lsof_4.91_src/version .
+rmdir lsof_4.91_src
diff --git a/repack.stub b/repack.stub
new file mode 100644 (file)
index 0000000..76b65bd
--- /dev/null
@@ -0,0 +1,82 @@
+#!/bin/sh
+
+: <<=cut
+=pod
+
+=head1 NAME
+
+repack.stub - script to repack upstream tarballs from uscan
+
+=head1 INSTRUCTIONS
+
+put this in debian/repack.stub and add "debian sh debian/repack.stub" to
+the end of the line in debian/watch. you will also need to add a version
+mangle to debian/watch.
+
+then create a debian/repack.local. this is a shell script that is
+sourced under "set -e", so be careful to check returns codes.
+
+=head1 FUNCTIONS
+
+=over 4
+
+=item rm
+
+rm is replaced by a function that does some magic ("rm -rv" by default), but also changes MANIFEST if $MANIFEST is 1
+
+=item mv
+
+mv is replaced by a function that just does mv (by default), but also changes MANIFEST if $MANIFEST is 1
+
+=item requires_version
+
+requires_version is there for future usage for requiring certain versions of the script
+
+=back
+
+=head1 VARIABLES
+
+=over 4
+
+=item SUFFIX
+
+defaults to +dfsg
+
+what to append to the upstream version
+
+=item RM_OPTS
+
+defaults to -vrf
+
+options to pass to rm
+
+=item MANIFEST
+
+defaults to 0, set to 1 to turn on.
+
+this will manipulate MANIFEST files in CPAN tarballs.
+
+=item UP_BASE
+
+this is the directory where the upstream source is.
+
+=back
+
+=cut
+
+if [ -z "$REPACK_SH" ]; then
+    if [ -f ../../scripts/repack.sh ]; then
+        REPACK_SH=../../scripts/repack.sh
+    fi
+    if [ -z "$REPACK_SH" ] && which repack.sh > /dev/null; then
+        REPACK_SH=$(which repack.sh)
+    fi
+fi
+
+if [ ! -f "$REPACK_SH" ]; then
+    echo "Couldn't find a repack.sh. please put it in your PATH, put it at ../../scripts/repack.sh, or put it somewhere else and set the REPACK_SH variable"
+    echo "You can get it from http://anonscm.debian.org/gitweb/?p=pkg-perl/scripts.git;a=blob_plain;f=repack.sh;hb=HEAD"
+    exit 1
+fi
+
+exec "$REPACK_SH" "$@"
diff --git a/rules b/rules
new file mode 100755 (executable)
index 0000000..05288f5
--- /dev/null
+++ b/rules
@@ -0,0 +1,63 @@
+#!/usr/bin/make -f
+
+export DH_VERBOSE=1
+ifeq ($(shell uname -s),GNU/kFreeBSD)
+    PLATFORM:=freebsd
+else
+    PLATFORM:=linux
+endif
+
+# This has to be exported to make some magic below work.
+export DH_OPTIONS
+
+export DEB_BUILD_MAINT_OPTIONS=hardening=+all
+
+# this is used by ./Configure
+LSOF_CFGF := $(shell dpkg-buildflags --get CFLAGS) $(shell dpkg-buildflags --get CPPFLAGS)
+export LSOF_CFGF
+LSOF_CFGL := $(shell dpkg-buildflags --get LDFLAGS)
+export LSOF_CFGL
+# prevent recording of details of the build environment to ensure build
+# reproducibility
+LSOF_CCDATE := none
+LSOF_HOST := none
+LSOF_LOGNAME := none
+LSOF_SYSINFO := none
+LSOF_USER := none
+export LSOF_CCDATE LSOF_HOST LSOF_LOGNAME LSOF_SYSINFO LSOF_USER
+
+DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+ifneq ($(DEB_BUILD_GNU_TYPE),$(DEB_HOST_GNU_TYPE))
+    export LSOF_CC := $(DEB_HOST_GNU_TYPE)-gcc
+    export LSOF_CCV := $(shell $(LSOF_CC) -v 2>&1 | sed -n 's/.*version \(.*\)/\1/p')
+    export LINUX_CONF_CC := gcc
+    export LSOF_AR := $(DEB_HOST_GNU_TYPE)-ar cr
+    export LSOF_RANLIB := $(DEB_HOST_GNU_TYPE)-ranlib
+    # Autodetection will fail.
+    LSOF_CFGF += -DHAS_STRFTIME
+endif
+
+override_dh_auto_clean:
+       dh_auto_clean
+       rm -f dfile.c dlsof.h dmnt.c dnode.c dproc.c dproto.h dsock.c dstore.c machine.h Makefile
+       rm -f lib/Makefile
+       cd tests && make clean && cd -
+       rm -f tests/config.cc tests/config.cflags tests/config.ldflags tests/config.xobj
+
+override_dh_auto_configure:
+       ./Configure -n ${PLATFORM}
+
+override_dh_installchangelogs:
+       dh_installchangelogs 00DIST
+
+override_dh_auto_test:
+ifeq (,$(filter nocheck,$(DEB_BUILD_OPTIONS)))
+       cd tests && make test && make opt && cd -
+endif
+
+%:
+       dh $@
+
+get-orig-source:
+       uscan  --force-download --repack --verbose
diff --git a/source/format b/source/format
new file mode 100644 (file)
index 0000000..163aaf8
--- /dev/null
@@ -0,0 +1 @@
+3.0 (quilt)
diff --git a/watch b/watch
new file mode 100644 (file)
index 0000000..aaf0ab3
--- /dev/null
+++ b/watch
@@ -0,0 +1,11 @@
+version=3
+opts=dversionmangle=s/\+dfsg\d*$//,pasv \
+    ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_([\d.]+)\.tar\.gz \
+    debian sh debian/repack.stub
+opts=dversionmangle=s/\+dfsg\d*$//,pasv \
+    ftp://ftp.fu-berlin.de/pub/unix/tools/lsof/lsof_([\d.]+)\.tar\.gz \
+    debian sh debian/repack.stub
+opts=dversionmangle=s/\+dfsg\d*$//,pasv \
+    ftp://sunsite.ualberta.ca/pub/Mirror/lsof/lsof_([\d.]+)\.tar\.gz \
+    debian sh debian/repack.stub
+