All of lore.kernel.org
 help / color / mirror / Atom feed
From: Masahiro Yamada <masahiroy@kernel.org>
To: Elliott Mitchell <ehem+linux@m5p.com>
Cc: nathan@kernel.org, nicolas@fjasle.eu, linux-kbuild@vger.kernel.org
Subject: Re: [PATCH RFC 0/3] Adding trailing slash to $(srctree)
Date: Thu, 22 Feb 2024 13:38:36 +0900	[thread overview]
Message-ID: <CAK7LNARcv=iYRb_Qoq=tB3avbjQLpye9bCeqjmJUn6OyP6bZkg@mail.gmail.com> (raw)
In-Reply-To: <cover.1708478591.git.ehem+linux@m5p.com>

On Thu, Feb 22, 2024 at 8:16 AM Elliott Mitchell <ehem+linux@m5p.com> wrote:
>
> The subject states exactly what I'm suggesting.
>
> The reason is the fallback value for $(srctree) of "." doesn't work
> properly in several places under some conditions.  In particular in
> several places a pattern of "$(srctree)/$(src)" is used.  If $(srctree)
> ends up with the value "." and $(src) ends up with the value `pwd`, the
> build breaks.  This can be triggered via in-tree/out-of-tree build
> mechanisms.


I really do not understand what you are trying to achieve,
but this is just about
"Do not try to build upstream drivers with M=".


If you hack it, it is what you should do locally.









> As such, assuming $(srctree) includes the trailing slash and setting
> the fallback for $(srctree) to "" fixes things.  This is untested, I'm
> proposing this since I wanted to use a build approach which triggers
> this.  This is really a single patch, but it has been split into 3 to
> emphasize where the real work is done.
>
> I'm suspicious of the fallback settings of $(srctree) found in several
> Makefiles.  This might be a distinct workaround for the same situation.
> I was wondering about adjusting some of those comments too.  I think
> $(src) needs similar treatment, but that is rather messier.
>
> Note, this is basically untested.  I'm hopeful this actually works, but
> if it breaks then this was mostly to alert the maintainers of this
> troublesome condition.
>
>
> Elliott Mitchell (3):
>   build: add trailing slash to $(srctree)
>   build: modify uses of $(srctree) to assume trailing slash
>   build: change $(srctree) to empty for current directory
>

--
Best Regards
Masahiro Yamada

  parent reply	other threads:[~2024-02-22  4:39 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-02-21  1:23 [PATCH RFC 0/3] Adding trailing slash to $(srctree) Elliott Mitchell
2024-02-20 17:13 ` [PATCH RFC 3/3] build: change $(srctree) to empty for current directory Elliott Mitchell
2024-02-20 17:13 ` [PATCH RFC 1/3] build: add trailing slash to $(srctree) Elliott Mitchell
2024-02-20 17:13 ` [PATCH RFC 2/3] build: modify uses of $(srctree) to assume trailing slash Elliott Mitchell
2024-02-22  4:38 ` Masahiro Yamada [this message]
2024-02-22 16:11   ` [PATCH RFC 0/3] Adding trailing slash to $(srctree) Elliott Mitchell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAK7LNARcv=iYRb_Qoq=tB3avbjQLpye9bCeqjmJUn6OyP6bZkg@mail.gmail.com' \
    --to=masahiroy@kernel.org \
    --cc=ehem+linux@m5p.com \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=nathan@kernel.org \
    --cc=nicolas@fjasle.eu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.