KlugyTools/CheckResolv/Makefile

61 lines
1.5 KiB
Makefile

#-------------------------------------------------------------------
#
# CheckResolv
#
# editable configuration variables:
DESTDIR = /usr/local
COPT = -g -ansi -Wall
#
# you can now compile with "make checkresolv" and install it
# with "su -c 'make install'"
#
#-------------------------------------------------------------------
VERSION=0.25
all:
@echo
@echo " may be you can read (and edit) the Makefile before"
@echo " trying to compile and run that kludge..."
@echo
@echo " for impatients: try \"make checkresolv\""
@echo
checkresolv.o: checkresolv.c Makefile fonctions.h
gcc $(COPT) -c -DVERSION=\"$(VERSION)\" -DTRACE=0 $<
fonctions.o: fonctions.c Makefile fonctions.h
gcc $(COPT) -c -DVERSION=\"$(VERSION)\" -DTRACE=0 $<
checkresolv: checkresolv.o fonctions.o
gcc $(COPT) $^ -o $@
#-------------------------------------------------------------------
#
# install procedure is _also_ quick and dirty
#
install:
install --strip checkresolv $(DESTDIR)/bin
install checkresolv.man $(DESTDIR)/man/man1/checkresolv.1
#-------------------------------------------------------------------
FILES=*.c *.h Makefile CHANGELOG README TODO checkresolv.man *.html
TARNAME=checkresolv-$(VERSION).tar.gz
tarball: $(FILES)
@echo "Tarball is" $(TARNAME)
@ls $^ > MANIFEST ; \
( cd .. ; \
tar zcvf $(TARNAME) `sed 's/^/CheckResolv\//' CheckResolv/MANIFEST` )
@date >> tarball
@wc -c ../$(TARNAME)
lines: $(FILES)
wc $(FILES) | sort -n
#-------------------------------------------------------------------