Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add the SPDLOG_USE_WCHAR tweak to enable support for Unicode names on Windows. #192

Merged
merged 1 commit into from
Apr 5, 2016

Conversation

Kentzo
Copy link
Contributor

@Kentzo Kentzo commented Apr 3, 2016

Refs #111

@gabime gabime merged commit 570f898 into gabime:master Apr 5, 2016
@gabime
Copy link
Owner

gabime commented Apr 5, 2016

I reverted. didn't compile properly under vs2015

@Kentzo
Copy link
Contributor Author

Kentzo commented Apr 5, 2016

@gabime What was the error?

I'll install vs2015 and test later today.

@gabime
Copy link
Owner

gabime commented Apr 5, 2016

an #include <codecvt> was missing in common.h

I will make some changes and merge again soon

@Kentzo
Copy link
Contributor Author

Kentzo commented Apr 5, 2016

@gabime This include caused errors in tests. See https://travis-ci.org/gabime/spdlog/jobs/120374514

We need to find a fallback method for turning wstring to string that should be executed in case compiler does not support codecvt.

The codecvt version should be preferred though.

@gabime
Copy link
Owner

gabime commented Apr 5, 2016

right. seems like gcc don't have this file.

@gabime
Copy link
Owner

gabime commented Apr 5, 2016

I think I will add something like

#if defined(_WIN32) && defined(SPDLOG_USE_WCHAR)
#include <locale>
#include <codecvt>
#endif

@Kentzo
Copy link
Contributor Author

Kentzo commented Apr 5, 2016

@gabime It's rather libstdc++. But I read somewhere that modern versions do support it.

Not sure how could we figure this out exactly, but your change seems sane.

@Kentzo
Copy link
Contributor Author

Kentzo commented Apr 6, 2016

@gabime Did this fix work for you?

@gabime
Copy link
Owner

gabime commented Apr 7, 2016

@Kentzo sorry, I did not have time to get to it.

@Kentzo
Copy link
Contributor Author

Kentzo commented Apr 8, 2016

@gabime See #193

bachittle pushed a commit to bachittle/spdlog that referenced this pull request Dec 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants