1#!/bin/sh 2 3# Check for files with CRLF line terminators 4 5r=0 6for f in $fldigi_SOURCES $flarq_SOURCES $EXTRA_fldigi_SOURCES $EXTRA_DIST; do 7 base=$(echo $f | sed -n '/\.[cC][cCpPxX]\{1,\}/ { s!.*/\(.*\)\.[^.]*$!\1!p; }') 8 if test "x$base" != "x" && grep " 9" "${srcdir}/${f}" >/dev/null; then 10 echo "E: $f has CRLF line terminators" >&2 11 r=1 12 fi 13done 14 15if [ $r -eq 1 ]; then 16 echo "Please remove the CRs from the above file(s)." 2>&1 17 echo "You can use something like: sed -i 's/\r$//' FILE1 FILE2 ..." 2>&1 18fi 19 20exit $r 21