Skip to content

Commit

Permalink
Use SDK default build type
Browse files Browse the repository at this point in the history
This will default to Release, rather than the current Debug builds
  • Loading branch information
will-v-pi committed Aug 28, 2024
1 parent 385ad93 commit 63180cb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
8 changes: 4 additions & 4 deletions scripts/pico_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -1174,19 +1174,19 @@ def DoEverything(parent, params):
if isWindows:
if shutil.which("ninja") or (params["ninjaPath"] != None and params["ninjaPath"] != ""):
# When installing SDK version 1.5.0 on windows with installer pico-setup-windows-x64-standalone.exe, ninja is used
cmakeCmd = params['cmakePath'] + ' -DCMAKE_BUILD_TYPE=Debug -G Ninja ..'
cmakeCmd = params['cmakePath'] + ' -G Ninja ..'
makeCmd = params['ninjaPath'] + ' '
else:
# Everything else assume nmake
cmakeCmd = params['cmakePath'] + ' -DCMAKE_BUILD_TYPE=Debug -G "NMake Makefiles" ..'
cmakeCmd = params['cmakePath'] + ' -G "NMake Makefiles" ..'
makeCmd = 'nmake '
else:
# Ninja now works OK under Linux, so if installed use it by default. It's faster.
if shutil.which("ninja") or (params["ninjaPath"] != None and params["ninjaPath"] != ""):
cmakeCmd = params['cmakePath'] + ' -DCMAKE_BUILD_TYPE=Debug -G Ninja ..'
cmakeCmd = params['cmakePath'] + ' -G Ninja ..'
makeCmd = params['ninjaPath'] + ' '
else:
cmakeCmd = params['cmakePath'] + ' -DCMAKE_BUILD_TYPE=Debug ..'
cmakeCmd = params['cmakePath'] + ' ..'
makeCmd = 'make -j' + str(cpus)

os.system(cmakeCmd)
Expand Down
2 changes: 1 addition & 1 deletion src/utils/cmakeUtil.mts
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ export async function configureCmakeNinja(folder: Uri): Promise<boolean> {
const command =
`${
process.env.ComSpec === "powershell.exe" ? "&" : ""
}"${cmake}" -DCMAKE_BUILD_TYPE=Debug ${
}"${cmake}" ${
pythonPath.includes("/")
? `-DPython3_EXECUTABLE="${pythonPath.replaceAll("\\", "/")}" `
: ""
Expand Down

0 comments on commit 63180cb

Please sign in to comment.