X-Git-Url: https://oss.titaniummirror.com/gitweb/?p=nesc.git;a=blobdiff_plain;f=src%2Fnesc-compile;fp=src%2Fnesc-compile;h=cdcfe1234590c5ddb98ce0aed118e46ea4c62280;hp=b02b5ba325fe64ffaf49a85aab56dc153327436a;hb=7b54393e237ed8f23c0c74f0a6cbc8de26c5bf98;hpb=57d4530c4d6814fa25338a00cc65b95938c723b6 diff --git a/src/nesc-compile b/src/nesc-compile index b02b5ba..cdcfe12 100755 --- a/src/nesc-compile +++ b/src/nesc-compile @@ -54,6 +54,10 @@ for ($i = 0; $i <= $#ARGV; $i++) { push @gcc_args, "--param"; push @gcc_args, $param; } + elsif (/^-include$/) { + ($i, $file) = &nextarg($i); + push @nesc_args, "-include", $file; + } elsif (/^-S$/) { $asmonly = 1; } @@ -136,6 +140,10 @@ if ($nocompile && !$conly) { # Check for gcc 4.0.x, which don't tell us about the __STDC__ #define unshift @nesc_args, "-D__STDC__" if isgcc40($gcc); +# Get rid of __BLOCKS__ define, if any (prevent use of Apple C extension that +# nesC doesn't understand) +unshift @nesc_args, "-U__BLOCKS__"; + unshift @nesc_args, "nesc1"; &vsystem(@nesc_args);