[MacPorts] #67811: wesnoth build fails with gcc: error: 'quick_exit' is not a member of 'std'

MacPorts noreply at macports.org
Mon Jul 24 04:06:45 UTC 2023


#67811: wesnoth build fails with gcc: error: 'quick_exit' is not a member of 'std'
---------------------------+------------------------
  Reporter:  barracuda156  |      Owner:  ryandesign
      Type:  defect        |     Status:  assigned
  Priority:  Low           |  Milestone:
 Component:  ports         |    Version:  2.8.1
Resolution:                |   Keywords:
      Port:  wesnoth       |
---------------------------+------------------------

Comment (by ryandesign):

 Replying to [ticket:67811 barracuda156]:
 > {{{
 > :info:build
 /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_games_wesnoth/wesnoth/work/wesnoth-1.16.9/src/serialization/schema/type.cpp:38:36:
 error: 'monostate' in namespace 'std' does not name a type
 > :info:build    38 |         bool operator()(const std::monostate&) const
 > :info:build       |                                    ^~~~~~~~~
 > }}}

 According to [https://en.cppreference.com/w/cpp/utility/variant/monostate
 this] one must `#include <variant>` to get `std::monostate`. Does adding
 that to type.cpp help?

 > {{{
 > :info:build
 /opt/local/var/macports/build/_opt_local_var_macports_sources_rsync.macports.org_macports_release_tarballs_ports_games_wesnoth/wesnoth/work/wesnoth-1.16.9/src/gui/dialogs/loading_screen.cpp:185:22:
 error: 'quick_exit' is not a member of 'std'
 > :info:build   185 |                 std::quick_exit(0);
 > :info:build       |                      ^~~~~~~~~~
 > }}}

 There is a similar report [https://github.com/wesnoth/wesnoth/issues/3295
 here] which was closed without being fixed.

 We have successful builds on the buildbot on 10.7 and later. According to
 [https://stackoverflow.com/questions/11681403/state-of-c11-standard-
 support-in-libc/60496235#60496235 this] macOS libc didn't implement
 `std::quick_exit` as recently as March 2020. Perhaps for that reason, six
 years ago
 [https://github.com/wesnoth/wesnoth/commit/120b11c0e0b96870789fcd8205c4b0e5fd5d9511
 this commit] disabled the use of `std::quick_exit` on macOS, but half an
 hour later
 [https://github.com/wesnoth/wesnoth/commit/52e77fb0ed7c33ecccd9860a16faac1cee236525
 this commit] re-enabled the use of `std::quick_exit` on macOS when using
 libstdc++, which you are since you're using gcc.

 These are upstream issues that should be reported to the developers.

-- 
Ticket URL: <https://trac.macports.org/ticket/67811#comment:1>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list