core/tools/build

36 lines
598 B
Text
Raw Normal View History

2024-08-18 13:57:55 +02:00
#!/usr/bin/env python3
2024-08-21 15:07:09 +02:00
import sys as _sys
2024-08-18 13:57:55 +02:00
import os as _os
import argparse as _argparse
def main():
## args
argument_parser = _argparse.ArgumentParser()
argument_parser.add_argument(
"-o",
"--output-directory",
type = str,
2024-08-21 19:47:31 +02:00
default = "/tmp/arc",
2024-08-18 13:57:55 +02:00
metavar = "<output-directory>",
help = "output directory",
)
args = argument_parser.parse_args()
## exec
targets = []
targets.append("_default")
_os.system(
"make dir_build=%s --file=tools/makefile %s"
% (
args.output_directory,
" ".join(targets),
)
)
2024-08-21 15:07:09 +02:00
_sys.stdout.write("%s\n" % args.output_directory)
2024-08-18 13:57:55 +02:00
main()