Fix incorrect info about build_type

This commit is contained in:
Ivan Kravets
2019-11-06 23:53:38 +02:00
parent 4b3f593df9
commit 2408c0a4c7

View File

@@ -114,10 +114,11 @@ def BuildProgram(env):
# process framework scripts
env.BuildFrameworks(env.get("PIOFRAMEWORK"))
if (
is_build_type_debug = (
set(["debug", "sizedata"]) & set(COMMAND_LINE_TARGETS)
or env.GetProjectOption("build_type") == "debug"
):
)
if is_build_type_debug:
env.ConfigureDebugFlags()
# remove specified flags
@@ -151,7 +152,7 @@ def BuildProgram(env):
)
)
print("Building in %s mode" % env.GetProjectOption("build_type"))
print("Building in %s mode" % ("debug" if is_build_type_debug else "release"))
return program