mirror of
https://github.com/gabime/spdlog.git
synced 2025-01-26 07:29:03 +08:00
Fixed windows compile
This commit is contained in:
parent
f67645a7e9
commit
9bc69aa2f5
@ -4,11 +4,10 @@
|
||||
// clang-format off
|
||||
#include "spdlog/details/windows_include.h"
|
||||
#include <wincon.h>
|
||||
|
||||
// clang-format on
|
||||
#include <mutex>
|
||||
#include "spdlog/sinks/wincolor_sink.h"
|
||||
#include "spdlog/common.h"
|
||||
#include "spdlog/details/null_mutex.h"
|
||||
|
||||
namespace spdlog {
|
||||
namespace sinks {
|
||||
@ -121,29 +120,30 @@ void wincolor_sink<Mutex>::write_to_file_(const memory_buf_t &formatted) {
|
||||
(void)(ignored);
|
||||
}
|
||||
|
||||
// template instantiations
|
||||
template class SPDLOG_API wincolor_stdout_sink<std::mutex>;
|
||||
template class SPDLOG_API wincolor_stdout_sink<details::null_mutex>;
|
||||
|
||||
|
||||
// spdlog::sinks::wincolor_stderr_sink<struct spdlog::details::null_mutex>::wincolor_stderr_sink<struct spdlog::details::null_mutex>(enum spdlog::color_mode)"
|
||||
template<> class SPDLOG_API
|
||||
wincolor_stdout_sink<std::mutex>::wincolor_stdout_sink(color_mode mode)
|
||||
: wincolor_sink<std::mutex>(::GetStdHandle(STD_OUTPUT_HANDLE), mode) {}
|
||||
|
||||
|
||||
template<> class SPDLOG_API
|
||||
wincolor_stdout_sink<details::null_mutex>::wincolor_stdout_sink(color_mode mode)
|
||||
: wincolor_sink<details::null_mutex>(::GetStdHandle(STD_OUTPUT_HANDLE), mode) {}
|
||||
// wincolor_stdout_sink
|
||||
template <typename Mutex>
|
||||
wincolor_stdout_sink<Mutex>::wincolor_stdout_sink(color_mode mode)
|
||||
: wincolor_sink<Mutex>(::GetStdHandle(STD_OUTPUT_HANDLE), mode) {}
|
||||
|
||||
// wincolor_stderr_sink
|
||||
template<> class SPDLOG_API
|
||||
wincolor_stderr_sink<std::mutex>::wincolor_stderr_sink(color_mode mode)
|
||||
: wincolor_sink<std::mutex>(::GetStdHandle(STD_ERROR_HANDLE), mode) {}
|
||||
template <typename Mutex>
|
||||
wincolor_stderr_sink<Mutex>::wincolor_stderr_sink(color_mode mode)
|
||||
: wincolor_sink<Mutex>(::GetStdHandle(STD_ERROR_HANDLE), mode) {}
|
||||
|
||||
template<> class SPDLOG_API
|
||||
wincolor_stderr_sink<details::null_mutex>::wincolor_stderr_sink(color_mode mode)
|
||||
: wincolor_sink<details::null_mutex>(::GetStdHandle(STD_ERROR_HANDLE), mode) {}
|
||||
|
||||
} // namespace sinks
|
||||
} // namespace spdlog
|
||||
|
||||
|
||||
#include <mutex>
|
||||
#include "spdlog/details/null_mutex.h"
|
||||
|
||||
// template instantiations
|
||||
template class SPDLOG_API spdlog::sinks::wincolor_sink<std::mutex>;
|
||||
template class SPDLOG_API spdlog::sinks::wincolor_sink<spdlog::details::null_mutex>;
|
||||
|
||||
template class SPDLOG_API spdlog::sinks::wincolor_stdout_sink<std::mutex>;
|
||||
template class SPDLOG_API spdlog::sinks::wincolor_stdout_sink<spdlog::details::null_mutex>;
|
||||
|
||||
template class SPDLOG_API spdlog::sinks::wincolor_stderr_sink<std::mutex>;
|
||||
template class SPDLOG_API spdlog::sinks::wincolor_stderr_sink<spdlog::details::null_mutex>;
|
||||
|
Loading…
Reference in New Issue
Block a user