wok-current diff syslinux/stuff/iso2exe/taziso @ rev 24164

linld: fix vcpi case
author Pascal Bellard <pascal.bellard@slitaz.org>
date Sun Dec 26 17:19:46 2021 +0000 (2021-12-26)
parents 8eaf1d9eb640
children 27c664d6b7a3
line diff
     1.1 --- a/syslinux/stuff/iso2exe/taziso	Tue Nov 09 17:05:26 2021 +0000
     1.2 +++ b/syslinux/stuff/iso2exe/taziso	Sun Dec 26 17:19:46 2021 +0000
     1.3 @@ -895,7 +895,9 @@
     1.4  
     1.5  xfile()
     1.6  {
     1.7 -	[ "$(which $1)" ] && menuitem "$@"
     1.8 +	for i in $1; do
     1.9 +		[ "$(which $i)" ] && menuitem "$@" && break
    1.10 +	done
    1.11  }
    1.12  
    1.13  initxfile()
    1.14 @@ -1547,8 +1549,8 @@
    1.15  
    1.16  infoiso()
    1.17  {
    1.18 -	isoinfo -d -i "$ISO" > /tmp/isoinfo$$
    1.19 -	if [ -x "$(which iso2exe)" ]; then
    1.20 +	isoinfo -d -i "$ISO" > /tmp/isoinfo$$ 2> /dev/null
    1.21 +	if [ "$(which iso2exe)" ]; then
    1.22  		echo "----"
    1.23  		blkid "$ISO" | while read args; do
    1.24  			set -- $args
    1.25 @@ -1571,6 +1573,16 @@
    1.26  	else
    1.27  		$DIALOG --clear --title " Info ISO " \
    1.28  			--textbox /tmp/isoinfo$$ 0 0
    1.29 +		files=$(sed '/^custom.*d/!d;s| .*||' /tmp/isoinfo$$)
    1.30 +		if [ "$files" ]; then
    1.31 +			$DIALOG --clear --title " Extract custom files " \
    1.32 +				--defaultno --yesno \
    1.33 +				"Do you want to extract the custom boot files ?\n$files" 7 70
    1.34 +			[ $? -eq 0 ] && for i in $files ; do
    1.35 +				echo "Extract $i ..."
    1.36 +				iso2exe -l "$ISO" $i
    1.37 +			done
    1.38 +		fi
    1.39  	fi
    1.40  	rm -f /tmp/isoinfo$$
    1.41  }
    1.42 @@ -1648,7 +1660,7 @@
    1.43  $(cdfile 'md5sum*'	"md5"		"Check the ISO files") \
    1.44  $(cdfile 'sha*sum*'	"sha"		"Check the ISO files") \
    1.45  $(menuitem		"filepos"	"File start sector") \
    1.46 -$(xfile isoinfo		"infoiso"	"ISO image info") \
    1.47 +$(xfile 'isoinfo iso2exe'	"infoiso"	"ISO image info") \
    1.48  $(cdfilex 'bzImage*'	"bootiso"	"Boot the ISO image") \
    1.49  $(burnable		"burniso"	"Burn the ISO image") \
    1.50  $(blankable		"blankcd"	"Blank the CD/DVD") \