Skip to content

Conversation

@multiplemonomials
Copy link
Collaborator

@multiplemonomials multiplemonomials commented Oct 27, 2025

Summary of changes

Found three small bugs in the PlatformIO build script:

  • The path to libmbed-os.a had hardcoded backslashes, breaking builds on non-Windows platforms (oops!)
  • The code that processed build flags from CMake was erroneously stripping away quotes, causing -include "Some Path" to be turned into -include Some Path, which then got processed into -include Some, and then Path. We can fix this by just leaving the quotes in place, allowing them to be passed through to Click.
  • Similarly, the code that generated the libmbed-os.a path was not quoting the path, causing a build failure if the path contained spaces (I didn't realize that SCons wasn't smart enough to do this automatically!)

Impact of changes

A few build errors with platformio will be fixed!

Migration actions required

Documentation

New doc page for platformio created here: https://mbed-ce.dev/getting-started/platformio-setup/


Pull request type

[X] Patch update (Bug fix / Target update / Docs update / Test update / Refactor)
[] Feature update (New feature / Functionality change / New API)
[] Major update (Breaking change E.g. Return code change / API behaviour change)

Test results

[] No Tests required for this change (E.g docs only update)
[] Covered by existing mbed-os tests (Greentea or Unittest)
[X] Tests / results supplied as part of this PR

Able to compile the project now when the build dir contains spaces

@multiplemonomials multiplemonomials merged commit fbfa2d0 into master Oct 28, 2025
51 checks passed
@multiplemonomials multiplemonomials deleted the dev/pio-bugfixes branch October 28, 2025 15:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants