mini/Makefile
author Florian Pose <fp@igh-essen.com>
Fri, 04 Nov 2005 17:51:36 +0000
changeset 8 f2ebe943c686
parent 5 6f2508af550c
child 9 144d220c8ca0
permissions -rw-r--r--
Spaces am Zeilenende entfernt.
#----------------------------------------------------------------
#
#  Makefile
#
#  Minimales EtherCAT-Modul
#
#  $Id$
#
#----------------------------------------------------------------

EC_DIR = /vol/projekte/msr_messen_steuern_regeln/ethercat

#KERNELDIR = $(EC_DIR)/linux-2.4.20.CX1100-rthal5-kdb
KERNELDIR = $(EC_DIR)/linux-2.4.20-kdb
#KERNELDIR = /usr/src/linux

CFLAGS = -O2 -Wall -Wuninitialized -D__KERNEL__ \
	-DMODULE -I$(KERNELDIR)/include

MODULE = ec_mini_mod.o

SRC = ec_mini.c
OBJ = $(SRC:.c=.o)

#----------------------------------------------------------------

all: .depend Makefile $(MODULE)

$(MODULE): $(OBJ)
	$(LD) -r $(OBJ) -o $@

#----------------------------------------------------------------

depend .depend dep:
	$(CC) $(CFLAGS) -M $(SRC) > .depend

ifeq (.depend,$(wildcard .depend))
include .depend
endif

#----------------------------------------------------------------

clean:
	rm -f *.o *~ core .depend

#----------------------------------------------------------------