Skip to content

Commit

Permalink
Don't use CPP in Configurations/unix-Makefile.tmpl
Browse files Browse the repository at this point in the history
We started using $(CPP) instead of $(CC) -E, with the assumption that
CPP would be predefined.  This is, however, not always true, and
rather depends on the 'make' implementation.  Furthermore, on
platforms where CPP=cpp or something else other than '$(CC) -E',
there's a risk that it won't understand machine specific flags that we
pass to it.  So it turns out that trying to use $(CPP) was a mistake,
and we therefore revert that use back to using $(CC) -E directly.

Fixes openssl#5867

Note: this affects config targets that use Alpha, ARM, IA64, MIPS,
s390x or SPARC assembler modules.

Reviewed-by: Andy Polyakov <[email protected]>
(Merged from openssl#5872)
  • Loading branch information
levitte committed Apr 4, 2018
1 parent d8fa932 commit d3f9268
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Configurations/unix-Makefile.tmpl
Original file line number Diff line number Diff line change
Expand Up @@ -954,7 +954,7 @@ EOF
}
return <<"EOF";
$args{src}: $args{generator}->[0] $deps
\$(CPP) $incs $cppflags $args{generator}->[0] | \\
\$(CC) $incs $cppflags -E $args{generator}->[0] | \\
\$(PERL) -ne '/^#(line)?\\s*[0-9]+/ or print' > \$@
EOF
}
Expand Down Expand Up @@ -1012,7 +1012,7 @@ EOF
$recipe .= <<"EOF";
$obj$objext: $deps
( trap "rm -f \$@.*" INT 0; \\
\$(CPP) $incs $cmdflags $srcs | \\
\$(CC) $incs $cmdflags -E $srcs | \\
\$(PERL) -ne '/^#(line)?\\s*[0-9]+/ or print' > \[email protected] && \\
$cmd $cmdflags -c -o \$\@ \[email protected] )
EOF
Expand Down

0 comments on commit d3f9268

Please sign in to comment.