equal
deleted
inserted
replaced
1 #------------------------------------------------------------------------------ |
1 #------------------------------------------------------------------------------ |
2 # |
2 # |
3 # Makefile |
3 # Makefile |
4 # |
4 # |
5 # IgH EtherCAT-Treiber |
5 # IgH EtherCAT master module |
6 # |
6 # |
7 # $Id$ |
7 # $Id$ |
8 # |
8 # |
9 #------------------------------------------------------------------------------ |
9 #------------------------------------------------------------------------------ |
10 |
10 |
11 ifneq ($(KERNELRELEASE),) |
11 ifneq ($(KERNELRELEASE),) |
12 |
12 |
13 #------------------------------------------------------------------------------ |
13 #------------------------------------------------------------------------------ |
14 # Kbuild-Abschnitt |
14 # kbuild section |
15 |
15 |
16 obj-m := ec_master.o |
16 obj-m := ec_master.o |
17 |
17 |
18 ec_master-objs := module.o master.o device.o slave.o command.o types.o \ |
18 ec_master-objs := module.o master.o device.o slave.o command.o types.o \ |
19 domain.o mailbox.o canopen.o ethernet.o |
19 domain.o mailbox.o canopen.o ethernet.o |
23 #------------------------------------------------------------------------------ |
23 #------------------------------------------------------------------------------ |
24 |
24 |
25 else |
25 else |
26 |
26 |
27 #------------------------------------------------------------------------------ |
27 #------------------------------------------------------------------------------ |
28 # Default-Abschnitt |
28 # default section |
29 |
29 |
30 ifneq ($(wildcard ethercat.conf),) |
30 ifneq ($(wildcard ../ethercat.conf),) |
31 include ethercat.conf |
31 include ../ethercat.conf |
32 else |
32 else |
33 KERNELDIR = /lib/modules/`uname -r`/build |
33 KERNEL := $(shell uname -r) |
34 endif |
34 endif |
35 |
35 |
|
36 KERNELDIR = /lib/modules/$(KERNEL)/build |
|
37 |
36 modules: |
38 modules: |
37 $(MAKE) -C $(KERNELDIR) M=`pwd` modules |
39 $(MAKE) -C $(KERNELDIR) M=`pwd` |
38 |
40 |
39 clean: cleandoc |
41 clean: |
40 $(MAKE) -C $(KERNELDIR) M=`pwd` clean |
42 $(MAKE) -C $(KERNELDIR) M=`pwd` clean |
41 |
|
42 doc: |
|
43 doxygen Doxyfile |
|
44 |
|
45 cleandoc: |
|
46 @rm -rf doc |
|
47 |
|
48 .PHONY: doc cleandoc modules clean |
|
49 |
43 |
50 #------------------------------------------------------------------------------ |
44 #------------------------------------------------------------------------------ |
51 |
45 |
52 endif |
46 endif |