Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clang support? #424

Open
brad0 opened this issue Dec 23, 2021 · 3 comments
Open

Clang support? #424

brad0 opened this issue Dec 23, 2021 · 3 comments

Comments

@brad0
Copy link
Contributor

brad0 commented Dec 23, 2021

Looking at Compcert I'm trying to clarify if this project absolutely requires GCC or if it should work with Clang?

@didickman
Copy link
Contributor

didickman commented Dec 23, 2021

Hello Xavier and team. For context Brad is looking at the OpenBSD CompCert package and is interested in seeing whether the gcc requirement could be switched to clang. I’ve already pointed him to section 2.2.2 in the manual which states that gcc or diab are required. Although given his interest in clang I’d suggested he could also check with you if there was any appetite to support clang. OpenBSD has mostly switched to clang on platforms that support it. Although gcc and gnu binutils remain available for packages that need them. All the best and happy holidays.

@xavierleroy
Copy link
Contributor

xavierleroy commented Dec 27, 2021

I would expect CompCert to work fine with Clang, with two caveats:
1- CompCert invokes gcc or targetname-gcc to perform preprocessing, assembling, and linking. This may need to be changed to clang or to cc to fit your use case.
2- For development and CI, we use GCC for Linux and Windows and Clang for macOS. So, Clang is tested for x86-64 and for aarch64, but has never been tested for PowerPC, say.

Why not give it a try and let us know how it goes?

@didickman
Copy link
Contributor

Thank you. Will take some time but we will try 32-bit/64-bit x86 and aarch64 on OpenBSD. Last I checked, PowerPC does build here although looked like it needs some minor fix at runtime. I do not have access to powerpc64 or riscv boxes although the project does, so we may be able to test those too. (Will need to check if ocaml and coq are built on those platforms though).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants