Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Keep msvc build output in build/ directories #10133

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Dec 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion mpy-cross/mpy-cross.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
<PyBuildingMpyCross>True</PyBuildingMpyCross>
<PyBuildDir>$(MSBuildThisFileDirectory)build\</PyBuildDir>
<PyIncDirs>$(MSBuildThisFileDirectory)</PyIncDirs>
<PyTargetDir>$(MSBuildThisFileDirectory)</PyTargetDir>
<PyMsvcDir>$(MSBuildThisFileDirectory)..\ports\windows\msvc\</PyMsvcDir>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
Expand Down
2 changes: 1 addition & 1 deletion ports/windows/.appveyor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ after_test:
if ($LASTEXITCODE -ne 0) {
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) {
throw "$env:MSYSTEM build exited with code $LASTEXITCODE"
}
Expand Down
4 changes: 0 additions & 4 deletions ports/windows/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,6 @@
*.*sdf
*.suo
*.sln
*.exe
*.pdb
*.ilk
*.filters
/build/*
.vs/*
*.VC.*db
2 changes: 1 addition & 1 deletion ports/windows/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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
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 .

Expand Down
4 changes: 2 additions & 2 deletions ports/windows/msvc/paths.props
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@
|- standard [PyVariantDir]

Note that the micropython executable will be copied from PyOutDir
to PyWinDir after each build. -->
to PyTargetDir after each build. -->

<!-- Start from project root -->
<PyBaseDir>$([System.IO.Path]::GetFullPath(`$(MSBuildThisFileDirectory)..\..\..`))\</PyBaseDir>
<PyWinDir>$(PyBaseDir)ports\windows\</PyWinDir>
<PyBuildDir Condition="'$(PyBuildDir)' == ''">$(PyWinDir)$(PyBuild)\</PyBuildDir>
<PyVariantDir Condition="'$(PyVariantDir)' == ''">$(PyWinDir)variants\$(PyVariant)\</PyVariantDir>
<PyTargetDir Condition="'$(PyTargetDir)' == ''">$(PyWinDir)</PyTargetDir>
<PyTargetDir Condition="'$(PyTargetDir)' == ''">$(PyBuildDir)</PyTargetDir>

<!-- All include directories needed for uPy -->
<PyIncDirs>$(PyIncDirs);$(PyBaseDir);$(PyWinDir);$(PyBuildDir);$(PyWinDir)msvc;$(PyVariantDir)</PyIncDirs>
Expand Down
4 changes: 3 additions & 1 deletion tests/run-internalbench.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
# to the correct executable.
if os.name == "nt":
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:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython")
Expand Down
4 changes: 3 additions & 1 deletion tests/run-multitests.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,9 @@

if os.name == "nt":
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:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv(
Expand Down
4 changes: 3 additions & 1 deletion tests/run-perfbench.py
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,9 @@
# Paths for host executables
if os.name == "nt":
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:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython")
Expand Down
6 changes: 4 additions & 2 deletions tests/run-tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,11 @@ def base_path(*p):
# to the correct executable.
if os.name == "nt":
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
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:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv(
Expand Down
4 changes: 3 additions & 1 deletion tools/gen-cpydiff.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@
# to the correct executable.
if os.name == "nt":
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:
CPYTHON3 = os.getenv("MICROPY_CPYTHON3", "python3")
MICROPYTHON = os.getenv("MICROPY_MICROPYTHON", "../ports/unix/build-standard/micropython")
Expand Down