Japanese Only
--prefixでインストールするディレクトリを指定して、CFLAGSで、HAVE_INET_ATONをdefine。$ ./configure --prefix=/home/psv/local CFLAGS=-DHAVE_INET_ATON間違えました(^_^; $ export CFLAGS=-DHAVE_INET_ATON;./configure --prefix=/home/psv/local の方が、良いです。(2001.7.23 修正)
$ grep HAVE_INET_ATON Makefile CFLAGS = -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified $(CCOPT) $(DEFS) $(INCLS) $ make (省略) gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -DHAVE_MALLOC_H= 1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./pcap-linu x.c gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -DHAVE_MALLOC_H= 1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./pcap.c gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -DHAVE_MALLOC_H= 1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./inet.c gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -DHAVE_MALLOC_H= 1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./gencode.c (省略) $ make install ./shtool mkdir -f -p -m 755 /home/psv/local/bin /home/psv/local/man/ma n1 /home/psv/local/share/nmap /home/psv/local/share/gnome/apps/Utiliti es ./shtool install -c -m 755 nmap /home/psv/local/bin/nmap If the next command fails -- you cannot use the X front end test -f nmapfe/nmapfe && ./shtool install -c -m 755 nmapfe/nmapfe /home/psv /local/bin/nmapfe && ./shtool mkln -f -s /home/psv/local/bin/nmapfe /home/ psv/local/bin/xnmap && ./shtool install -c -m 644 nmapfe.desktop /home/psv/ local/share/gnome/apps/Utilities/nmapfe.desktop && ./shtool install -c -m 644 docs/nmapfe.1 /home/psv/local/man/man1/nmapfe.1 && ./shtool install - c -m 644 docs/xnmap.1 /home/psv/local/man/man1/xnmap.1 ./shtool install -c -m 644 docs/nmap.1 /home/psv/local/man/man1/nmap.1 ./shtool install -c -m 644 nmap-os-fingerprints /home/psv/local/share/nma p/nmap-os-fingerprints ./shtool install -c -m 644 nmap-services /home/psv/local/share/nmap/nmap- services ./shtool install -c -m 644 nmap-rpc /home/psv/local/share/nmap/nmap-rpc $
$ nmap localhost Starting nmap V. 2.53 by fyodor@insecure.org ( www.insecure.org/nmap/ ) Interesting ports on psv-ps2linux (127.0.0.1): (The 1517 ports scanned but not shown below are in state: closed) Port State Service 21/tcp open ftp 23/tcp open telnet 98/tcp open linuxconf 111/tcp open sunrpc 515/tcp open printer 5680/tcp open canna Nmap run completed -- 1 IP address (1 host up) scanned in 1 second $ $ nmap 192.168.0.1 Starting nmap V. 2.53 by fyodor@insecure.org ( www.insecure.org/nmap/ ) All 1523 scanned ports on (192.168.0.1) are: closed Nmap run completed -- 1 IP address (1 host up) scanned in 3 seconds $という事で、めでたく動作OK。
という事なんで、PlayStation2にも簡単にインストール出来ました♪Changes for Fri Jun 15: 1.2.1: Added Linux PlayStation 2 Graphics Synthesizer support
[psv@psv-ps2linux src]$ pwd
/home/psv/local/src
[psv@psv-ps2linux src]$ ls
nmap-2.53.tgz
[psv@psv-ps2linux src]$ gunzip -c nmap-2.53.tgz | tar xvf -
[psv@psv-ps2linux nmap-2.53]$ ./configure --prefix=/home/psv/local CFLAGS=-DHAVE_INET_ATON
configure: warning: CFLAGS=-DHAVE_INET_ATON: invalid host type
creating cache ./config.cache
checking for gcc... gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking host system type... Invalid configuration `CFLAGS=-DHAVE_INET_ATON': ma
chine `CFLAGS=' not recognized
checking for gethostent... yes
checking for setsockopt... yes
checking for nanosleep... yes
checking how to run the C preprocessor... gcc -E
checking for pcap.h... no
checking for ANSI C header files... yes
checking for string.h... yes
checking for getopt.h... yes
checking for strings.h... yes
checking for memory.h... yes
checking for sys/param.h... yes
checking for sys/sockio.h... no
checking for netinet/if_ether.h... yes
checking for bstring.h... no
checking for sys/time.h... yes
checking whether time.h and sys/time.h may both be included... yes
checking for inline... inline
checking struct ip... yes
checking ip_v in struct ip... yes
checking if sockaddr{} has sa_len member... no
checking whether byte ordering is bigendian... no
checking if struct in_addr is a wacky huge structure (some Sun boxes)... no
checking if struct icmp exists... yes
checking if struct ip exists... yes
checking if struct ip has ip_sum member... yes
checking for bzero... yes
checking for snprintf... yes
checking for vsnprintf... yes
checking for memcpy... yes
checking for usleep... yes
checking for nanosleep... (cached) yes
checking for strerror... yes
checking for strcasestr... yes
checking for snprintf... (cached) yes
checking for inet_aton... yes
checking for getopt_long_only... yes
updating cache ./config.cache
creating ./config.status
creating Makefile
creating config.h
configuring in libpcap-possiblymodified
running /bin/sh ./configure --prefix=/home/psv/local CFLAGS=-DHAVE_INET_ATON --
cache-file=.././config.cache --srcdir=.
configure: warning: CFLAGS=-DHAVE_INET_ATON: invalid host type
loading cache .././config.cache
checking host system type... Invalid configuration `CFLAGS=-DHAVE_INET_ATON': ma
chine `CFLAGS=' not recognized
checking target system type... Invalid configuration `CFLAGS=-DHAVE_INET_ATON':
machine `CFLAGS=' not recognized
checking build system type... Invalid configuration `CFLAGS=-DHAVE_INET_ATON': m
achine `CFLAGS=' not recognized
checking for gcc... (cached) gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking gcc version... 2
checking how to run the C preprocessor... (cached) gcc -E
checking for malloc.h... yes
checking for sys/ioccom.h... no
checking for sys/sockio.h... (cached) no
checking for ANSI ioctl definitions... yes
checking for ether_hostton... yes
checking for strerror... (cached) yes
checking packet capture type... linux
checking for net/if_arp.h... yes
checking Linux kernel version... 2
checking for flex... flex
checking for flex 2.4 or higher... yes
checking for bison... bison
checking for ranlib... ranlib
checking if sockaddr struct has sa_len member... no
checking if unaligned accesses fail... no
checking for a BSD compatible install... /usr/bin/install -c
updating cache .././config.cache
creating ./config.status
creating Makefile
configuring in nmapfe
running /bin/sh ./configure --prefix=/home/psv/local CFLAGS=-DHAVE_INET_ATON --
cache-file=.././config.cache --srcdir=.
configure: warning: CFLAGS=-DHAVE_INET_ATON: invalid host type
loading cache .././config.cache
checking for gcc... (cached) gcc
checking whether the C compiler (gcc ) works... yes
checking whether the C compiler (gcc ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gtk-config... /usr/bin/gtk-config
checking for GTK - version >= 1.0.0... yes
updating cache .././config.cache
creating ./config.status
creating Makefile
[psv@psv-ps2linux nmap-2.53]$
[psv@psv-ps2linux nmap-2.53]$ pwd
/home/psv/local/src/nmap-2.53
[psv@psv-ps2linux nmap-2.53]$ export CFLAGS=-DHAVE_INET_ATON;./configure --prefix=/home/psv/local
creating cache ./config.cache
checking for gcc... gcc
checking whether the C compiler (gcc -DHAVE_INET_ATON ) works... yes
checking whether the C compiler (gcc -DHAVE_INET_ATON ) is a cross-compiler... n
o
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking host system type... mipsel-unknown-linux-gnu
checking for gethostent... yes
checking for setsockopt... yes
checking for nanosleep... yes
checking how to run the C preprocessor... gcc -E
checking for pcap.h... no
checking for ANSI C header files... yes
checking for string.h... yes
checking for getopt.h... yes
checking for strings.h... yes
checking for memory.h... yes
checking for sys/param.h... yes
checking for sys/sockio.h... no
checking for netinet/if_ether.h... yes
checking for bstring.h... no
checking for sys/time.h... yes
checking whether time.h and sys/time.h may both be included... yes
checking for inline... inline
checking struct ip... yes
checking ip_v in struct ip... yes
checking if sockaddr{} has sa_len member... no
checking whether byte ordering is bigendian... no
checking if struct in_addr is a wacky huge structure (some Sun boxes)... no
checking if struct icmp exists... yes
checking if struct ip exists... yes
checking if struct ip has ip_sum member... yes
checking for bzero... yes
checking for snprintf... yes
checking for vsnprintf... yes
checking for memcpy... yes
checking for usleep... yes
checking for nanosleep... (cached) yes
checking for strerror... yes
checking for strcasestr... yes
checking for snprintf... (cached) yes
checking for inet_aton... yes
checking for getopt_long_only... yes
updating cache ./config.cache
creating ./config.status
creating Makefile
creating config.h
configuring in libpcap-possiblymodified
running /bin/sh ./configure --prefix=/home/psv/local --cache-file=.././config.c
ache --srcdir=.
loading cache .././config.cache
checking host system type... mipsel-unknown-linux-gnu
checking target system type... mipsel-unknown-linux-gnu
checking build system type... mipsel-unknown-linux-gnu
checking for gcc... (cached) gcc
checking whether the C compiler (gcc -DHAVE_INET_ATON -Wall -Ilibpcap-possiblym
odified ) works... yes
checking whether the C compiler (gcc -DHAVE_INET_ATON -Wall -Ilibpcap-possiblym
odified ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking gcc version... 2
checking how to run the C preprocessor... (cached) gcc -E
checking for malloc.h... yes
checking for sys/ioccom.h... no
checking for sys/sockio.h... (cached) no
checking for ANSI ioctl definitions... yes
checking for ether_hostton... yes
checking for strerror... (cached) yes
checking packet capture type... linux
checking for net/if_arp.h... yes
checking Linux kernel version... 2
checking for flex... flex
checking for flex 2.4 or higher... yes
checking for bison... bison
checking for ranlib... ranlib
checking if sockaddr struct has sa_len member... no
checking if unaligned accesses fail... no
checking for a BSD compatible install... /usr/bin/install -c
updating cache .././config.cache
creating ./config.status
creating Makefile
configuring in nmapfe
running /bin/sh ./configure --prefix=/home/psv/local --cache-file=.././config.c
ache --srcdir=.
loading cache .././config.cache
checking for gcc... (cached) gcc
checking whether the C compiler (gcc -DHAVE_INET_ATON -Wall -Ilibpcap-possiblym
odified ) works... yes
checking whether the C compiler (gcc -DHAVE_INET_ATON -Wall -Ilibpcap-possiblym
odified ) is a cross-compiler... no
checking whether we are using GNU C... (cached) yes
checking whether gcc accepts -g... (cached) yes
checking for gtk-config... /usr/bin/gtk-config
checking for GTK - version >= 1.0.0... yes
updating cache .././config.cache
creating ./config.status
creating Makefile
[psv@psv-ps2linux nmap-2.53]$
という事で、無事インストール出来ました。[psv@psv-ps2linux nmap-2.53]$ pwd /home/psv/local/src/nmap-2.53 [psv@psv-ps2linux nmap-2.53]$ make Compiling libpcap make[1]: Entering directory `/home/psv/local/src/nmap-2.53/libpcap-possiblymodif ied' gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -Ilinux-include -DHAVE_MALLOC_H=1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./pcap-linux.c gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -Ilinux-include -DHAVE_MALLOC_H=1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./pcap.c gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -Ilinux-include -DHAVE_MALLOC_H=1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./inet.c gcc -O2 -DHAVE_INET_ATON -Wall -Ilibpcap-possiblymodified -I. -Ilinux-include -DHAVE_MALLOC_H=1 -DHAVE_ETHER_HOSTTON=1 -DHAVE_STRERROR=1 -DHAVE_NET_IF_ARP_H=1 -c ./gencode.c (省略) /usr/bin/ld: /usr/lib/libgmodule.so: invalid string offset 23718 >= 703 for sect ion `.dynstr' /usr/bin/ld: /usr/X11R6/lib/libXi.so: invalid string offset 25236 >= 1463 for se ction `.dynstr' /usr/bin/ld: /usr/X11R6/lib/libXext.so: invalid string offset 28000 >= 2970 for section `.dynstr' make[1]: Leaving directory `/home/psv/local/src/nmap-2.53/nmapfe' END OF SECTION WHERE FAILURES ARE OK [psv@psv-ps2linux nmap-2.53]$ [psv@psv-ps2linux nmap-2.53]$ make install ./shtool mkdir -f -p -m 755 /home/psv/local/bin /home/psv/local/man/man1 /home/p sv/local/share/nmap /home/psv/local/share/gnome/apps/Utilities ./shtool install -c -m 755 nmap /home/psv/local/bin/nmap If the next command fails -- you cannot use the X front end test -f nmapfe/nmapfe && ./shtool install -c -m 755 nmapfe/nmapfe /home/psv/loc al/bin/nmapfe && ./shtool mkln -f -s /home/psv/local/bin/nmapfe /home/psv/local/ bin/xnmap && ./shtool install -c -m 644 nmapfe.desktop /home/psv/local/share/gn ome/apps/Utilities/nmapfe.desktop && ./shtool install -c -m 644 docs/nmapfe.1 / home/psv/local/man/man1/nmapfe.1 && ./shtool install -c -m 644 docs/xnmap.1 /ho me/psv/local/man/man1/xnmap.1 ./shtool install -c -m 644 docs/nmap.1 /home/psv/local/man/man1/nmap.1 ./shtool install -c -m 644 nmap-os-fingerprints /home/psv/local/share/nmap/nma p-os-fingerprints ./shtool install -c -m 644 nmap-services /home/psv/local/share/nmap/nmap-servi ces ./shtool install -c -m 644 nmap-rpc /home/psv/local/share/nmap/nmap-rpc [psv@psv-ps2linux nmap-2.53]$
とするのが良いでしょう。[psv@psv-ps2linux nmap-2.53]$ export CFLAGS=-DHAVE_INET_ATON;./configure --prefix=/home/psv/local [psv@psv-ps2linux nmap-2.53]$ make [psv@psv-ps2linux nmap-2.53]$ make install
$ pwd /usr/local/squid $ ls -al total 28 drwxr-xr-x 7 root root 4096 Jul 29 09:43 . drwxr-xr-x 13 root root 4096 Jul 29 09:26 .. drwxr-xr-x 2 root root 4096 Jul 29 09:25 bin drwxr-xr-x 18 nobody nogroup 4096 Jul 29 12:09 cache drwxr-xr-x 4 root root 4096 Jul 29 12:08 etc drwxr-xr-x 3 root root 4096 Jul 29 09:25 libexec drwxr-xr-x 2 nobody nogroup 4096 Jul 29 12:09 logs $
$ pwd /usr/local/squid/etc $ diff squid.conf.default squid.conf 48a49 > http_port 8080 406a408 > cache_mem 8 MB 602a605 > cache_dir ufs /usr/local/squid/cache 1024 16 256 1412a1416,1418 > > #2001.7.29 add this line > acl allowed_hosts src 192.168.0.2-192.168.0.5/255.255.255.255 192.168.0.1 1439c1445 < http_access deny manager --- > http_access deny manager all 1447a1454 > http_access allow allowed_hosts 1462c1469,1470 < icp_access allow all --- > icp_access allow allowed_hosts > icp_access deny all 1532a1541 > cache_mgr hogehoge 1547a1557,1558 > cache_effective_user nobody > cache_effective_group nogroup $