From ecb6ec4a0a6013e16104ae3d8f81d8b3b59bc33f Mon Sep 17 00:00:00 2001 From: Steve McIntyre Date: Thu, 9 Feb 2023 17:44:28 +0000 Subject: [PATCH] Tweak firmware-image build scripts Add more debug to generate_firmware_patterns when called with -v Make make-firmware-image more robust, I hope? --- tools/generate_firmware_patterns | 6 ++++++ tools/make-firmware-image | 8 ++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/tools/generate_firmware_patterns b/tools/generate_firmware_patterns index 2cd0e0e5..0adfe989 100755 --- a/tools/generate_firmware_patterns +++ b/tools/generate_firmware_patterns @@ -158,6 +158,9 @@ sub generate_patterns_for_firmware_sof_intel_workaround { } +print STDERR "Looking up patterns for package $pkgname\n" + if $verbose; + # Make sure the output directory exists: die "missing output directory $output_dir" if ! -d $output_dir; @@ -175,3 +178,6 @@ foreach my $components (@ARGV) { # Only apply the workaround when relevant: generate_patterns_for_firmware_sof_intel_workaround() if ! $done and $pkgname eq $SOF; + +print STDERR "Done with package $pkgname\n" + if $verbose; diff --git a/tools/make-firmware-image b/tools/make-firmware-image index 0c470840..4da728ba 100755 --- a/tools/make-firmware-image +++ b/tools/make-firmware-image @@ -62,8 +62,12 @@ $BASEDIR/tools/generate_firmware_task '*' --list-filenames-and-indices | sort -u # Mimic make_disc_trees.pl, except it only passes a single Components-.yml.gz while # we pass all of them. Differences are unlikely though, as interesting firmware packages # are "Architecture: all". - $BASEDIR/tools/generate_firmware_patterns --output-dir $FW_DEP11_DIR --package $PACKAGE $DEP11_DIR/Components-*.yml.gz - [ -f $FW_DEP11_DIR/$PACKAGE.patterns ] && printf $COMPONENT > $FW_DEP11_DIR/$PACKAGE.component + $BASEDIR/tools/generate_firmware_patterns \ + -v --output-dir $FW_DEP11_DIR \ + --package $PACKAGE $DEP11_DIR/Components-*.yml.gz + if [ -f $FW_DEP11_DIR/$PACKAGE.patterns ]; then + printf "%s\n" $COMPONENT > $FW_DEP11_DIR/$PACKAGE.component + fi done cd $TMPDIR/firmware