-
Notifications
You must be signed in to change notification settings - Fork 41
Open
Description
Building nxcomp 3.5.99.22 on a case-insensitive filesystem (e.g. on macOS) with a C++20-capable compiler (e.g. Apple clang version 14.0.0 (clang-1400.0.29.202)) fails:
In file included from /Library/Developer/CommandLineTools/SDKs/MacOSX12.sdk/usr/include/c++/v1/ostream:142:
../version:1:1: error: expected unqualified-id
3.5.99.22
^
This is because C++20 has a header called version which other system headers include, and on a case-insensitive filesystem your VERSION file will be found instead.
Solutions include:
- Stop adding the
-Iflag that points to the directory where theVERSIONfile is located. With a project like this one that uses autoconf, this-Iflag is added automatically because this is the directory where config.h is created. So one solution is to move config.h to a different directory. - Move the
VERSIONfile to a different directory, one for which an-Iflag is not added, and update all references to it, e.g. in version.sh. - Rename the
VERSIONfile to something else, e.g.VERSION.txt, and update all references to it.
Metadata
Metadata
Assignees
Labels
No labels