Skip to content

Pass '-x c++' and '-std=c++11' to `cc` for cpp files, in Hadrian

Ethan Kiang requested to merge zyklotomic/ghc:fix/hadrian_cc_cpp into master

I was trying to compile GHC with ghc-debug support, using Hadrian, after cherry-picking commit 4be70967f1f1ab70cbe31aad8ae69aea87c6f4c4 onto master, but was unable to before this patch.

This patch passes the arguments -x c++ and -std=c++11 to cc when compiling a C++ file.

Operating System: macOS Catalina

Clang --version output:

Apple clang version 12.0.0 (clang-1200.0.32.29)
Target: x86_64-apple-darwin19.6.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
Edited by Ethan Kiang

Merge request reports