[PATCH] translate dashes in filenames for headers install

The current filename->define translation does not scrub dashes so when
creating stub defines for like asm-x86_64/ptrace-abi.h, we get: #define
__ASM_STUB_PTRACE-ABI_H

gcc just hates that sort of thing :)

trivial attached patch adds - to the tr list to scrub it to _

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Cc: David Woodhouse <dwmw2@infradead.org>
Cc: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
Mike Frysinger 2007-01-30 14:35:55 -08:00 committed by Linus Torvalds
parent 0d59a01bc4
commit ec268be36e
1 changed files with 1 additions and 1 deletions

View File

@ -109,7 +109,7 @@ quiet_cmd_mkdir = MKDIR $(patsubst $(INSTALL_HDR_PATH)/%,%,$@)
quiet_cmd_gen = GEN $(patsubst $(INSTALL_HDR_PATH)/%,%,$@)
cmd_gen = \
FNAME=$(patsubst $(INSTALL_HDR_PATH)/$(_dst)/%,%,$@) \
STUBDEF=__ASM_STUB_`echo $$FNAME | tr a-z. A-Z_`; \
STUBDEF=__ASM_STUB_`echo $$FNAME | tr a-z.- A-Z__`; \
(echo "/* File autogenerated by 'make headers_install' */" ; \
echo "\#ifndef $$STUBDEF" ; \
echo "\#define $$STUBDEF" ; \