Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
S
spdlog
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
spdlog
Commits
ce637440
Commit
ce637440
authored
May 12, 2019
by
gabime
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wip static-lib
parent
61e45974
Hide whitespace changes
Inline
Side-by-side
Showing
21 changed files
with
83 additions
and
33 deletions
+83
-33
async_logger-inl.h
include/spdlog/async_logger-inl.h
+4
-0
common-inl.h
include/spdlog/common-inl.h
+4
-0
file_helper-inl.h
include/spdlog/details/file_helper-inl.h
+4
-0
log_msg-inl.h
include/spdlog/details/log_msg-inl.h
+4
-0
os-inl.h
include/spdlog/details/os-inl.h
+5
-0
pattern_formatter-inl.h
include/spdlog/details/pattern_formatter-inl.h
+4
-0
periodic_worker-inl.h
include/spdlog/details/periodic_worker-inl.h
+6
-0
registry-inl.h
include/spdlog/details/registry-inl.h
+4
-0
thread_pool-inl.h
include/spdlog/details/thread_pool-inl.h
+4
-0
logger-inl.h
include/spdlog/logger-inl.h
+4
-0
ansicolor_sink-inl.h
include/spdlog/sinks/ansicolor_sink-inl.h
+4
-0
base_sink-inl.h
include/spdlog/sinks/base_sink-inl.h
+4
-0
basic_file_sink-inl.h
include/spdlog/sinks/basic_file_sink-inl.h
+4
-0
rotating_file_sink-inl.h
include/spdlog/sinks/rotating_file_sink-inl.h
+4
-0
sink-inl.h
include/spdlog/sinks/sink-inl.h
+4
-0
stdout_color_sinks-inl.h
include/spdlog/sinks/stdout_color_sinks-inl.h
+4
-0
wincolor_sink-inl.h
include/spdlog/sinks/wincolor_sink-inl.h
+7
-0
spdlog-inl.h
include/spdlog/spdlog-inl.h
+4
-0
spdlog.cpp
src/spdlog.cpp
+2
-32
includes.h
tests/includes.h
+2
-1
test_fmt_helper.cpp
tests/test_fmt_helper.cpp
+1
-0
No files found.
include/spdlog/async_logger-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/async_logger.h"
#endif
#include "spdlog/sinks/sink.h"
#include "spdlog/details/thread_pool.h"
...
...
include/spdlog/common-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/common.h"
#endif
namespace
spdlog
{
namespace
level
{
static
string_view_t
level_string_views
[]
SPDLOG_LEVEL_NAMES
;
...
...
include/spdlog/details/file_helper-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/details/file_helper.h"
#endif
#include "spdlog/details/os.h"
#include <cerrno>
...
...
include/spdlog/details/log_msg-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/details/log_msg.h"
#endif
#include "spdlog/details/os.h"
#include "spdlog/sinks/sink.h"
...
...
include/spdlog/details/os-inl.h
View file @
ce637440
...
...
@@ -2,6 +2,11 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/details/os.h"
#endif
#include <algorithm>
#include <chrono>
#include <cstdio>
...
...
include/spdlog/details/pattern_formatter-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/details/pattern_formatter.h"
#endif
#include "spdlog/details/fmt_helper.h"
#include "spdlog/details/log_msg.h"
#include "spdlog/details/os.h"
...
...
include/spdlog/details/periodic_worker-inl.h
View file @
ce637440
...
...
@@ -2,8 +2,14 @@
// Distributed under the MIT License (http://opensource.org/licenses/MIT)
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/details/periodic_worker.h"
#endif
namespace
spdlog
{
namespace
details
{
SPDLOG_INLINE
periodic_worker
::
periodic_worker
(
const
std
::
function
<
void
()
>
&
callback_fun
,
std
::
chrono
::
seconds
interval
)
{
active_
=
(
interval
>
std
::
chrono
::
seconds
::
zero
());
...
...
include/spdlog/details/registry-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/details/registry.h"
#endif
#include "spdlog/common.h"
#include "spdlog/details/periodic_worker.h"
#include "spdlog/logger.h"
...
...
include/spdlog/details/thread_pool-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/details/thread_pool.h"
#endif
#include "spdlog/common.h"
namespace
spdlog
{
...
...
include/spdlog/logger-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/logger.h"
#endif
#include "spdlog/sinks/sink.h"
#include "spdlog/details/pattern_formatter.h"
...
...
include/spdlog/sinks/ansicolor_sink-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/sinks/ansicolor_sink.h"
#endif
#include "spdlog/details/os.h"
template
<
typename
TargetStream
,
typename
ConsoleMutex
>
...
...
include/spdlog/sinks/base_sink-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/sinks/base_sink.h"
#endif
#include "spdlog/common.h"
#include "spdlog/details/pattern_formatter.h"
...
...
include/spdlog/sinks/basic_file_sink-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/sinks/basic_file_sink.h"
#endif
#include "spdlog/common.h"
#include "spdlog/details/os.h"
...
...
include/spdlog/sinks/rotating_file_sink-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/sinks/rotating_file_sink.h"
#endif
#include "spdlog/common.h"
#include "spdlog/details/file_helper.h"
...
...
include/spdlog/sinks/sink-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/sinks/sink.h"
#endif
#include "spdlog/common.h"
#include "spdlog/details/pattern_formatter.h"
...
...
include/spdlog/sinks/stdout_color_sinks-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/sinks/stdout_color_sinks.h"
#endif
#include "spdlog/logger.h"
#include "spdlog/common.h"
...
...
include/spdlog/sinks/wincolor_sink-inl.h
View file @
ce637440
...
...
@@ -3,8 +3,15 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/sinks/wincolor_sink.h"
#endif
#include "spdlog/common.h"
namespace
spdlog
{
namespace
sinks
{
template
<
typename
TargetStream
,
typename
ConsoleMutex
>
SPDLOG_INLINE
wincolor_sink
<
TargetStream
,
ConsoleMutex
>::
wincolor_sink
()
:
out_handle_
(
TargetStream
::
handle
())
...
...
include/spdlog/spdlog-inl.h
View file @
ce637440
...
...
@@ -3,6 +3,10 @@
#pragma once
#ifndef SPDLOG_HEADER_ONLY
#include "spdlog/spdlog.h"
#endif
#include "spdlog/common.h"
#include "spdlog/details/pattern_formatter.h"
...
...
src/spdlog.cpp
View file @
ce637440
...
...
@@ -8,72 +8,48 @@
#include <mutex>
#include <chrono>
#include "spdlog/spdlog.h"
#include "spdlog/spdlog-inl.h"
#include "spdlog/details/null_mutex.h"
#include "spdlog/async.h"
#include "spdlog/
common
.h"
#include "spdlog/
spdlog-inl
.h"
#include "spdlog/common-inl.h"
#include "spdlog/details/null_mutex.h"
#include "spdlog/logger.h"
#include "spdlog/logger-inl.h"
template
spdlog
::
logger
::
logger
(
std
::
string
name
,
sinks_init_list
::
iterator
begin
,
sinks_init_list
::
iterator
end
);
#include "spdlog/async_logger.h"
#include "spdlog/async_logger-inl.h"
#include "spdlog/details/log_msg.h"
#include "spdlog/details/log_msg-inl.h"
#include "spdlog/sinks/sink.h"
#include "spdlog/sinks/sink-inl.h"
#include "spdlog/sinks/base_sink.h"
#include "spdlog/sinks/base_sink-inl.h"
template
class
spdlog
::
sinks
::
base_sink
<
std
::
mutex
>
;
template
class
spdlog
::
sinks
::
base_sink
<
spdlog
::
details
::
null_mutex
>
;
#include "spdlog/sinks/basic_file_sink.h"
#include "spdlog/sinks/basic_file_sink-inl.h"
template
class
spdlog
::
sinks
::
basic_file_sink
<
std
::
mutex
>
;
template
class
spdlog
::
sinks
::
basic_file_sink
<
spdlog
::
details
::
null_mutex
>
;
#include "spdlog/sinks/rotating_file_sink.h"
#include "spdlog/sinks/rotating_file_sink-inl.h"
template
class
spdlog
::
sinks
::
rotating_file_sink
<
std
::
mutex
>
;
template
class
spdlog
::
sinks
::
rotating_file_sink
<
spdlog
::
details
::
null_mutex
>
;
#include "spdlog/details/registry.h"
#include "spdlog/details/registry-inl.h"
#include "spdlog/details/os.h"
#include "spdlog/details/os-inl.h"
#include "spdlog/details/periodic_worker.h"
#include "spdlog/details/periodic_worker-inl.h"
#include "spdlog/details/file_helper.h"
#include "spdlog/details/file_helper-inl.h"
#include "spdlog/details/pattern_formatter.h"
#include "spdlog/details/pattern_formatter-inl.h"
#include "spdlog/details/thread_pool.h"
#include "spdlog/details/thread_pool-inl.h"
template
class
spdlog
::
details
::
mpmc_blocking_queue
<
spdlog
::
details
::
async_msg
>
;
#ifdef _WIN32
#include "spdlog/sinks/wincolor_sink.h"
#include "spdlog/sinks/wincolor_sink-inl.h"
template
class
spdlog
::
sinks
::
wincolor_sink
<
spdlog
::
details
::
console_stdout
,
spdlog
::
details
::
console_mutex
>
;
template
class
spdlog
::
sinks
::
wincolor_sink
<
spdlog
::
details
::
console_stdout
,
spdlog
::
details
::
console_nullmutex
>
;
template
class
spdlog
::
sinks
::
wincolor_sink
<
spdlog
::
details
::
console_stderr
,
spdlog
::
details
::
console_mutex
>
;
template
class
spdlog
::
sinks
::
wincolor_sink
<
spdlog
::
details
::
console_stderr
,
spdlog
::
details
::
console_nullmutex
>
;
#else
#include "spdlog/sinks/ansicolor_sink.h"
#include "spdlog/sinks/ansicolor_sink-inl.h"
template
class
spdlog
::
sinks
::
ansicolor_sink
<
spdlog
::
details
::
console_stdout
,
spdlog
::
details
::
console_mutex
>
;
template
class
spdlog
::
sinks
::
ansicolor_sink
<
spdlog
::
details
::
console_stdout
,
spdlog
::
details
::
console_nullmutex
>
;
...
...
@@ -81,7 +57,6 @@ template class spdlog::sinks::ansicolor_sink<spdlog::details::console_stderr, sp
template
class
spdlog
::
sinks
::
ansicolor_sink
<
spdlog
::
details
::
console_stderr
,
spdlog
::
details
::
console_nullmutex
>
;
#endif
#include "spdlog/sinks/stdout_color_sinks.h"
#include "spdlog/sinks/stdout_color_sinks-inl.h"
template
std
::
shared_ptr
<
spdlog
::
logger
>
spdlog
::
stdout_color_mt
<
spdlog
::
synchronous_factory
>
(
const
std
::
string
&
logger_name
);
template
std
::
shared_ptr
<
spdlog
::
logger
>
spdlog
::
stdout_color_st
<
spdlog
::
synchronous_factory
>
(
const
std
::
string
&
logger_name
);
...
...
@@ -93,11 +68,6 @@ template std::shared_ptr<spdlog::logger> spdlog::stdout_color_st<spdlog::async_f
template
std
::
shared_ptr
<
spdlog
::
logger
>
spdlog
::
stderr_color_mt
<
spdlog
::
async_factory
>
(
const
std
::
string
&
logger_name
);
template
std
::
shared_ptr
<
spdlog
::
logger
>
spdlog
::
stderr_color_st
<
spdlog
::
async_factory
>
(
const
std
::
string
&
logger_name
);
// fmt_helper templates
#include "spdlog/details/fmt_helper.h"
template
void
spdlog
::
details
::
fmt_helper
::
append_string_view
(
spdlog
::
string_view_t
view
,
fmt
::
memory_buffer
&
dest
);
template
spdlog
::
string_view_t
spdlog
::
details
::
fmt_helper
::
to_string_view
(
const
fmt
::
memory_buffer
&
buf
)
SPDLOG_NOEXCEPT
;
// Slightly modified version of fmt lib's format.cc source file.
// Copyright (c) 2012 - 2016, Victor Zverovich
// All rights reserved.
...
...
tests/includes.h
View file @
ce637440
...
...
@@ -20,4 +20,4 @@
#include "spdlog/sinks/ostream_sink.h"
#include "spdlog/sinks/rotating_file_sink.h"
#include "spdlog/sinks/stdout_color_sinks.h"
#include "spdlog/details/pattern_formatter.h"
#include "spdlog/details/pattern_formatter.h"
\ No newline at end of file
tests/test_fmt_helper.cpp
View file @
ce637440
#include "includes.h"
#include "spdlog/details/fmt_helper.h"
void
test_pad2
(
int
n
,
const
char
*
expected
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment