Makefile
e60a9728
 # $Id$
 #
 # sip_router makefile
 #
1b1b19d8
 # WARNING: requires gmake (GNU Make)
 #
e60a9728
 
 sources= $(wildcard *.c)
828920bb
 objs= $(sources:.c=.o)
e60a9728
 depends= $(sources:.c=.d)
 
 NAME=sip_router
 
 CC=gcc
1b1b19d8
 CFLAGS=-O2
 # on linux and freebsd keep it empty (e.g. LIBS= )
 # on solaris add -lxnet (e.g. LIBS= -lxnet)
 LIBS=
e60a9728
 ALLDEP=Makefile
 
 MKDEP=gcc -M
 
 
 #implicit rules
 
 %.o:%.c $(ALLDEP)
1b1b19d8
 	$(CC) $(CFLAGS) -c $< -o $@
e60a9728
 
 %.d: %.c
 	$(MKDEP) $< >$@
 
 $(NAME): $(objs)
1b1b19d8
 	$(CC) $(CFLAGS) $(LIBS) $(objs) -o $(NAME)
e60a9728
 
 .PHONY: all
 all: $(NAME)
 
 .PHONY: dep
 dep: $(depends)
 
 .PHONY: clean
 clean:
 	-rm $(objs) $(NAME)
 
 .PHONY: proper
 proper: clean
 	-rm $(depends)
 
 include $(depends)