*** gnulib-tool.orig 2008-08-31 00:58:50.000000000 +0200 --- gnulib-tool 2008-08-31 00:36:48.000000000 +0200 *************** *** 1341,1349 **** esac; \ done | sed -e 's,^lib/,,'` # Remove $already_mentioned_files from $lib_files. echo "$lib_files" | LC_ALL=C sort -u > "$tmp"/lib-files extra_files=`for f in $already_mentioned_files; do echo $f; done \ ! | LC_ALL=C sort -u | LC_ALL=C join -v 2 - "$tmp"/lib-files` if test -n "$extra_files"; then echo "EXTRA_DIST +=" $extra_files echo --- 1341,1352 ---- esac; \ done | sed -e 's,^lib/,,'` # Remove $already_mentioned_files from $lib_files. + # The 'cat > /dev/null' command is there because 'join' sometimes closes + # stdin prematurely, otherwise leading to "write error: Broken pipe". echo "$lib_files" | LC_ALL=C sort -u > "$tmp"/lib-files extra_files=`for f in $already_mentioned_files; do echo $f; done \ ! | LC_ALL=C sort -u \ ! | { LC_ALL=C join -v 2 - "$tmp"/lib-files; cat > /dev/null; }` if test -n "$extra_files"; then echo "EXTRA_DIST +=" $extra_files echo *************** *** 1508,1515 **** done handledmodules=`for m in $handledmodules $inmodules_this_round; do echo $m; done | LC_ALL=C sort -u` # Remove $handledmodules from $inmodules. for m in $inmodules; do echo $m; done | LC_ALL=C sort -u > "$tmp"/queued-modules ! inmodules=`echo "$handledmodules" | LC_ALL=C join -v 2 - "$tmp"/queued-modules` done modules=`for m in $outmodules; do echo $m; done | LC_ALL=C sort -u` rm -f "$tmp"/queued-modules --- 1511,1521 ---- done handledmodules=`for m in $handledmodules $inmodules_this_round; do echo $m; done | LC_ALL=C sort -u` # Remove $handledmodules from $inmodules. + # The 'cat > /dev/null' command is there because 'join' sometimes closes + # stdin prematurely, otherwise leading to "write error: Broken pipe". for m in $inmodules; do echo $m; done | LC_ALL=C sort -u > "$tmp"/queued-modules ! inmodules=`echo "$handledmodules" \ ! | { LC_ALL=C join -v 2 - "$tmp"/queued-modules; cat > /dev/null; }` done modules=`for m in $outmodules; do echo $m; done | LC_ALL=C sort -u` rm -f "$tmp"/queued-modules *************** *** 2405,2412 **** echo "$main_modules" | sed -e 's/^/ /' fi # Determine tests-related module list. echo "$final_modules" | LC_ALL=C sort -u > "$tmp"/final-modules ! testsrelated_modules=`echo "$main_modules" | LC_ALL=C sort -u | LC_ALL=C join -v 2 - "$tmp"/final-modules` if test $verbose -ge 1; then echo "Tests-related module list:" echo "$testsrelated_modules" | sed -e 's/^/ /' --- 2411,2422 ---- echo "$main_modules" | sed -e 's/^/ /' fi # Determine tests-related module list. + # The 'cat > /dev/null' command is there because 'join' sometimes closes + # stdin prematurely, otherwise leading to "write error: Broken pipe". echo "$final_modules" | LC_ALL=C sort -u > "$tmp"/final-modules ! testsrelated_modules=`echo "$main_modules" \ ! | LC_ALL=C sort -u \ ! | { LC_ALL=C join -v 2 - "$tmp"/final-modules; cat > /dev/null; }` if test $verbose -ge 1; then echo "Tests-related module list:" echo "$testsrelated_modules" | sed -e 's/^/ /' *************** *** 3271,3281 **** fi if test -f "$destdir/$dir$ignore"; then if test -n "$dir_added" || test -n "$dir_removed"; then sed -e "s|^$anchor||" < "$destdir/$dir$ignore" | LC_ALL=C sort > "$tmp"/ignore echo "$dir_added" | sed -e '/^$/d' | LC_ALL=C sort -u \ ! | LC_ALL=C join -v 2 "$tmp"/ignore - > "$tmp"/ignore-added echo "$dir_removed" | sed -e '/^$/d' | LC_ALL=C sort -u \ ! | LC_ALL=C join -v 2 "$tmp"/ignore - > "$tmp"/ignore-removed if test -s "$tmp"/ignore-added || test -s "$tmp"/ignore-removed; then if $doit; then echo "Updating $destdir/$dir$ignore (backup in $destdir/$dir${ignore}~)" --- 3281,3295 ---- fi if test -f "$destdir/$dir$ignore"; then if test -n "$dir_added" || test -n "$dir_removed"; then + # The 'cat > /dev/null' commands are there because 'join' sometimes closes + # stdin prematurely, otherwise leading to "write error: Broken pipe". sed -e "s|^$anchor||" < "$destdir/$dir$ignore" | LC_ALL=C sort > "$tmp"/ignore echo "$dir_added" | sed -e '/^$/d' | LC_ALL=C sort -u \ ! | { LC_ALL=C join -v 2 "$tmp"/ignore -; cat > /dev/null; } \ ! > "$tmp"/ignore-added echo "$dir_removed" | sed -e '/^$/d' | LC_ALL=C sort -u \ ! | { LC_ALL=C join -v 2 "$tmp"/ignore -; cat > /dev/null; } \ ! > "$tmp"/ignore-removed if test -s "$tmp"/ignore-added || test -s "$tmp"/ignore-removed; then if $doit; then echo "Updating $destdir/$dir$ignore (backup in $destdir/$dir${ignore}~)"