diff options
author | Francesco Colista <fcolista@alpinelinux.org> | 2019-05-28 10:38:05 +0000 |
---|---|---|
committer | Francesco Colista <fcolista@alpinelinux.org> | 2019-05-28 10:45:17 +0000 |
commit | 7f9789919af11d5fbb73e1e25596746dbfb3f159 (patch) | |
tree | ff413a62119a0a745afd538221afd164610ee2b5 /main/hylafaxplus/common-functions-busybox-awk.patch | |
parent | 61e4723a0317995acbe4262708693206e1906257 (diff) | |
download | aports-7f9789919af11d5fbb73e1e25596746dbfb3f159.tar.bz2 aports-7f9789919af11d5fbb73e1e25596746dbfb3f159.tar.xz |
main/hylafaxplus: moved from community.
This does not break anything on stable and I'm willing to maintain it for 2 years.
According with #10495 I backport this to v3.8 and v3.9 too
Diffstat (limited to 'main/hylafaxplus/common-functions-busybox-awk.patch')
-rw-r--r-- | main/hylafaxplus/common-functions-busybox-awk.patch | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/main/hylafaxplus/common-functions-busybox-awk.patch b/main/hylafaxplus/common-functions-busybox-awk.patch new file mode 100644 index 0000000000..b217b20b7f --- /dev/null +++ b/main/hylafaxplus/common-functions-busybox-awk.patch @@ -0,0 +1,42 @@ +diff --git a/util/common-functions.sh.in b/util/common-functions.sh.in +index 38049e3..54cfd6b 100644 +--- a/util/common-functions.sh.in ++++ b/util/common-functions.sh.in +@@ -40,7 +40,7 @@ setInfoSize() + DICTTIMETORECV DICTSIGNALRATE DICTDATAFORMAT DICTERRCORRECT \ + DICTCALLID1 DICTCALLID2 DICTCALLID3 DICTCALLID4 DICTCALLID \ + DICTCALLID6 DICTCALLID7 DICTRECEIVEDON DICTCOMMID; do +- THISLEN="`eval echo \\\""$"$ITEM\\\" | $AWK 'BEGIN {L=0} length>L {L=length} END {print L}' | $SED 's/ //g'`" ++ THISLEN=`eval 'echo ${#'$ITEM'}'` + if [ $THISLEN -gt $INFOSIZE ]; then INFOSIZE=$THISLEN; fi + done + } +@@ -57,7 +57,7 @@ setItemSize() + DICTCALLS DICTPAGES DICTATTEMPTS DICTDIRNUM DICTRECEIVER DICTQUALITY \ + DICTPAGEWIDTH DICTPAGELENGTH DICTDATAFORMAT DICTREMOTEEQUIPMENT \ + DICTREMOTESTATION DICTSIGNALRATE; do +- THISLEN="`eval echo \\\""$"$ITEM\\\" | $AWK 'BEGIN {L=0} length>L {L=length} END {print L}' | $SED 's/ //g'`" ++ THISLEN=`eval 'echo ${#'$ITEM'}'` + if [ $THISLEN -gt $ITEMSIZE ]; then ITEMSIZE=$THISLEN; fi + done + } +@@ -146,12 +146,12 @@ + } p("faxstatus", status); + next; + } +- /^[!]*post/ { p("files_"++nfiles, $4); p("filetype_"nfiles, "PostScript"); next; } +- /^[!]*tiff/ { p("files_"++nfiles, $4); p("filetype_"nfiles, "TIFF"); next; } +- /^[!]*pdf/ { p("files_"++nfiles, $4); p("filetype_"nfiles, "PDF"); next; } +- /^[!]*pcl/ { p("files_"++nfiles, $4); p("filetype_"nfiles, "PCL"); next; } +- /^page:/ { p("pins_"++npins, $4); next; } +- /^data:/ { p("files_"++nfiles, $4); next; } ++ /^[!]*post/ { ++nfiles; p("files_"nfiles, $4); p("filetype_"nfiles, "PostScript"); next; } ++ /^[!]*tiff/ { ++nfiles; p("files_"nfiles, $4); p("filetype_"nfiles, "TIFF"); next; } ++ /^[!]*pdf/ { ++nfiles; p("files_"nfiles, $4); p("filetype_"nfiles, "PDF"); next; } ++ /^[!]*pcl/ { ++nfiles; p("files_"nfiles, $4); p("filetype_"nfiles, "PCL"); next; } ++ /^page:/ { ++npins; p("pins_"npins, $4); next; } ++ /^data:/ { ++nfiles; p("files_"nfiles, $4); next; } + /^poll/ { p("poll", " -p"); next; } + # Only parse remaining valid lines and allows for colons to appear in the value part + /^[a-z]+:/ { str = $0; sub($1":", "", str); p($1, str); next; } + |