2010-04-08 Jb Evain <jbevain@novell.com>
[mcs.git] / tools / removecomments.sh
blob2d8cb27023a6d8813d0ccc6847b71bdfc9721b65
1 #!/bin/sh
3 # Remove comments from .sources files since this usage of IFS is unsuable inside make
4 # (trouble with newlines)
6 source_files="$@"
8 OIFS=$IFS
10 for f in $source_files ; do
11 IFS='
13 for f in `cat $f` ; do
14 case $f in
15 \#*) ;;
16 *) echo $f ;;
17 esac
18 done
19 OIFS=$IFS
20 done
22 IFS=$OIFS