"Fossies" - the Fresh Open Source Software Archive

Member "fake-1.1.11/Makefile" (8 Jul 2009, 2704 Bytes) of package /linux/misc/old/fake-1.1.11.tar.gz:


As a special service "Fossies" has tried to format the requested text file into HTML format (style: standard) with prefixed line numbers. Alternatively you can here view or download the uninterpreted source code file.

    1 ######################################################################
    2 # Makefile for fake                                       October 1998
    3 # Horms                                             horms@verge.net.au
    4 #
    5 # Fake
    6 # Script to spoof an ip
    7 # Designed to create redundant servers
    8 # Copyright (C) 1998  Horms <horms@verge.net.au>
    9 # 
   10 # This program is free software; you can redistribute it and/or modify
   11 # it under the terms of the GNU General Public License as published by
   12 # the Free Software Foundation; either version 2 of the License, or
   13 # (at your option) any later version.
   14 # 
   15 # This program is distributed in the hope that it will be useful, but
   16 # WITHOUT ANY WARRANTY; without even the implied warranty of
   17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
   18 # General Public License for more details.
   19 # 
   20 # You should have received a copy of the GNU General Public License
   21 # along with this program; if not, write to the Free Software
   22 # Foundation, Inc., 59 Temple Place, Suite 330,
   23 ######################################################################
   24 
   25 ROOT_DIR=
   26 BIN_DIR=$(ROOT_DIR)/usr/sbin
   27 BIN=fake
   28 CONFIG_DIR=$(ROOT_DIR)/etc/fake
   29 CONFIG=.fakerc clear_routers
   30 INSTANCE_CONFIG_DIR=$(ROOT_DIR)/etc/fake/instance_config
   31 INSTANCE_CONFIG=instance_config/203.12.97.7.cfg \
   32 instance_config/192.168.89.19.cfg
   33 MAN8=fake.8 send_arp.8
   34 MAN8_DIR=$(ROOT_DIR)/usr/man/man8
   35 DOC_DIR=$(ROOT_DIR)/usr/doc/fake-1.1.10
   36 DOCS=README AUTHORS COPYING ChangeLog
   37 SUBDIR=send_arp heartbeat
   38 
   39 .PHONY: all install clean patch
   40 
   41 all: patch
   42 	for i in $(SUBDIR); do make -C $$i all; done
   43 
   44 clean: patch
   45 	for i in $(SUBDIR); do make -C $$i clean; done
   46 	make unpatch
   47 	rm -f core send_arp/send_arp.c.orig
   48 
   49 install: all
   50 	for i in $(SUBDIR); do make -C $$i install; done
   51 	test -d $(BIN_DIR) || mkdir -p $(BIN_DIR)
   52 	install -c -m 755 $(BIN) $(BIN_DIR)
   53 	test -d $(CONFIG_DIR) || mkdir -p $(CONFIG_DIR)
   54 	install -c -m 644 $(CONFIG) $(CONFIG_DIR)
   55 	test -d $(INSTANCE_CONFIG_DIR) || mkdir -p $(INSTANCE_CONFIG_DIR)
   56 	install -c -m 644 $(INSTANCE_CONFIG) $(INSTANCE_CONFIG_DIR)
   57 	test -d $(DOC_DIR) || mkdir -p $(DOC_DIR)
   58 	install -c -m 644 $(DOCS) $(DOC_DIR)
   59 	test -d $(MAN8_DIR) || mkdir -p $(MAN8_DIR)
   60 	install -c -m 644 $(MAN8) $(MAN8_DIR)
   61 
   62 patch:
   63 	cd send_arp ; test -f Makefile ||  \
   64 		( patch -p 1 < ../send_arp.patch ; \
   65 		patch -p 1 < ../send_arp.dev.patch ; \
   66 		patch -p 1 < ../send_arp.l2.patch ; \
   67 		patch -p 1 < ../send_arp.request_reply.patch ; )
   68 
   69 unpatch:
   70 	cd send_arp ; test -f Makefile &&  \
   71 		( patch -p 1 -R < ../send_arp.request_reply.patch ; \
   72 		patch -p 1 -R < ../send_arp.l2.patch ; \
   73 		patch -p 1 -R < ../send_arp.dev.patch ; \
   74 		patch -p 1 -R < ../send_arp.patch )
   75 	cd send_arp ; rm -f Makefile
   76