[MacPorts] #65886: rbmake @1.2_8: rev-upgrade fails with: error: cannot combine with previous 'char' declaration specifier
MacPorts
noreply at macports.org
Fri Sep 23 09:43:59 UTC 2022
#65886: rbmake @1.2_8: rev-upgrade fails with: error: cannot combine with previous
'char' declaration specifier
--------------------------+--------------------
Reporter: cooljeanius | Owner: (none)
Type: defect | Status: new
Priority: Normal | Milestone:
Component: ports | Version: 2.7.2
Resolution: | Keywords:
Port: rbmake |
--------------------------+--------------------
Comment (by ryandesign):
Replying to [comment:1 ryandesign]:
> I don't see the `bool`-redefinition-related build failure on my Catalina
system but I'll see what I can do about that as well.
I was able to reproduce it on Monterey. For whatever reason, on these new
systems, the system headers now cause the C99 <stdbool.h> header to be
included, which defines `bool`, `true`, and `false`. rbmake's rbfile.h
checks whether `true` and `false` are defined before defining them, and
provides way to prevent them from being defined even if they aren't
already, but defines `bool` unconditionally, hence the clash.
I opted to fix it by ripping the custom `bool`/`true`/`false` out of
rbmake's rbfile.h and making it use <stdbool.h> instead, which requires
that rbmake and any other project that uses its header be compiled with at
least `-std=c99` now. I figured it was ok in 2022 to require at least the
1999 C standard. There are no ports in MacPorts that depend on rbmake that
would need to be updated.
--
Ticket URL: <https://trac.macports.org/ticket/65886#comment:2>
MacPorts <https://www.macports.org/>
Ports system for macOS
More information about the macports-tickets
mailing list