automatic version update by autodist [release 4.87-1mamba;Mon Jan 14 2013]

This commit is contained in:
Automatic Build System 2024-01-06 06:30:25 +01:00
parent 99551638a7
commit 3ca45e5fd6
3 changed files with 246 additions and 0 deletions

View File

@ -1,2 +1,7 @@
# lsof # lsof
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.
It can also list communications open by each process.

138
lsof-4.77-linux.patch Normal file
View File

@ -0,0 +1,138 @@
*** /tmp/T0k0aqHb Thu May 25 14:28:35 2006
--- dialects/linux/dproc.c Wed May 10 01:50:57 2006
***************
*** 233,242 ****
pn = 1;
ss = SB_ALL;
if (HasNFS) {
! if ((sv = statsafely(path, &sb))) {
! if (lnk)
! sv = statEx(pbuf, &sb, &ss);
! }
} else
sv = stat(path, &sb);
if (sv) {
--- 233,240 ----
pn = 1;
ss = SB_ALL;
if (HasNFS) {
! if ((sv = statsafely(path, &sb)))
! sv = statEx(pbuf, &sb, &ss);
} else
sv = stat(path, &sb);
if (sv) {
***************
*** 279,288 ****
if ((scko && !slash) || !scko) {
pn = 1;
if (HasNFS) {
! if ((sv = statsafely(path, &sb))) {
! if (lnk)
! sv = statEx(pbuf, &sb, &ss);
! }
} else
sv = stat(path, &sb);
if (sv) {
--- 277,284 ----
if ((scko && !slash) || !scko) {
pn = 1;
if (HasNFS) {
! if ((sv = statsafely(path, &sb)))
! sv = statEx(pbuf, &sb, &ss);
} else
sv = stat(path, &sb);
if (sv) {
***************
*** 329,339 ****
pn = 1;
if (HasNFS) {
if ((sv = statsafely(path, &sb))) {
! if (lnk) {
! sv = statEx(pbuf, &sb, &ss);
! if (!sv && (ss & SB_DEV) && (ss & SB_INO))
! txts = 1;
! }
}
} else
sv = stat(path, &sb);
--- 325,333 ----
pn = 1;
if (HasNFS) {
if ((sv = statsafely(path, &sb))) {
! sv = statEx(pbuf, &sb, &ss);
! if (!sv && (ss & SB_DEV) && (ss & SB_INO))
! txts = 1;
}
} else
sv = stat(path, &sb);
***************
*** 422,439 ****
pn = 1;
if (HasNFS) {
if (lstatsafely(path, &lsb)) {
! if (lnk)
! (void) statEx(pbuf, &lsb, &ls);
! else
! ls = 0;
enls = errno;
} else
ls = SB_ALL;
if (statsafely(path, &sb)) {
! if (lnk)
! (void) statEx(pbuf, &sb, &ss);
! else
! ss = SB_ALL;
enss = errno;
} else
ss = SB_ALL;
--- 416,427 ----
pn = 1;
if (HasNFS) {
if (lstatsafely(path, &lsb)) {
! (void) statEx(pbuf, &lsb, &ls);
enls = errno;
} else
ls = SB_ALL;
if (statsafely(path, &sb)) {
! (void) statEx(pbuf, &sb, &ss);
enss = errno;
} else
ss = SB_ALL;
***************
*** 664,679 ****
|| !ep || *ep)
continue;
/*
! * Assemble the inode number.
*/
if (!fp[5] || !*fp[5])
continue;
inode = (INODETYPE)atoi(fp[5]);
/*
* See if the device + inode pair match that of the executable.
* If they do, skip this map entry.
*/
- dev = (dev_t)makedev((int)maj, (int)min);
if (s && (ss & SB_DEV) && (ss & SB_INO)
&& (dev == s->st_dev) && (inode == (INODETYPE)s->st_ino))
continue;
--- 652,670 ----
|| !ep || *ep)
continue;
/*
! * Assemble the device and inode numbers. If they are both zero, skip
! * the entry.
*/
+ dev = (dev_t)makedev((int)maj, (int)min);
if (!fp[5] || !*fp[5])
continue;
inode = (INODETYPE)atoi(fp[5]);
+ if (!dev && !inode)
+ continue;
/*
* See if the device + inode pair match that of the executable.
* If they do, skip this map entry.
*/
if (s && (ss & SB_DEV) && (ss & SB_INO)
&& (dev == s->st_dev) && (inode == (INODETYPE)s->st_ino))
continue;

103
lsof.spec Normal file
View File

@ -0,0 +1,103 @@
Name: lsof
Version: 4.87
Release: 1mamba
Summary: Lists open files for running UNIX processes
Group: System/Tools
Vendor: openmamba
Distribution: openmamba
Packager: Aleph0 <aleph0@openmamba.org>
URL: http://people.freebsd.org/~abe/
Source: ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/lsof_%{version}.tar.bz2
#Patch from ftp://lsof.itap.purdue.edu/pub/tools/unix/lsof/patches/%{version}/linux.patch
Patch: %{name}-4.77-linux.patch
License: no OSI Approved
BuildRoot: %{_tmppath}/%{name}-%{version}-root
%description
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.
It can also list communications open by each process.
%prep
%setup -q -n %{name}_%{version}
tar -xf %{name}_%{version}_src.tar
cd %{name}_%{version}_src/dialects/linux
#% patch -p2
%build
cd %{name}_%{version}_src
chmod 644 dialects/linux/machine.h &&
echo "
#undef HASSECURITY
#undef HASNOSOCKSECURITY
#define HASSECURITY 1
#define HASNOSOCKSECURITY 1
#undef WARNINGSTATE
#undef HASDCACHE
#undef HASENVDC
#undef HASPERSDC
#undef HASPERSDCPATH
#undef HASSYSDC
#undef HASKERNIDCK" >> dialects/linux/machine.h
LSOF_VSTR="2.6.22" \
LINUX_BASE=/proc \
./Configure -n linux
make DEBUG="" CDEF="%{optflags}" CFGL="-L./lib -llsof -lselinux -ltirpc"
#make -C tests test opt
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
cd %{name}_%{version}_src
install -D -m755 %{name} %{buildroot}%{_bindir}/%{name}
install -D -m644 %{name}.8 %{buildroot}%{_mandir}/man8/%{name}.8
rm -fr %{name}_docs
install -d %{name}_docs
for f in 00{CREDITS,DIST,FAQ,LSOF-L,PORTING,QUICKSTART,README,TEST,XCONFIG}; do
install $f %{name}_docs/${f/00/}
done
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files
%defattr(-,root,root)
%{_bindir}/%{name}
%{_mandir}/man8/%{name}.*
%doc %{name}_%{version}_src/%{name}_docs/*
%changelog
* Mon Jan 14 2013 Automatic Build System <autodist@mambasoft.it> 4.87-1mamba
- automatic version update by autodist
* Fri Jun 15 2012 Automatic Build System <autodist@mambasoft.it> 4.86-1mamba
- automatic version update by autodist
* Mon Oct 03 2011 Automatic Build System <autodist@mambasoft.it> 4.85-1mamba
- automatic version update by autodist
* Sat Jul 31 2010 Automatic Build System <autodist@mambasoft.it> 4.84-1mamba
- automatic update by autodist
* Sat Jan 23 2010 Automatic Build System <autodist@mambasoft.it> 4.83-1mamba
- automatic update by autodist
* Wed Apr 08 2009 Silvan Calarco <silvan.calarco@mambasoft.it> 4.82-1mamba
- automatic update by autodist
* Sun Nov 02 2008 Silvan Calarco <silvan.calarco@mambasoft.it> 4.81-1mamba
- automatic update by autodist
* Tue Nov 13 2007 Aleph0 <aleph0@openmamba.org> 4.77-2mamba
- force LINUX_BASE environment
* Wed Jun 28 2006 Stefano Cotta Ramusino <stefano.cotta@qilinux.it> 4.77-1qilnx
- update to version 4.77 by autospec
* Wed May 11 2005 Davide Madrisan <davide.madrisan@qilinux.it> 4.74-1qilnx
- package created by autospec