Skip to content

Commit 28e89e4

Browse files
author
Joakim Gebart
committed
Makefile.docker: Pass TOOLCHAIN variable to Docker container
1 parent da74abc commit 28e89e4

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

Makefile.docker

+4-3
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,7 @@ export DOCKER_ENV_VARS = \
5151
UNDEF \
5252
BUILDTEST_MCU_GROUP \
5353
BUILDTEST_VERBOSE \
54+
TOOLCHAIN \
5455
#
5556

5657
# Find which variables were set using the command line or the environment and
@@ -59,9 +60,9 @@ export DOCKER_ENV_VARS = \
5960
# of the environment variables will be overwritten by Makefile.include and their
6061
# origin is changed to "file"
6162
DOCKER_ENVIRONMENT_CMDLINE := $(foreach varname,$(DOCKER_ENV_VARS), \
62-
$(if $(filter environment command,$(origin $(varname))), \
63-
-e '$(varname)=$($(varname))', \
64-
))
63+
$(if $(filter environment command,$(origin $(varname))), \
64+
-e '$(varname)=$(subst ','\'',$($(varname)))', \
65+
))
6566
DOCKER_ENVIRONMENT_CMDLINE := $(strip $(DOCKER_ENVIRONMENT_CMDLINE))
6667

6768
# This will execute `make $(DOCKER_MAKECMDGOALS)` inside a Docker container.

0 commit comments

Comments
 (0)