home *** CD-ROM | disk | FTP | other *** search
- #! perl -w
- use RISCOS;
-
- die "$0 <Objectprefix> <Sourceprefix> <Pattern>" if( $#ARGV < 1 );
-
- $obj = shift;
- $prefix = shift;
- foreach ( @ARGV )
- {
- foreach $source ( RISCOS::Filespec::globlist( "$prefix$_" ) )
- {
- $source = substr $source, length $prefix;
-
- $source =~ s/\.c\./\.o\./;
- $source =~ s/\.s\./\.o\./;
-
- $source = $obj . $source;
- if( -f $source )
- {
- print "$source\n";
- unlink( "$source" ) or warn $!;
- }
- }
- }
-