YosysHQ / yosys

Yosys Open SYnthesis Suite
https://yosyshq.net/yosys/
ISC License
3.31k stars 860 forks source link

Fix CXX variables in Makefile #4258

Closed RCoeurjoly closed 4 months ago

RCoeurjoly commented 4 months ago

Thanks to the comment by @KrystalDelusion in https://github.com/YosysHQ/yosys/issues/4244#issuecomment-1975402037, the solution was found.

This PR fixes https://github.com/YosysHQ/yosys/issues/4244.

RCoeurjoly commented 4 months ago

the emcc pipeline fails, it seems to be related to the CXX variable

KrystalDelusion commented 4 months ago

TIL make automatically provides a default value of CXX = g++, which can be seen as it is g++ returning the error. I suspect make config-clang; make would also run g++ in this case despite the implication of using the clang config; which (in hindsight) is probably why this was setup the way it was. Rather than changing the the CXX assignments, it might make more sense to assign CONFIG=none by default and leave config-gcc/config-clang etc to override as previously intended.

@RCoeurjoly can you check if #4270 also fixes your issue? You'll want to delete Makefile.conf first and then go straight to make (no call to make config-clang)

RCoeurjoly commented 4 months ago

TIL make automatically provides a default value of CXX = g++, which can be seen as it is g++ returning the error. I suspect make config-clang; make would also run g++ in this case despite the implication of using the clang config; which (in hindsight) is probably why this was setup the way it was. Rather than changing the the CXX assignments, it might make more sense to assign CONFIG=none by default and leave config-gcc/config-clang etc to override as previously intended.

@RCoeurjoly can you check if #4270 also fixes your issue? You'll want to delete Makefile.conf first and then go straight to make (no call to make config-clang)

I confirm that PR 4270 fixes this issue.

KrystalDelusion commented 4 months ago

Awesome. I'll close this one in favour of that then.