1
0
mirror of https://bitbucket.org/librepilot/librepilot.git synced 2024-11-29 07:24:13 +01:00
LibrePilot/flight/libraries/PyMite/vm/SConscript
2013-04-25 13:13:36 +03:00

27 lines
767 B
Python

import sys
Import("env", "vars")
SOURCES = Glob("*.c")
PMSTDLIB_SOURCES = ["../lib/list.py",
"../lib/dict.py",
"../lib/__bi.py",
"../lib/sys.py",
"../lib/string.py",]
if env["IPM"] == True:
PMSTDLIB_SOURCES.append("../lib/ipm.py")
img_sources = Command(["pmstdlib_img.c", "pmstdlib_nat.c"], [PMSTDLIB_SOURCES],
"%s src/tools/pmImgCreator.py -f src/platform/%s/pmfeatures.py -c -s " \
"-o src/vm/pmstdlib_img.c --native-file=src/vm/pmstdlib_nat.c $SOURCES" \
% (sys.executable, vars.args["PLATFORM"]))
if sys.platform != "win32":
env['ARFLAGS'] = "rcs"
lib = env.Library("pmvm_%s" % vars.args["PLATFORM"], SOURCES + img_sources)
env.Precious(lib)
Return("lib")