shithub: scc

Download patch

ref: 6853b1e9d0763d49d00264f9c1cd3edc25c3299b
parent: ff5b36e280ae269eaa3835006f0f46fbe1bb2d2f
author: Roberto E. Vargas Caballero <k0ga@shike2.com>
date: Sun Oct 6 18:14:45 EDT 2019

[cc] Force cc1 when -E is used

When -E is used we can ignore the extensions of the files
and pass to cc1 because we only want to preprocess the files.

--- a/src/cmd/cc/posix/cc.c
+++ b/src/cmd/cc/posix/cc.c
@@ -353,6 +353,9 @@
 {
 	char *dot = strrchr(file, '.');
 
+	if (Eflag)
+		return CC1;
+
 	if (dot) {
 		if (!strcmp(dot, ".c"))
 			return CC1;