Browse Source

No extra build folder for st/jlink upload (#21341)

Victor Oliveira 3 years ago
parent
commit
da84b59ee4
No account linked to committer's email address
1 changed files with 2 additions and 3 deletions
  1. 2
    3
      buildroot/share/PlatformIO/scripts/common-cxxflags.py

+ 2
- 3
buildroot/share/PlatformIO/scripts/common-cxxflags.py View File

@@ -22,10 +22,9 @@ def add_cpu_freq():
22 22
 #
23 23
 # It will separe release and debug build folders.
24 24
 # It useful when we need keep two live versions: one debug, for debugging,
25
-# other release, for flashing.
25
+# other release, for flashing (when upload is not done automatically by jlink/stlink).
26 26
 # Without this, PIO will recompile everything twice for any small change.
27
-#
28
-if env.GetBuildType() == "debug":
27
+if env.GetBuildType() == "debug" and env.get('UPLOAD_PROTOCOL') not in ['jlink', 'stlink']:
29 28
 	env['BUILD_DIR'] = '$PROJECT_BUILD_DIR/$PIOENV/debug'
30 29
 
31 30
 # On some platform, F_CPU is a runtime variable. Since it's used to convert from ns

Loading…
Cancel
Save