all: Keep msvc build output in build/ directories.

This follow the change made for Makefile-based projects in b2e82402.
pull/10133/head
stijn 2022-11-29 16:58:21 +01:00 zatwierdzone przez Damien George
rodzic db19ee7e15
commit 9c7ff87643
9 zmienionych plików z 20 dodań i 11 usunięć

Wyświetl plik

@ -24,7 +24,6 @@
<PyBuildingMpyCross>True</PyBuildingMpyCross> <PyBuildingMpyCross>True</PyBuildingMpyCross>
<PyBuildDir>$(MSBuildThisFileDirectory)build\</PyBuildDir> <PyBuildDir>$(MSBuildThisFileDirectory)build\</PyBuildDir>
<PyIncDirs>$(MSBuildThisFileDirectory)</PyIncDirs> <PyIncDirs>$(MSBuildThisFileDirectory)</PyIncDirs>
<PyTargetDir>$(MSBuildThisFileDirectory)</PyTargetDir>
<PyMsvcDir>$(MSBuildThisFileDirectory)..\ports\windows\msvc\</PyMsvcDir> <PyMsvcDir>$(MSBuildThisFileDirectory)..\ports\windows\msvc\</PyMsvcDir>
</PropertyGroup> </PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />

Wyświetl plik

@ -78,7 +78,7 @@ after_test:
if ($LASTEXITCODE -ne 0) { if ($LASTEXITCODE -ne 0) {
throw "$env:MSYSTEM build exited with code $LASTEXITCODE" throw "$env:MSYSTEM build exited with code $LASTEXITCODE"
} }
C:\msys64\usr\bin\bash.exe -l -c "make -B -j4 V=1 MICROPY_MPYCROSS=../../mpy-cross/mpy-cross.exe VARIANT=$($env:PyVariant)" C:\msys64\usr\bin\bash.exe -l -c "make -B -j4 V=1 MICROPY_MPYCROSS=../../mpy-cross/build/mpy-cross.exe VARIANT=$($env:PyVariant)"
if ($LASTEXITCODE -ne 0) { if ($LASTEXITCODE -ne 0) {
throw "$env:MSYSTEM build exited with code $LASTEXITCODE" throw "$env:MSYSTEM build exited with code $LASTEXITCODE"
} }

Wyświetl plik

@ -128,7 +128,7 @@ functions and thus should be ran using the `wineconsole` tool. Depending
on the Wine build configuration, you may also want to select the curses on the Wine build configuration, you may also want to select the curses
backend which has the look&feel of a standard Unix console: backend which has the look&feel of a standard Unix console:
wineconsole --backend=curses ./micropython.exe wineconsole --backend=curses ./build-standard/micropython.exe
For more info, see https://www.winehq.org/docs/wineusr-guide/cui-programs . For more info, see https://www.winehq.org/docs/wineusr-guide/cui-programs .

Wyświetl plik

@ -22,14 +22,14 @@
|- standard [PyVariantDir] |- standard [PyVariantDir]
Note that the micropython executable will be copied from PyOutDir Note that the micropython executable will be copied from PyOutDir
to PyWinDir after each build. --> to PyTargetDir after each build. -->
<!-- Start from project root --> <!-- Start from project root -->
<PyBaseDir>$([System.IO.Path]::GetFullPath(`$(MSBuildThisFileDirectory)..\..\..`))\</PyBaseDir> <PyBaseDir>$([System.IO.Path]::GetFullPath(`$(MSBuildThisFileDirectory)..\..\..`))\</PyBaseDir>
<PyWinDir>$(PyBaseDir)ports\windows\</PyWinDir> <PyWinDir>$(PyBaseDir)ports\windows\</PyWinDir>
<PyBuildDir Condition="'$(PyBuildDir)' == ''">$(PyWinDir)$(PyBuild)\</PyBuildDir> <PyBuildDir Condition="'$(PyBuildDir)' == ''">$(PyWinDir)$(PyBuild)\</PyBuildDir>
<PyVariantDir Condition="'$(PyVariantDir)' == ''">$(PyWinDir)variants\$(PyVariant)\</PyVariantDir> <PyVariantDir Condition="'$(PyVariantDir)' == ''">$(PyWinDir)variants\$(PyVariant)\</PyVariantDir>
<PyTargetDir Condition="'$(PyTargetDir)' == ''">$(PyWinDir)</PyTargetDir> <PyTargetDir Condition="'$(PyTargetDir)' == ''">$(PyBuildDir)</PyTargetDir>
<!-- All include directories needed for uPy --> <!-- All include directories needed for uPy -->
<PyIncDirs>$(PyIncDirs);$(PyBaseDir);$(PyWinDir);$(PyBuildDir);$(PyWinDir)msvc;$(PyVariantDir)</PyIncDirs> <PyIncDirs>$(PyIncDirs);$(PyBaseDir);$(PyWinDir);$(PyBuildDir);$(PyWinDir)msvc;$(PyVariantDir)</PyIncDirs>

Wyświetl plik

@ -13,7 +13,9 @@ from collections import defaultdict
# to the correct executable. # to the correct executable.
if os.name == "nt": if os.name == "nt":
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/windows/micropython.exe") MICROPYTHON = os.getenv(
"MICROPY_MICROPYTHON", "../ports/windows/build-standard/micropython.exe"
)
else: else:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython") MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython")

Wyświetl plik

@ -27,7 +27,9 @@ import pyboard
if os.name == "nt": if os.name == "nt":
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", test_dir + "/../ports/windows/micropython.exe") MICROPYTHON = os.getenv(
"MICROPY_MICROPYTHON", test_dir + "/../ports/windows/build-standard/micropython.exe"
)
else: else:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv( MICROPYTHON = os.getenv(

Wyświetl plik

@ -18,7 +18,9 @@ prepare_script_for_target = __import__("run-tests").prepare_script_for_target
# Paths for host executables # Paths for host executables
if os.name == "nt": if os.name == "nt":
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/windows/micropython.exe") MICROPYTHON = os.getenv(
"MICROPY_MICROPYTHON", "../ports/windows/build-standard/micropython.exe"
)
else: else:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython") MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython")

Wyświetl plik

@ -30,9 +30,11 @@ def base_path(*p):
# to the correct executable. # to the correct executable.
if os.name == "nt": if os.name == "nt":
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", base_path("../ports/windows/micropython.exe")) MICROPYTHON = os.getenv(
"MICROPY_MICROPYTHON", base_path("../ports/windows/build-standard/micropython.exe")
)
# mpy-cross is only needed if --via-mpy command-line arg is passed # mpy-cross is only needed if --via-mpy command-line arg is passed
MPYCROSS = os.getenv("MICROPY_MPYCROSS", base_path("../mpy-cross/mpy-cross.exe")) MPYCROSS = os.getenv("MICROPY_MPYCROSS", base_path("../mpy-cross/build/mpy-cross.exe"))
else: else:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv( MICROPYTHON = os.getenv(

Wyświetl plik

@ -38,7 +38,9 @@ from collections import namedtuple
# to the correct executable. # to the correct executable.
if os.name == "nt": if os.name == "nt":
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3.exe")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/windows/micropython.exe") MICROPYTHON = os.getenv(
"MICROPY_MICROPYTHON", "../ports/windows/build-standard/micropython.exe"
)
else: else:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3") CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython") MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython")