Current Path : /usr/src/tools/tools/mid/ |
FreeBSD hs32.drive.ne.jp 9.1-RELEASE FreeBSD 9.1-RELEASE #1: Wed Jan 14 12:18:08 JST 2015 root@hs32.drive.ne.jp:/sys/amd64/compile/hs32 amd64 |
Current File : //usr/src/tools/tools/mid/mid-master-index |
#!/bin/sh if [ $# -le 2 ]; then echo "usage $0 parallel_processes command [comand_options]" exit 1 fi count=$1; shift command=$1; shift file=$1; shift filelistmid=`perl -e "for(0 .. $count -1) {print qq{$file.temp.\\$_.mid }}"` filelistirt=`perl -e "for(0 .. $count -1) {print qq{$file.temp.\\$_.irt }}"` if mid-master $count $command $file.temp; then sort -u -m -o $file.temp.mid $filelistmid && rm -f $filelistmid && mv $file.temp.mid $file.mid || exit 1 sort -u -m -o $file.temp.irt $filelistirt && rm -f $filelistirt && mv $file.temp.irt $file.irt || exit 1 else exit 1 fi