Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Yann E. MORIN" <yann.morin.1998@free.fr>
To: Peter Korsgaard <peter@korsgaard.com>
Cc: buildroot@buildroot.org
Subject: Re: [Buildroot] [PATCH] package/environment-setup: do not export GIT_DIR
Date: Sat, 27 Jan 2024 21:09:10 +0100	[thread overview]
Message-ID: <ZbVi5sy69XqopvaT@landeda> (raw)
In-Reply-To: <20240126093441.2130693-1-peter@korsgaard.com>

Peter, All,

On 2024-01-26 10:34 +0100, Peter Korsgaard spake thusly:
> Commit c07aafa08792 (package/Makefile.in: set GIT_DIR=.  in {HOST,
> TARGET}_MAKE_ENV) added GIT_DIR=.  to TARGET_MAKE_ENV (which is included in
> TARGET_CONFIGURE_OPTS) to work around issues with packages getting confused
> when building in a subdir of the Buildroot git repo.
> 
> This unfortunately also causes git commands to fail when
> output/host/environment-setup is sourced:
> 
> git status
> fatal: not a git repository: '.'
> 
> So strip GIT_DIR= from TARGET_CONFIGURE_OPTS when generating
> environment-setup.
> 
> Reported-by: Mircea Gliga <gliga.mircea@gmail.com>
> Signed-off-by: Peter Korsgaard <peter@korsgaard.com>

Applied to master, thanks.

Regards,
Yann E. MORIN.

> ---
>  package/environment-setup/environment-setup.mk | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/package/environment-setup/environment-setup.mk b/package/environment-setup/environment-setup.mk
> index 29ec5a9a95..069ee25f9f 100644
> --- a/package/environment-setup/environment-setup.mk
> +++ b/package/environment-setup/environment-setup.mk
> @@ -8,7 +8,7 @@ ENVIRONMENT_SETUP_FILE = $(HOST_DIR)/environment-setup
>  
>  define HOST_ENVIRONMENT_SETUP_INSTALL_CMDS
>  	cp package/environment-setup/environment-setup $(ENVIRONMENT_SETUP_FILE)
> -	for var in $(TARGET_CONFIGURE_OPTS); do \
> +	for var in $(filter-out GIT_DIR=%,$(TARGET_CONFIGURE_OPTS)); do \
>  		printf "export \"$$var\"\n" >> $(ENVIRONMENT_SETUP_FILE); \
>  	done
>  	printf "export \"ARCH=$(NORMALIZED_ARCH)\"\n" >> $(ENVIRONMENT_SETUP_FILE)
> -- 
> 2.39.2
> 
> _______________________________________________
> buildroot mailing list
> buildroot@buildroot.org
> https://lists.buildroot.org/mailman/listinfo/buildroot

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 561 099 427 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

      reply	other threads:[~2024-01-27 20:09 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-26  9:34 [Buildroot] [PATCH] package/environment-setup: do not export GIT_DIR Peter Korsgaard
2024-01-27 20:09 ` Yann E. MORIN [this message]

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=ZbVi5sy69XqopvaT@landeda \
    --to=yann.morin.1998@free.fr \
    --cc=buildroot@buildroot.org \
    --cc=peter@korsgaard.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox