Skip to content

Commit 00f204f

Browse files
committed
Ensure all exported paths use Posix style separators.
mbed_config.h is a file that is placed in your project root when you export. This allows the configuration to be used by your IDE. When this file already exists (due to a previous export), it changed the compiler include option on Windows from "-include mbed_config.h" to "-include .\mbed_config.h". The "\" character was interpreted as an escape character "\m" and broke the build. This converts all resource paths to use the Posix path separator "/" before writing project files to avoid this issue.
1 parent 1920212 commit 00f204f

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

tools/export/exporters.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ def __init__(self, target, export_dir, project_name, toolchain,
9292
self.toolchain = toolchain
9393
jinja_loader = FileSystemLoader(os.path.dirname(os.path.abspath(__file__)))
9494
self.jinja_environment = Environment(loader=jinja_loader)
95+
resources.win_to_unix()
9596
self.resources = resources
9697
self.generated_files = []
9798
self.static_files = (

0 commit comments

Comments
 (0)