Opened 14 months ago

Last modified 6 months ago

#59800 assigned defect

wxWidgets-3.0: error: unknown type name 'nullptr_t'; did you mean 'std::nullptr_t'?

Reported by: ryandesign (Ryan Schmidt) Owned by: mojca (Mojca Miklavec)
Priority: Normal Milestone:
Component: ports Version: 2.6.2
Keywords: Cc: MSoegtropIMC, MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Port: wxWidgets-3.0

Description

xchm is failing to build at least on 10.10 and 10.11. It looks like the problem is in wxWidgets-3.0:

In file included from chmsearchpanel.cpp:21:
In file included from ./chmhtmlnotebook.h:25:
In file included from /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/aui/auibook.h:24:
In file included from /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/aui/tabart.h:23:
In file included from /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/colour.h:15:
In file included from /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/gdiobj.h:14:
In file included from /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/object.h:19:
In file included from /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/memory.h:15:
In file included from /opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/string.h:46:
/opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/strvararg.h:442:27: error: unknown type name 'nullptr_t'; did you mean 'std::nullptr_t'?
wxFORMAT_STRING_SPECIFIER(nullptr_t, wxFormatString::Arg_Pointer)
                          ^~~~~~~~~
                          std::nullptr_t
/opt/local/Library/Frameworks/wxWidgets.framework/Versions/wxWidgets/3.0/include/wx-3.0/wx/strvararg.h:396:47: note: expanded from macro 'wxFORMAT_STRING_SPECIFIER'
    template<> struct wxFormatStringSpecifier<T>                            \
                                              ^
/Library/Developer/CommandLineTools/usr/bin/../include/c++/v1/cstddef:97:31: note: 'std::nullptr_t' declared here
    typedef decltype(nullptr) nullptr_t;
                              ^

Change History (4)

comment:1 Changed 14 months ago by jmroot (Joshua Root)

The fix is probably to patch it to #include <cstddef> if it doesn't already, and change nullptr_t to std::nullptr_t. It may be including stddef.h to try to get nullptr_t in the global namespace, but some Xcode versions don't implement that correctly (and doing it is deprecated anyway).

comment:2 Changed 7 months ago by ryandesign (Ryan Schmidt)

hugin-app is failing to build on 10.8 for the same reason. Mojca, any news on a fix for this, perhaps like Josh proposed above?

comment:3 Changed 6 months ago by ryandesign (Ryan Schmidt)

Cc: MSoegtropIMC MarcusCalhoun-Lopez added

wxMaxima is failing to build on 10.11 and earlier for the same reason.

comment:4 Changed 6 months ago by reneeotten (Renee Otten)

I haven't tried to, but from a quick glance it looks like this might have been fixed in the latest version (v3.0.5.1) - so perhaps updating wxWidgets-3.0 would be the way forward?

Note: See TracTickets for help on using tickets.