Re: using cc-option in arch/ppc64/boot/Makefile

From: Hollis Blanchard
Date: Mon Oct 18 2004 - 14:01:48 EST


On Sunday 17 October 2004 09:57, Sam Ravnborg wrote:
> Something like this should do the trick?
> You could also include everything in your Makefile but I prefer
> Makefile.lib to make it a bit more general.

That's what I had tried. I'm having strange problems though. This patch:

--- 1.25/arch/ppc64/boot/Makefile Sun Oct 3 12:23:50 2004
+++ edited/arch/ppc64/boot/Makefile Mon Oct 18 14:03:40 2004
@@ -20,6 +20,8 @@
# CROSS32_COMPILE is setup as a prefix just like CROSS_COMPILE
# in the toplevel makefile.

+include scripts/Makefile.lib
+
CROSS32_COMPILE ?=
#CROSS32_COMPILE = /usr/local/ppc/bin/powerpc-linux-

@@ -72,7 +74,12 @@
quiet_cmd_stripvm = STRIP $@
cmd_stripvm = $(STRIP) -s $< -o $@

+HAS_BIARCH := $(call cc-option-yn, -lalala)
+
vmlinux.strip: vmlinux FORCE
+ echo $(cc-option-yn)
+ echo $(HAS_BIARCH)
+ $(call cc-option-yn, -m64)
$(call if_changed,stripvm)
$(obj)/vmlinux.initrd: vmlinux.strip $(obj)/addRamDisk
$(obj)/ramdisk.image.gz FORCE
$(call if_changed,ramdisk)

... yields the following output:

make -f scripts/Makefile.build obj=arch/ppc64/boot arch/ppc64/boot/zImage
echo y
y
echo y
y
y
make[1]: y: Command not found

Also confusing: the gcc switch "-lalala" is invalid, so I don't know where
*any* y's came from. User error?

--
Hollis Blanchard
IBM Linux Technology Center
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/