diff --git a/rootfs.py b/rootfs.py index c31d5a1..6f4faf0 100755 --- a/rootfs.py +++ b/rootfs.py @@ -28,6 +28,8 @@ def create_configuration_file(args): """ config_path = os.path.join('steps', 'bootstrap.cfg') with open(config_path, "w", encoding="utf_8") as config: + config.write(f"ARCH={args.arch}\n") + config.write(f"ARCH_DIR={stage0_arch_map.get(args.arch, args.arch)}\n") config.write(f"FORCE_TIMESTAMPS={args.force_timestamps}\n") config.write(f"CHROOT={args.chroot or args.bwrap}\n") config.write(f"UPDATE_CHECKSUMS={args.update_checksums}\n") diff --git a/steps/improve/clean_artifacts.sh b/steps/improve/clean_artifacts.sh new file mode 100644 index 0000000..326d835 --- /dev/null +++ b/steps/improve/clean_artifacts.sh @@ -0,0 +1,13 @@ +# SPDX-FileCopyrightText: 2024 Gábor Stefanik +# +# SPDX-License-Identifier: GPL-3.0-or-later + +# Delete build artifacts to free up space for Linux kernel build + +for pkg in $(ls "${SRCDIR}"); do + if [ -d "${SRCDIR}/${pkg}/build" ]; then + rm -rf "${SRCDIR}/${pkg}/build" + fi +done + +rm -rf "/${ARCH_DIR}/artifact" diff --git a/steps/manifest b/steps/manifest index c5ca560..f103c39 100644 --- a/steps/manifest +++ b/steps/manifest @@ -123,6 +123,7 @@ define: BUILD_LINUX = ( CHROOT == False || BUILD_KERNELS == True ) build: kexec-linux-1.0.0 ( BUILD_LINUX == True ) build: kexec-tools-2.0.22 ( BUILD_LINUX == True ) improve: clean_sources +improve: clean_artifacts build: linux-4.9.10 ( BUILD_LINUX == True ) jump: break ( INTERNAL_CI == pass1 ) improve: populate_device_nodes