[xbuild] Fix bug #674630.
[mono.git] / mono / cil / make-opcodes-def.pl
index 3114918bb6512267b93896dba71100d0be68413a..a94c15778cac608d1f83d9d1e23421d0de139da9 100644 (file)
@@ -19,10 +19,10 @@ my %valid_flow;
 # the XML file also includes "throw"
 @valid_flow{qw(next call return branch meta cond-branch)} = ();
 
-open OUTPUT, ">opcode.def" || die "Can not create opcode.def file: $!";
+open OUTPUT, ">$ARGV[1]" || die "Can not create $ARGV[1] file: $!";
 
 my $parser = new XML::Parser (Handlers => {Start => \&handle_opcode});
-$parser->parsefile("cil-opcodes.xml");
+$parser->parsefile($ARGV[0]);
 print_trailer();
 close(OUTPUT) || die "Can not close file: $!";