# This Source Code Form is subject to the terms of the Mozilla Public License, # v. 2.0. If a copy of the MPL was not distributed with this file, You can # obtain one at https://mozilla.org/MPL/2.0/. # frozen_string_literal: true require 'open3' require 'rake/clean' require 'term/ansicolor' CLEAN.include 'build/boot' directory 'build/boot' desc 'Final stage' task default: ['build/boot/stage2b', 'build/boot/stage2b.s', 'boot/stage2.elna'] do |t| exe, previous_output, source = t.prerequisites cat_arguments = ['cat', source] compiler_arguments = [QEMU, '-L', SYSROOT, exe] diff_arguments = ['diff', '-Nur', '--text', previous_output, '-'] Open3.pipeline(cat_arguments, compiler_arguments, diff_arguments) end