mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-13 20:12:26 +00:00
Rationale: previously we had archs on toplevel, e.g. out/x86_64 However, host tools like QEMU and gem5 can reuse a lot of the common build files across archs. Therefore, we save space and time by putting them into a single directory. Therefore, the toplevel out/x86_64 was inconsistent, better put arch inside guest tools that need separate build trees instead, e.g. out/buildroot/x86_64/ Also common was pretty obscure as a name to say the best.
22 lines
548 B
Python
Executable File
22 lines
548 B
Python
Executable File
#!/usr/bin/env python3
|
|
import common
|
|
parser = common.get_argparse(argparse_args={
|
|
'description': '''Print the value of a common.py variable.
|
|
|
|
This is useful to:
|
|
|
|
* give dry commands on the README that don't change when we refactor directory structure
|
|
* create simple bash scripts that call use common.py variables
|
|
|
|
For example, to get the Buildroot output directory for an ARM build, use:
|
|
|
|
....
|
|
./%(prog)s -a arm buildroot_build_dir
|
|
....
|
|
|
|
'''
|
|
})
|
|
parser.add_argument('variable')
|
|
args = common.setup(parser)
|
|
print(getattr(common, args.variable))
|