From: Nishanth Aravamudan <nacc@us.ibm.com>
To: chas@cmf.nrl.navy.mil
Cc: linux-atm-general@lists.sourceforge.net,
LKML <linux-kernel@vger.kernel.org>
Subject: [PATCH] fix ATM build with O=
Date: Tue, 10 May 2005 14:27:21 -0700 [thread overview]
Message-ID: <20050510212721.GC2772@us.ibm.com> (raw)
Chas,
I noticed today, while trying to build with the O= make option (which
allows the objects to be in a different directory than the source), that
ATM throws a warning. Turns out there is an explicit dependency on where
include is. But, with O=, include only contains asm-offsets.s and
include2 contains the appropriate files.
Here is a first attempt at a fix... Ideally, I could just check
KBUILD_OUTPUT's value (which should be set with O= or the
environmental variable KBUILD_OUTPUT). But I couldn't get that to work
(can try again with some guidance, though). Instead, I just check if the
source and object trees are different -- which I think can only be the
case if you use O= or KBUILD_OUTPUT. I think the change from $(src) to
$(obj) is also correct...
Description: Fix the build process for ATM when the make command-line
option O= is used. The current code assumes the files will be availabled
in the src directory (not the case with O=) and that include is the
directory to look in (not the case with O=). I would prefer to use
KBUILD_OUTPUT, but was unable to get it working.
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
--- 2.6.12-rc4/drivers/atm/Makefile.orig 2005-05-10 14:24:35.000000000 -0700
+++ 2.6.12-rc4/drivers/atm/Makefile 2005-05-10 14:19:43.000000000 -0700
@@ -39,7 +39,11 @@ 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)
+ ifneq ($(srctree),$(objtree))
+ CONFIG_ATM_FORE200E_PCA_FW = $(shell if test -n "`$(CC) -E -dM $(obj)/../../include2/asm/byteorder.h | grep ' __LITTLE_ENDIAN '`"; then echo $(obj)/pca200e.bin; else echo $(obj)/pca200e_ecd.bin2; fi)
+ else
+ CONFIG_ATM_FORE200E_PCA_FW = $(shell if test -n "`$(CC) -E -dM $(obj)/../../include/asm/byteorder.h | grep ' __LITTLE_ENDIAN '`"; then echo $(obj)/pca200e.bin; else echo $(obj)/pca200e_ecd.bin2; fi)
+ endif
endif
endif
reply other threads:[~2005-05-10 21:30 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20050510212721.GC2772@us.ibm.com \
--to=nacc@us.ibm.com \
--cc=chas@cmf.nrl.navy.mil \
--cc=linux-atm-general@lists.sourceforge.net \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox