Re: We interrupt you regularly scheduled catfight for.. Linux 2.2.18pre13

From: Ben Collins (bcollins@debian.org)
Date: Sat Sep 30 2000 - 18:13:09 EST


> ----- snip -----
>
> --- Makefile~ Sun Oct 1 00:46:27 2000
> +++ Makefile Sun Oct 1 00:49:27 2000
> @@ -23,7 +23,7 @@
> AS =$(CROSS_COMPILE)as
> LD =$(CROSS_COMPILE)ld
> CC =$(shell if [ -n "$(CROSS_COMPILE)" ]; then echo $(CROSS_COMPILE)cc; else \
> - which gcc272 2>/dev/null || which kgcc 2>/dev/null || echo cc; fi) \
> + which gcc272 >/dev/null 2>/dev/null || which kgcc > /dev/null 2>/dev/null || echo cc; fi) \
> -D__KERNEL__ -I$(HPATH)
> #CC =$(CROSS_COMPILE)cc -D__KERNEL__ -I$(HPATH)
> CPP =$(CC) -E
> ----- snip -----

Isn't this completely broken? I mean, it wont detect the others at all. It
will leave CC="" if gcc272 or kgcc are there.

How about:

CC = $(shell if [ -n "$(CROSS_COMPILE)" ]; then echo $(CROSS_COMPILE)cc; else \
        if which gcc272 > /dev/null 2> /dev/null; then \
                which gcc272; \
        else \
                if which kgcc > /dev/null 2> /dev/null; then \
                        which kgcc; \
                else \
                        echo cc; \
                fi; \
        fi) -D__KERNEL__ -I$(HPATH)

(obscure as needed)

-- 
 -----------=======-=-======-=========-----------=====------------=-=------
/  Ben Collins  --  ...on that fantastic voyage...  --  Debian GNU/Linux   \
`  bcollins@debian.org  --  bcollins@openldap.org  --  bcollins@linux.com  '
 `---=========------=======-------------=-=-----=-===-======-------=--=---'
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Sep 30 2000 - 21:00:28 EST