mirror of
https://github.com/tianocore/edk2
synced 2026-08-27 00:23:19 -04:00
BaseTools/Tests: Fix clean target
SEP variable is only set if PYTHON_COMMAND is undefined but referred regardless. It breaks the clean target for the following scenario: . edksetup.sh # Sets PYTHON_COMMAND make -C BaseTools make -C BaseTools clean This change fixes the use case mentioned above by settings SEP for all build configurations. [ardb: Drop redundant assignment for Windows] Signed-off-by: Oleksandr Tymoshenko <ovt@google.com>
This commit is contained in:
parent
f5f4e9b764
commit
522b18190a
1 changed files with 8 additions and 4 deletions
|
|
@ -7,11 +7,17 @@
|
|||
|
||||
all: test
|
||||
|
||||
ifeq (Windows, $(findstring Windows,$(OS)))
|
||||
MAKEROOT := $(shell echo %CD%)
|
||||
SEP:=$(shell echo \)
|
||||
else
|
||||
MAKEROOT := .
|
||||
SEP:=/
|
||||
endif
|
||||
|
||||
ifndef PYTHON_COMMAND
|
||||
ifeq (Windows, $(findstring Windows,$(OS)))
|
||||
SHELL := cmd.exe
|
||||
MAKEROOT := $(shell echo %CD%)
|
||||
SEP:=$(shell echo \)
|
||||
#
|
||||
# Try using the Python Launcher for Windows to find an interperter.
|
||||
#
|
||||
|
|
@ -36,8 +42,6 @@ ifndef PYTHON_COMMAND
|
|||
endif
|
||||
undefine CHECK_PY
|
||||
else # UNIX
|
||||
MAKEROOT := .
|
||||
SEP:=/
|
||||
PYTHON_COMMAND := $(shell /usr/bin/env python3 -c "import sys; print(sys.executable)")
|
||||
ifdef (,$(wildcard $(PYTHON_COMMAND))) # Make sure the file exists
|
||||
PYTHON_COMMAND := $(shell /usr/bin/env python -c "import sys; print(sys.executable)")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue