# Makefile for the Linux chaosnet driver
#

.PHONY: dummy

ifndef TOPDIR
TOPDIR=/usr/src/linux
endif

OBJS = chlinux.o chaos.o chether.o challoc.o chconf.o chtime.o

all:	$(OBJS)

ifndef HOSTCC
#
#	Running outside the kernel build.
#
CC	= gcc
HOSTCC	= gcc
#CFLAGS	= -O2 -D__KERNEL__ -DMODULE -I../h -I/usr/src/linux/include -Wall -Wstrict-prototypes -fomit-frame-pointer -pipe -m486
CFLAGS	= -g -D__KERNEL__ -DMODULE -I../h -I/usr/src/linux/include -fomit-frame-pointer -pipe -m486
else
include $(TOPDIR)/Rules.make
endif

clean:
	rm -f core core.* *.o *.a

dep:
	$(CPP) -M *.c > .depend

#
# include a dependency file if one exists
#
ifeq (.depend,$(wildcard .depend))
include .depend
endif
