-LiSt Open Files-

   
 Makefile を修正する。
 赤字 のところを書き加えました。
  ↓

[root@server2 lsof_4.68_src]# vi Makefile

# linux Makefile for lsof revision 4.68

CC= cc

CCV= 2.95.3 20010315 (release)

LIB= lib/liblsof.a

CFGF= -DLINUXV=24019 -DGLIBCV=202 -DHASIPv6 -D_FILE_OFFSET_BITS=64 -DLSOF_VSTR=\"2.4.19-0vl11\"

CFGL= -L./lib -llsof

DEBUG= -O

# Linux /proc-based Makefile
#
# $Id: Makefile,v 1.9 2001/11/01 20:26:27 abe Exp abe $

PROG= lsof

BIN= ${DESTDIR} /sbin

DOC= ${DESTDIR} /usr/man/man8

I=/usr/include
S=/usr/include/sys
L=/usr/include/local
P=

CDEF=
CDEFS= ${CDEF} ${CFGF}
DEP= ${CFGD} ${CFGDN}
INCL= ${DINC}
CFLAGS= ${CDEFS} ${INCL} ${DEP} ${DEBUG}

GRP= sys

HDR= lsof.h lsof_fields.h dlsof.h machine.h proto.h dproto.h

SRC= dfile.c dmnt.c dnode.c dproc.c dsock.c dstore.c \
arg.c main.c misc.c node.c print.c proc.c store.c usage.c

OBJ= dfile.o dmnt.o dnode.o dproc.o dsock.o dstore.o \
arg.o main.o misc.o node.o print.o proc.o store.o usage.o

MAN= lsof.8

OTHER=

SHELL= /bin/sh

SOURCE= Makefile ${OTHER} ${MAN} ${HDR} ${SRC}

all: ${PROG}

${PROG}: ${P} ${LIB} ${OBJ}
${CC} -o $@ ${OBJ} ${CFGL}

clean: FRC
rm -f Makefile.bak ${PROG} a.out core errs lint.out tags *.o version.h ${CFGDN}
rm -f machine.h.old new_machine.h
(cd lib; ${MAKE} -f Makefile.skel clean)

install: all FRC
@echo ''
@echo 'Please write your own install rule. Lsof should be installed'
@echo 'setuid to root if you wish any lsof user to be able to examine'
@echo 'all open files. Your install rule actions might look something'
@echo 'like this:'
@echo ''
@echo ' install -m 4xxx -o root -g <group> $${PROG} $${BIN}'
@echo ' install -m 444 $${MAN} $${DOC}'
@echo ''
@echo 'You will have to complete the 4xxx modes, the <group> value,'
@echo 'and the skeletons for the BIN and DOC strings, given at the'
@echo 'beginning of this Makefile, e.g.,'
@echo ''
@echo ' BIN= $${DESTDIR}/usr/local/etc'
@echo ' DOC= $${DESTDIR}/usr/man/man8'
@echo ' GRP= sys'
@echo ''
install -m 4500 -o root -g ${GRP} ${PROG} ${BIN}
install -m 444 ${MAN} ${DOC}

${LIB}: FRC
(cd lib; ${MAKE} DEBUG="${DEBUG}" CFGF="${CFGF}")

version.h: FRC
@echo Constructing version.h
@rm -f version.h
@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
@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 \
echo '#define LSOF_HOST "'`uname -n`'"' >> version.h; \
else \
if [ "${LSOF_HOST}" = "none" ]; then \
echo '#define LSOF_HOST ""' >> version.h; \
else \
echo '#define LSOF_HOST "${LSOF_HOST}"' >> version.h; \
fi \
fi
@echo '#define LSOF_LDFLAGS "${CFGL}"' >> version.h
@if [ "X${LSOF_LOGNAME}" = "X" ]; then \
echo '#define LSOF_LOGNAME "${LOGNAME}"' >> version.h; \
else \
if [ "${LSOF_LOGNAME}" = "none" ]; then \
echo '#define LSOF_LOGNAME ""' >> version.h; \
else \
echo '#define LSOF_LOGNAME "${LSOF_LOGNAME}"' >> version.h; \
fi; \
fi
@if [ "X${LSOF_SYSINFO}" = "X" ]; then \
echo '#define LSOF_SYSINFO "'`uname -a`'"' >> version.h; \

---- Makefile 以下省略 ----------------------------------------


Makefileに手を加えたので 改めて # make install してみました。
がぁ!!!!
またもや エラ〜 ((+_+))

[root@server2 lsof_4.68_src]# make install
(cd lib; make DEBUG="-O" CFGF="-DLINUXV=24019 -DGLIBCV=202 -DHASIPv6 -D_FILE_OFFSET_BITS=64 -DLSOF_V
STR=\"2.4.19-0vl11\"")
make[1]: 入ります ディレクトリ `/usr/local/src/lsof_4.68/lsof_4.68_src/lib'
make[1]: `all' に対して行うべき事はありません。
make[1]: 出ます ディレクトリ `/usr/local/src/lsof_4.68/lsof_4.68_src/lib'
Constructing version.h
cc -DLINUXV=24019 -DGLIBCV=202 -DHASIPv6 -D_FILE_OFFSET_BITS=64 -DLSOF_VSTR=\"2.4.19-0vl11\" -O
-c -o usage.o usage.c
cc -o lsof dfile.o dmnt.o dnode.o dproc.o dsock.o dstore.o arg.o main.o misc.o node.o print.o proc.o
store.o usage.o -L./lib -llsof

Please write your own install rule. Lsof should be installed
setuid to root if you wish any lsof user to be able to examine
all open files. Your install rule actions might look something
like this:

install -m 4xxx -o root -g <group> ${PROG} ${BIN}
install -m 444 ${MAN} ${DOC}

You will have to complete the 4xxx modes, the <group> value,
and the skeletons for the BIN and DOC strings, given at the
beginning of this Makefile, e.g.,

BIN= ${DESTDIR}/usr/local/etc
DOC= ${DESTDIR}/usr/man/man8
GRP= sys

install -m 4500 -o root -g sys lsof /sbin
install -m 444 lsof.8 /usr/man/man8
install: ファイル ``/usr/man/man8'' を作ることができませんでした: そのようなファイルやディレクトリは
ありません
make: *** [install] エラー 1