+Change 170 on 1998/07/05 by <gbarr@pobox.com> (Graham Barr)
+
+ Fixed three problems reported by Hans Mulder for NeXT
+
+ - Errno_pm.PL does not recognize #define lines because they have
+ whitespace before the '#'. ANSI does not allow that in portable
+ code; that didn't stop the author of NeXT's <errno.h>.
+
+ - Cpp output lines look like this: #1 "errno.c"
+ Errno_pm.PL does not recognize that format; it wants whitespace
+ before the line number.
+
+ - Cpp does a syntax check on files with names ending in ".c"; it
+ reports fatal errors on input lines like: "ENOSYS" [[ENOSYS]]
+ Workaround: use $Config{cppstdin}, like Errno 1.04 did.
+
Change 160 on 1998/06/27 by <gbarr@pobox.com> (Graham Barr)
- Added patch from Sarathy to support Win32
use vars qw($VERSION);
-$VERSION = "1.08";
+$VERSION = "1.09";
my %err = ();
}
while(<FH>) {
$err{$1} = 1
- if /^\s*#\s*define\s+(E\w+)\s+/;
+ if /^\s*#\s*define\s+(E\w+)\s+/;
}
close(FH);
}
close(CPPI);
# invoke CPP and read the output
+
if ($^O eq 'VMS') {
my $cpp = "$Config{cppstdin} $Config{cppflags} $Config{cppminus}";
$cpp =~ s/sys\$input//i;
open(CPPO,"$cpp errno.c |") or
die "Cannot exec $Config{cppstdin}";
- } elsif ($^O eq 'next') {
+ } elsif($^O eq 'next') {
+ # NeXT will do syntax checking unless it is reading from stdin
my $cpp = "$Config{cppstdin} $Config{cppflags} $Config{cppminus}";
- open(CPPO,"$cpp < errno.c |") or die "Cannot exec $cpp";
+ open(CPPO,"$cpp < errno.c |")
+ or die "Cannot exec $cpp";
} else {
open(CPPO,"$Config{cpprun} $Config{cppflags} errno.c |") or
die "Cannot exec $Config{cpprun}";