###################################################
#
# Makefile for pwhoisd
# Creator [Xcode -> Makefile Ver: May  8 2006 13:39:03]
# Created: [Tue Feb 13 01:58:19 2007]
#
###################################################

#
# Macros
#

# CC = /usr/bin/gcc
CC_OPTIONS = -g
LNK_OPTIONS = -L/usr/local/pgsql/lib -lpq -lpthread


#
# INCLUDE directories for pwhoisd
#

INCLUDE = -I/usr/local/pgsql/include


#
# Build pwhoisd
#

pwhoisd : \
		main.o\
		pwhois_thread.o\
		geounit.o\
		IPV4.o\
		logger.o\
		patricia.o\
		timeformat.o\
		arinunit.o\
		tst_malloc.o
	$(CC) $(LNK_OPTIONS) \
		main.o\
		pwhois_thread.o\
		geounit.o\
		IPV4.o\
		logger.o\
		patricia.o\
		timeformat.o\
		arinunit.o\
		tst_malloc.o\
		-o pwhoisd

clean : 
		rm \
		main.o\
		pwhois_thread.o\
		geounit.o\
		IPV4.o\
		logger.o\
		patricia.o\
		timeformat.o\
		arinunit.o\
		tst_malloc.o\
		pwhoisd

install : pwhoisd
		cp pwhoisd pwhoisd

#
# Build the parts of pwhoisd
#


# Item # 1 -- main --
main.o : main.c
	$(CC) $(CC_OPTIONS) main.c -c $(INCLUDE) -o main.o


# Item # 2 -- pwhois_thread --
pwhois_thread.o : pwhois_thread.c
	$(CC) $(CC_OPTIONS) pwhois_thread.c -c $(INCLUDE) -o pwhois_thread.o


# Item # 3 -- geounit --
geounit.o : geounit.c
	$(CC) $(CC_OPTIONS) geounit.c -c $(INCLUDE) -o geounit.o


# Item # 4 -- IPV4 --
IPV4.o : IPV4.c
	$(CC) $(CC_OPTIONS) IPV4.c -c $(INCLUDE) -o IPV4.o


# Item # 5 -- logger --
logger.o : logger.c
	$(CC) $(CC_OPTIONS) logger.c -c $(INCLUDE) -o logger.o


# Item # 6 -- patricia --
patricia.o : patricia.c
	$(CC) $(CC_OPTIONS) patricia.c -c $(INCLUDE) -o patricia.o


# Item # 7 -- timeformat --
timeformat.o : timeformat.c
	$(CC) $(CC_OPTIONS) timeformat.c -c $(INCLUDE) -o timeformat.o


# Item # 8 -- arinunit --
arinunit.o : arinunit.c
	$(CC) $(CC_OPTIONS) arinunit.c -c $(INCLUDE) -o arinunit.o


# Item # 9 -- tst_malloc --
tst_malloc.o : tst_malloc.c
	$(CC) $(CC_OPTIONS) tst_malloc.c -c $(INCLUDE) -o tst_malloc.o


##### END RUN ####
