wok-next diff syslinux/stuff/iso2exe/taziso @ rev 18145
Add defragfs
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Thu Jun 18 16:31:01 2015 +0200 (2015-06-18) |
parents | 678daaa78112 |
children | 0a22c10d35b2 |
line diff
1.1 --- a/syslinux/stuff/iso2exe/taziso Wed Jun 17 19:05:26 2015 +0200 1.2 +++ b/syslinux/stuff/iso2exe/taziso Thu Jun 18 16:31:01 2015 +0200 1.3 @@ -1057,6 +1057,17 @@ 1.4 parse_isolinux() 1.5 { 1.6 awk 'BEGIN { IGNORECASE=1 } 1.7 +function multi(n) 1.8 +{ 1.9 + auto=$n 1.10 + for (--n; n < NF; n+=2) { 1.11 + s=$n 1.12 + if (s ~ /M$/) s = substr(s,0,length(s)-1) 1.13 + else s /= 1024 1.14 + sizes=int(s) " " sizes 1.15 + } 1.16 + next 1.17 +} 1.18 { 1.19 if ($1 == "LABEL") { 1.20 label=$2 1.21 @@ -1066,13 +1077,10 @@ 1.22 if ($1 == "INITRD") initrd[label]=$2 1.23 if ($1 == "APPEND") { 1.24 i=2 1.25 - if (kernel[label] ~ "ifmem.c32") { 1.26 - auto=$3 1.27 - next 1.28 - } 1.29 + if (kernel[label] ~ "ifmem.c32") multi(3) 1.30 if (kernel[label] ~ "c32box.c32") { 1.31 if ($2 == "linux") { kernel[label]=$3; i=4 } 1.32 - if ($2 == "ifmem") { auto=$4; next } 1.33 + if ($2 == "ifmem") multi(4) 1.34 } 1.35 if (kernel[label] ~ "ifcpu64.c32") { auto=$4; next } 1.36 while (i <= NF) { 1.37 @@ -1086,6 +1094,7 @@ 1.38 print "KERNEL=\"" kernel[auto] "\"" 1.39 print "INITRD=\"" initrd[auto] "\"" 1.40 print "CMDLINE=\"" substr(cmdline[auto],2) "\"" 1.41 + print "SIZES=\"" sizes "\"" 1.42 }' 1.43 } 1.44