Unverified Commit 40f4fdf2 authored by Maximilian Gerhardt's avatar Maximilian Gerhardt Committed by GitHub

Fix PlatformIO linking for variant-specific overrides (#696)

parent 67b3c8fc
......@@ -295,10 +295,11 @@ if variant != "":
os.path.join(FRAMEWORK_DIR, "variants", variant)
])
libs.append(
env.BuildLibrary(
os.path.join("$BUILD_DIR", "FrameworkArduinoVariant"),
os.path.join(FRAMEWORK_DIR, "variants", variant)))
# link variant's source files as object files into the binary.
# otherwise weak function overriding won't work in the linking stage.
env.BuildSources(
os.path.join("$BUILD_DIR", "FrameworkArduinoVariant"),
os.path.join(FRAMEWORK_DIR, "variants", variant))
libs.append(
env.BuildLibrary(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment