equal
deleted
inserted
replaced
43 obj-m := ec_master.o |
43 obj-m := ec_master.o |
44 |
44 |
45 ec_master-objs := module.o master.o device.o slave.o command.o types.o \ |
45 ec_master-objs := module.o master.o device.o slave.o command.o types.o \ |
46 domain.o mailbox.o canopen.o ethernet.o debug.o fsm.o |
46 domain.o mailbox.o canopen.o ethernet.o debug.o fsm.o |
47 |
47 |
48 REV := $(shell svnversion $(src) 2>/dev/null) |
48 REV := $(shell svnversion $(src) 2>/dev/null || echo "unknown") |
49 |
49 |
50 EXTRA_CFLAGS := -DSVNREV=$(REV) -DUSER=$(USER) |
50 EXTRA_CFLAGS := -DSVNREV=$(REV) -DUSER=$(USER) |
51 |
51 |
52 #------------------------------------------------------------------------------ |
52 #------------------------------------------------------------------------------ |
53 |
53 |
60 include ../ethercat.conf |
60 include ../ethercat.conf |
61 else |
61 else |
62 KERNEL := $(shell uname -r) |
62 KERNEL := $(shell uname -r) |
63 endif |
63 endif |
64 |
64 |
65 KERNELDIR := /lib/modules/$(KERNEL)/build |
65 KERNEL_DIR := /lib/modules/$(KERNEL)/build |
|
66 CURRENT_DIR := $(shell pwd) |
66 |
67 |
67 modules: |
68 modules: |
68 $(MAKE) -C $(KERNELDIR) M=`pwd` |
69 $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) |
69 |
70 |
70 clean: |
71 clean: |
71 $(MAKE) -C $(KERNELDIR) M=`pwd` clean |
72 $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) clean |
72 |
73 |
73 #------------------------------------------------------------------------------ |
74 #------------------------------------------------------------------------------ |
74 |
75 |
75 endif |
76 endif |