This commit is contained in:
Ciro Santilli 六四事件 法轮功
2020-11-20 00:00:00 +00:00
parent 367df352d3
commit 2abb994752
9 changed files with 163 additions and 22 deletions

View File

@@ -1,7 +1,5 @@
#!/usr/bin/env python3
import os
import common
from shell_helpers import LF
@@ -25,14 +23,14 @@ See: https://cirosantilli.com/linux-kernel-module-cheat#gem5-m5-executable
]
def build(self):
os.makedirs(self.env['gem5_m5_build_dir'], exist_ok=True)
self.sh.mkdir_p(self.env['gem5_m5_build_dir'])
# We must clean first or else the build outputs of one arch can conflict with the other.
# I should stop being lazy and go actually patch gem5 to support out of tree m5 build...
self.clean()
self.sh.run_cmd(
self._get_make_cmd(),
)
os.makedirs(self.env['out_rootfs_overlay_bin_dir'], exist_ok=True)
self.sh.mkdir_p(self.env['out_rootfs_overlay_bin_dir'])
self.sh.cp(
self.env['gem5_m5_source_dir_build'],
self.env['out_rootfs_overlay_bin_dir']
@@ -42,7 +40,6 @@ See: https://cirosantilli.com/linux-kernel-module-cheat#gem5-m5-executable
self.sh.run_cmd(
self._get_make_cmd() + ['--clean', LF],
)
return None
if __name__ == '__main__':
Main().cli()