recognize but ignore -undef flag
authorceriel <none@none>
Mon, 12 Feb 1990 14:33:57 +0000 (14:33 +0000)
committerceriel <none@none>
Mon, 12 Feb 1990 14:33:57 +0000 (14:33 +0000)
util/cpp/cpp.6
util/cpp/options.c

index 95fb605..38b3717 100644 (file)
@@ -58,6 +58,9 @@ when generating makefile dependencies, generate them in the following format:
 .IP ""
 where "file.o" is derived from the source file name. Normally, only a list
 of files included is generated.
+.IP -\fBundef\fR
+.br
+this flag is silently ignored, for compatibility with other preprocessors.
 .PP
 The following names are always available unless undefined:
 .IP __FILE__
index 24b015a..429cad7 100644 (file)
@@ -31,6 +31,12 @@ do_option(text)
        case 'x':
                options[*text] = 1;
                break;
+       case 'u':
+               if (! strcmp(text,"ndef")) {
+                       /* ignore -undef */
+                       break;
+               }
+               /* fall through */
        default:
                error("illegal option: %c", text[-1]);
                break;