Client Build Error on Recent Commits with macOS

Hello:

I’m having an issue with building the current client release under macOS.

I’m gradually working my way through other issues on this OS - but there’s a change introduced with client commit fac3f69 that breaks my build process, whereas the previous commit (077f5ee) builds as expected.

The build error I’m getting is:

client/ConfigPath.cpp:100:4: error: no matching function for call to 'TokenizeMail'
                        TokenizeMail(std::string(dir.path.ToUTF8()), toks, "|");
                        ^~~~~~~~~~~~
client/stringtools.h:71:6: note: candidate function not viable: expects an l-value for 1st argument
void TokenizeMail(std::string& str, std::vector<std::string> &tokens, std::string seps);
     ^

As I’m something of an enthusiastic amateur rather than someone with a real clue of what they’re doing: any smart ideas, before I start jumping in and breaking things?.. :wink:

Thanks!

Does this fix the issue?

Thanks for the quick reply. Unfortunately that just shifted the error elsewhere:

client/stringtools.cpp:1041:8: error: functions that differ only in their return type cannot be overloaded
string htmldecode(string str, bool html, char xc='%');
~~~~~~ ^
client/stringtools.h:100:14: note: previous declaration is here
std::wstring htmldecode(std::string str, bool html=true, char xc='%');
~~~~~~~~~~~~ ^
client/stringtools.cpp:1059:16: error: no viable conversion from 'basic_string<wchar_t, char_traits<wchar_t>,
      allocator<wchar_t>>' to 'basic_string<char, char_traits<char>, allocator<char>>'
                        std::string wv = htmldecode(value, false);
                                    ^    ~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/string:763:5: note: candidate
      constructor not viable: no known conversion from 'std::wstring' (aka 'basic_string<wchar_t, char_traits<wchar_t>,
      allocator<wchar_t> >') to 'const std::__1::basic_string<char> &' for 1st argument
    basic_string(const basic_string& __str);
    ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/string:778:31: note: 
      candidate constructor not viable: no known conversion from 'std::wstring' (aka 'basic_string<wchar_t,
      char_traits<wchar_t>, allocator<wchar_t> >') to 'const value_type *' (aka 'const char *') for 1st argument
    _LIBCPP_INLINE_VISIBILITY basic_string(const value_type* __s);
                              ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/string:818:5: note: candidate
      function
    operator __self_view() const _NOEXCEPT { return __self_view(data(), size()); }
    ^
client/stringtools.cpp:1075:15: error: no viable conversion from 'basic_string<wchar_t, char_traits<wchar_t>,
      allocator<wchar_t>>' to 'basic_string<char, char_traits<char>, allocator<char>>'
                std::string wv = htmldecode(value, false);
                            ^    ~~~~~~~~~~~~~~~~~~~~~~~~
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/string:763:5: note: candidate
      constructor not viable: no known conversion from 'std::wstring' (aka 'basic_string<wchar_t, char_traits<wchar_t>,
      allocator<wchar_t> >') to 'const std::__1::basic_string<char> &' for 1st argument
    basic_string(const basic_string& __str);
    ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/string:778:31: note: 
      candidate constructor not viable: no known conversion from 'std::wstring' (aka 'basic_string<wchar_t,
      char_traits<wchar_t>, allocator<wchar_t> >') to 'const value_type *' (aka 'const char *') for 1st argument
    _LIBCPP_INLINE_VISIBILITY basic_string(const value_type* __s);
                              ^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/include/c++/v1/string:818:5: note: candidate
      function
    operator __self_view() const _NOEXCEPT { return __self_view(data(), size()); }
    ^
client/stringtools.cpp:1180:8: error: functions that differ only in their return type cannot be overloaded
string htmldecode(string str, bool html, char xc)
~~~~~~ ^
client/stringtools.h:100:14: note: previous declaration is here
std::wstring htmldecode(std::string str, bool html=true, char xc='%');
~~~~~~~~~~~~ ^
6 warnings and 4 errors generated.

I’m definitely out of my depth now!

That one here from dev?

Hi:

I’m not sure what happened earlier - but that’s building now that I’ve deleted my repo and checked it out afresh. :grinning:

Many thanks!