Re: [PATCH] get rid of the last symlink in uml build

From: Sam Ravnborg
Date: Wed Dec 17 2008 - 02:25:08 EST


On Wed, Dec 17, 2008 at 06:12:50AM +0000, Al Viro wrote:
> We need to make asm-offsets.h contents visible for objects built
> with userland headers. Instead of creating a symlink, just have the
> file with equivalent include (relative to location of header) created
> once.
>
> That kills the last symlink used in arch/um builds. Have fun...

great!
Soon we have no more symlinks generated for a kernel build.
um used to be the worst of all but you have fixed it all up now.

Minor comment below.

Thanks,
Sam
>
> Signed-off-by: Al Viro <viro@xxxxxxxxxxxxxxxxxx>
> ---
> diff --git a/arch/um/Makefile b/arch/um/Makefile
> index d944c34..3fd7e45 100644
> --- a/arch/um/Makefile
> +++ b/arch/um/Makefile
> @@ -22,10 +22,11 @@ MODE_INCLUDE += -I$(srctree)/$(ARCH_DIR)/include/shared/skas
>
> include $(srctree)/$(ARCH_DIR)/Makefile-skas
>
> -ARCH_INCLUDE := -I$(srctree)/$(ARCH_DIR)/include/shared
> +SHARED_HEADERS := $(ARCH_DIR)/include/shared
> +ARCH_INCLUDE := -I$(srctree)/$(SHARED_HEADERS)
> ARCH_INCLUDE += -I$(srctree)/$(ARCH_DIR)/sys-$(SUBARCH)/shared
> ifneq ($(KBUILD_SRC),)
> -ARCH_INCLUDE += -I$(ARCH_DIR)/include/shared # for two generated files
> +ARCH_INCLUDE += -I$(SHARED_HEADERS)
> endif
> KBUILD_CPPFLAGS += -I$(srctree)/$(ARCH_DIR)/sys-$(SUBARCH)
>
> @@ -85,8 +86,8 @@ endef
>
> KBUILD_KCONFIG := arch/um/Kconfig.$(HEADER_ARCH)
>
> -archprepare: $(ARCH_DIR)/include/shared/user_constants.h
> -prepare: $(ARCH_DIR)/include/shared/kern_constants.h
> +archprepare: $(SHARED_HEADERS)/user_constants.h
> +prepare: $(SHARED_HEADERS)/kern_constants.h

arch Makefiles should rely solely on the archprepare target.
That cleanup could come later as it is independent from
the purpose of this patch.

Sam
--
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/