Skip to contentSkip to conversation

fix ATM makefile for out-of-source-tree builds

PATCH Applied Jan Beulich 4 participants 4 messages May 12, 2005 – Jun 2, 2005 ATM

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 fix ATM makefile for out-of-source-tree builds

(Note: Patch also attached because the inline version is certain to get line wrapped.)

Adjust ATM makefile to account for building outside of the source tree.

drivers/atm/Makefile +2 -1
diff -Npru linux-2.6.12-rc4.base/drivers/atm/Makefile linux-2.6.12-rc4/drivers/atm/Makefile
@@ -39,7 +39,8 @@ ifeq ($(CONFIG_ATM_FORE200E_PCA),y)
   fore_200e-objs		+= fore200e_pca_fw.o
   # guess the target endianess to choose the right PCA-200E firmware image
   ifeq ($(CONFIG_ATM_FORE200E_PCA_DEFAULT_FW),y)
-    CONFIG_ATM_FORE200E_PCA_FW = $(shell if test -n "`$(CC) -E -dM $(src)/../../include/asm/byteorder.h | grep ' __LITTLE_ENDIAN '`"; then echo $(obj)/pca200e.bin; else echo $(obj)/pca200e_ecd.bin2; fi)
+    byteorder.h			:= include$(if $(patsubst $(srctree),,$(objtree)),2)/asm/byteorder.h
+    CONFIG_ATM_FORE200E_PCA_FW	:= $(obj)/pca200e$(if $(shell $(CC) -E -dM $(byteorder.h) | grep ' __LITTLE_ENDIAN '),.bin,_ecd.bin2)
   endif
 endif
 

(Note: Patch also attached because the inline version is certain to get line wrapped.)

Adjust ATM makefile to account for building outside of the source tree.

drivers/atm/Makefile +2 -1
diff -Npru linux-2.6.12-rc4.base/drivers/atm/Makefile linux-2.6.12-rc4/drivers/atm/Makefile
@@ -39,7 +39,8 @@ ifeq ($(CONFIG_ATM_FORE200E_PCA),y)
   fore_200e-objs		+= fore200e_pca_fw.o
   # guess the target endianess to choose the right PCA-200E firmware image
   ifeq ($(CONFIG_ATM_FORE200E_PCA_DEFAULT_FW),y)
-    CONFIG_ATM_FORE200E_PCA_FW = $(shell if test -n "`$(CC) -E -dM $(src)/../../include/asm/byteorder.h | grep ' __LITTLE_ENDIAN '`"; then echo $(obj)/pca200e.bin; else echo $(obj)/pca200e_ecd.bin2; fi)
+    byteorder.h			:= include$(if $(patsubst $(srctree),,$(objtree)),2)/asm/byteorder.h
+    CONFIG_ATM_FORE200E_PCA_FW	:= $(obj)/pca200e$(if $(shell $(CC) -E -dM $(byteorder.h) | grep ' __LITTLE_ENDIAN '),.bin,_ecd.bin2)
   endif
 endif
 
#1 lore raw
Quoted 4 lines · Jan Beulich

(Note: Patch also attached because the inline version is certain to get line wrapped.)

Adjust ATM makefile to account for building outside of the source tree.

Btw, if someone still has the hardware it would be really nice to convert the atm drivers to use the userspace firmware loader.

#2 lore raw
In reply to Jan Beulich

dave,

please apply to 2.6 head -- thanks!

[ATM]: fix ATM makefile for out-of-source-tree builds

---
commit 70ac1c1be822318a3b706d00397b2bf24ffe0a6e
tree fe56ec270cfb1155e9370731e49900172ec73de6
parent ff0d2f90fdc4b564d47a7c26b16de81a16cfa28e
author chas williams <chas@relax.(none)> Tue, 17 May 2005 14:39:55 -0400 committer chas williams <chas@relax.(none)> Tue, 17 May 2005 14:39:55 -0400

 atm/Makefile |    3 ++-
 1 files changed, 2 insertions(+), 1 deletion(-)
drivers/atm/Makefile (mode:100644) +2 -1
Index: drivers/atm/Makefile
===================================================================
@@ -39,7 +39,8 @@
   fore_200e-objs		+= fore200e_pca_fw.o
   # guess the target endianess to choose the right PCA-200E firmware image
   ifeq ($(CONFIG_ATM_FORE200E_PCA_DEFAULT_FW),y)
-    CONFIG_ATM_FORE200E_PCA_FW = $(shell if test -n "`$(CC) -E -dM $(src)/../../include/asm/byteorder.h | grep ' __LITTLE_ENDIAN '`"; then echo $(obj)/pca200e.bin; else echo $(obj)/pca200e_ecd.bin2; fi)
+    byteorder.h			:= include$(if $(patsubst $(srctree),,$(objtree)),2)/asm/byteorder.h
+    CONFIG_ATM_FORE200E_PCA_FW	:= $(obj)/pca200e$(if $(shell $(CC) -E -dM $(byteorder.h) | grep ' __LITTLE_ENDIAN '),.bin,_ecd.bin2)
   endif
 endif