Pass PlatformIO macros with version to libs

This commit is contained in:
Ivan Kravets
2016-06-13 19:46:54 +03:00
parent f75a7c91eb
commit 768ac77ea2

View File

@ -35,6 +35,11 @@ SRC_DEFAULT_FILTER = " ".join([
def BuildProgram(env): def BuildProgram(env):
env.Append(
CPPDEFINES=["PLATFORMIO={0:02d}{1:02d}{2:02d}".format(
*pioversion_to_intstr())],
)
# fix ASM handling under non-casitive OS # fix ASM handling under non-casitive OS
if not case_sensitive_suffixes(".s", ".S"): if not case_sensitive_suffixes(".s", ".S"):
env.Replace( env.Replace(
@ -78,8 +83,6 @@ def BuildProgram(env):
env.ProcessFlags([env.get("SRC_BUILD_FLAGS", None)]) env.ProcessFlags([env.get("SRC_BUILD_FLAGS", None)])
env.Append( env.Append(
CPPDEFINES=["PLATFORMIO={0:02d}{1:02d}{2:02d}".format(
*pioversion_to_intstr())],
CPPPATH=["$PROJECTSRC_DIR"], CPPPATH=["$PROJECTSRC_DIR"],
LIBS=deplibs, LIBS=deplibs,
LIBPATH=["$BUILD_DIR"] LIBPATH=["$BUILD_DIR"]