aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
-rwxr-xr-xcgcc8
1 files changed, 8 insertions, 0 deletions
diff --git a/cgcc b/cgcc
index 40004425..e215827c 100755
--- a/cgcc
+++ b/cgcc
@@ -39,6 +39,14 @@ while (@ARGV) {
$nargs = 1;
}
+ # Ignore the extension if '-x c' is given.
+ if ($_ eq '-x') {
+ die ("$0: missing argument for $_") if !@ARGV;
+ die ("$0: invalid argument for $_") if $ARGV[0] ne 'c';
+ $do_check = 1;
+ $nargs = 1;
+ }
+
$m32 = 1 if /^-m32$/;
$m64 = 1 if /^-m64$/;
$gendeps = 1 if /^-M$/;