# HG changeset patch # User Florian Pose # Date 1151331636 0 # Node ID c91bbf7bc52c570ff8a94e5fd34de8afe514cc8e # Parent 35c99cdda518c7807be993afeefecfaead822e94 Better modules_install targets. diff -r 35c99cdda518 -r c91bbf7bc52c Makefile --- a/Makefile Mon Jun 26 11:28:24 2006 +0000 +++ b/Makefile Mon Jun 26 14:20:36 2006 +0000 @@ -1,7 +1,7 @@ #------------------------------------------------------------------------------ # # Makefile -# +# # IgH EtherCAT master # # $Id$ @@ -55,6 +55,7 @@ KERNEL_DIR := /lib/modules/$(KERNEL)/build CURRENT_DIR := $(shell pwd) +INSTALL_MOD_DIR := ethercat modules: $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) modules @@ -63,8 +64,8 @@ @script/install.sh $(KERNEL) modules_install: - $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR)/master modules_install - $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR)/devices modules_install + $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) \ + INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) modules_install clean: cleandoc $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) clean diff -r 35c99cdda518 -r c91bbf7bc52c devices/Makefile --- a/devices/Makefile Mon Jun 26 11:28:24 2006 +0000 +++ b/devices/Makefile Mon Jun 26 14:20:36 2006 +0000 @@ -61,6 +61,7 @@ KERNEL_DIR := /lib/modules/$(KERNEL)/build CURRENT_DIR := $(shell pwd) +INSTALL_MOD_DIR := ethercat/devices modules: $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) modules @@ -68,7 +69,8 @@ install: modules_install modules_install: - $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) modules_install + $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) \ + INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) modules_install clean: $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) clean diff -r 35c99cdda518 -r c91bbf7bc52c ethercat.conf.tmpl --- a/ethercat.conf.tmpl Mon Jun 26 11:28:24 2006 +0000 +++ b/ethercat.conf.tmpl Mon Jun 26 14:20:36 2006 +0000 @@ -12,6 +12,6 @@ # # The kernel to compile the EtherCAT sources against # -KERNEL := `uname -r` +KERNEL := $(shell uname -r) #------------------------------------------------------------------------------ diff -r 35c99cdda518 -r c91bbf7bc52c master/Makefile --- a/master/Makefile Mon Jun 26 11:28:24 2006 +0000 +++ b/master/Makefile Mon Jun 26 14:20:36 2006 +0000 @@ -62,6 +62,7 @@ KERNEL_DIR := /lib/modules/$(KERNEL)/build CURRENT_DIR := $(shell pwd) +INSTALL_MOD_DIR := ethercat/master modules: $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) modules @@ -69,7 +70,8 @@ install: modules_install modules_install: - $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) modules_install + $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) \ + INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) modules_install clean: $(MAKE) -C $(KERNEL_DIR) M=$(CURRENT_DIR) clean