mirror of
https://github.com/cirosantilli/linux-kernel-module-cheat.git
synced 2026-01-23 02:05:57 +01:00
build: make baremetal parts more flexible and powerful
Document test-gdb on readme
This commit is contained in:
@@ -41,6 +41,7 @@ include_src_dir = os.path.join(this_module.root_dir, this_module.include_subdir)
|
||||
submodules_dir = os.path.join(root_dir, 'submodules')
|
||||
buildroot_src_dir = os.path.join(submodules_dir, 'buildroot')
|
||||
crosstool_ng_src_dir = os.path.join(submodules_dir, 'crosstool-ng')
|
||||
crosstool_ng_supported_archs = set(['arm', 'aarch64'])
|
||||
linux_src_dir = os.path.join(submodules_dir, 'linux')
|
||||
linux_config_dir = os.path.join(this_module.root_dir, 'linux_config')
|
||||
rootfs_overlay_dir = os.path.join(this_module.root_dir, 'rootfs_overlay')
|
||||
@@ -169,6 +170,10 @@ def add_newlines(cmd):
|
||||
out.extend([arg, this_module.Newline])
|
||||
return out
|
||||
|
||||
def assert_crosstool_ng_supports_arch(arch):
|
||||
if arch not in this_module.crosstool_ng_supported_archs:
|
||||
raise Exception('arch not yet supported: ' + arch)
|
||||
|
||||
def base64_encode(string):
|
||||
return base64.b64encode(string.encode()).decode()
|
||||
|
||||
@@ -555,10 +560,6 @@ def raw_to_qcow2(prebuilt=False, reverse=False):
|
||||
outfile, this_module.Newline,
|
||||
])
|
||||
|
||||
def raise_no_x86(arch):
|
||||
if (arch == 'x86_64'):
|
||||
raise Exception('x86_64 not yet supported')
|
||||
|
||||
def resolve_args(defaults, args, extra_args):
|
||||
if extra_args is None:
|
||||
extra_args = {}
|
||||
|
||||
Reference in New Issue
Block a user