From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.0 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 36D2EC0044C for ; Mon, 5 Nov 2018 17:29:21 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8B10820827 for ; Mon, 5 Nov 2018 17:29:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=nifty.com header.i=@nifty.com header.b="ZRfkjajb" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 8B10820827 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=socionext.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730073AbeKFCuB (ORCPT ); Mon, 5 Nov 2018 21:50:01 -0500 Received: from conssluserg-01.nifty.com ([210.131.2.80]:24512 "EHLO conssluserg-01.nifty.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729692AbeKFCuA (ORCPT ); Mon, 5 Nov 2018 21:50:00 -0500 Received: from mail-vk1-f172.google.com (mail-vk1-f172.google.com [209.85.221.172]) (authenticated) by conssluserg-01.nifty.com with ESMTP id wA5HSuKm031803; Tue, 6 Nov 2018 02:28:57 +0900 DKIM-Filter: OpenDKIM Filter v2.10.3 conssluserg-01.nifty.com wA5HSuKm031803 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nifty.com; s=dec2015msa; t=1541438937; bh=IYwV7hRb+zvP1QmrH2b7ksnh9KdD8BQuBnj+U7T28dk=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=ZRfkjajbiUuZNnyjfBneDjVTPW6jZwcAApVlb8+VuaI4B+CIXlW70u5nnmYvi+JtQ O5pKvaxFRwUqiOjgabZ5iiZQ5SEh8JgdJVwCMNgxuibDsv/Jh8fAkMFRKku1KJuBF6 INyBVYwUKzOWjgtZOxA+uFj9wRyvKSUMcpkrXUA2n5VoJnqFt0DewKKgkDY/5VJaoq g+MKJjE7lZXf9YR0unBBfK5zTRRcyPWMZIjqzoFz2FEczayhG+R3FKHvXBaKRGxJBV 7aP8s1ZjopQpyveMrrJl54Wn6SDbfstx5S3bTlghTJh0ijlu6gRvWhkcuL8A9+f7T7 2oaPt4IFadWFA== X-Nifty-SrcIP: [209.85.221.172] Received: by mail-vk1-f172.google.com with SMTP id v70so2196304vkv.7; Mon, 05 Nov 2018 09:28:57 -0800 (PST) X-Gm-Message-State: AGRZ1gJpUySwzE+v1MmqIn45EB5Yx/DAJAd/8s24x1DgOUU/0zWJb+O0 RMS70L4SuSINaio9Euv4KWph9Rl7Al5f9F1H7NQ= X-Google-Smtp-Source: AJdET5epT+bTC+jQEevuNHvErj1iHKg2rC39BkvwapWPl91CILSMIQj/+DEXh4umAZ5xmT24URGh+K5Ojp675oKBd4U= X-Received: by 2002:a1f:5e47:: with SMTP id s68mr2276736vkb.64.1541438936187; Mon, 05 Nov 2018 09:28:56 -0800 (PST) MIME-Version: 1.0 References: <20181026212034.5491-1-linux@rasmusvillemoes.dk> <20181027194725.GA30155@avx2> <408ef493-de1d-37bb-de66-69134c5a1aca@rasmusvillemoes.dk> In-Reply-To: <408ef493-de1d-37bb-de66-69134c5a1aca@rasmusvillemoes.dk> From: Masahiro Yamada Date: Tue, 6 Nov 2018 02:28:20 +0900 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] fs: proc: move linux_proc_banner to where it is used To: Rasmus Villemoes Cc: Alexey Dobriyan , Andrew Morton , Kees Cook , Linux Kernel Mailing List , Linux Kbuild mailing list Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Oct 30, 2018 at 5:18 PM Rasmus Villemoes wrote: > > On 2018-10-27 21:47, Alexey Dobriyan wrote: > > On Fri, Oct 26, 2018 at 11:20:34PM +0200, Rasmus Villemoes wrote: > >> +#include > > > >> +#define linux_proc_banner \ > >> + "%s version %s" \ > >> + " (" LINUX_COMPILE_BY "@" LINUX_COMPILE_HOST ")" \ > >> + " (" LINUX_COMPILER ") %s\n" > > > > Include doesn't work if compiling from scratch: > > Urgh, thanks. I assumed that all the include/generated/ stuff was always > generated by the prepare steps in the top Makefile. But the logic for > making compile.h is in init/Makefile. > > > rm -rf ../obj > > mkdir ../obj > > make O=../obj defconfig > > make O=../obj fs/proc/version.o > > > > CC fs/proc/version.o > > fs/proc/version.c:2:10: fatal error: generated/compile.h: No such file or directory > > The same happens in current mainline for arch/x86/boot/version.o: > > $ make arch/x86/boot/version.o > CALL scripts/checksyscalls.sh > DESCEND objtool > CC arch/x86/boot/version.o > arch/x86/boot/version.c:17:31: fatal error: generated/compile.h: No such > file or directory > > Cc kbuild: Wouldn't it be a little nicer creating generated/compile.h > along with the other files in generated/, so that everybody can rely on > them being there instead of having the logic for compile.h hidden away > in init/Makefile and listing it as an explicit dependency? Or is there > some reason compile.h is special? > > Rasmus > I think the basic idea is, the build version should not be incremented if you do incremental build without touching any source file. If you create/update first, you never know whether the .version should be incremented or not. -- Best Regards Masahiro Yamada