SHA256
1
0
forked from pool/spdlog

Accepting request 678535 from devel:libraries:c_c++

OBS-URL: https://build.opensuse.org/request/show/678535
OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/spdlog?expand=0&rev=6
This commit is contained in:
Stephan Kulow 2019-02-25 16:56:15 +00:00 committed by Git OBS Bridge
commit a2a1920171
4 changed files with 154 additions and 9 deletions

View File

@ -1,3 +0,0 @@
version https://git-lfs.github.com/spec/v1
oid sha256:867a4b7cedf9805e6f76d3ca41889679054f7e5a3b67722fe6d0eae41852a767
size 188284

3
spdlog-1.3.1.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:160845266e94db1d4922ef755637f6901266731c4cb3b30b45bf41efa0e6ab70
size 202634

View File

@ -1,9 +1,147 @@
-------------------------------------------------------------------
Mon Feb 18 09:33:36 UTC 2019 - Luigi Baldoni <aloisio@gmx.com>
- Update to version 1.3.1
* Fix google benchmark link error when compiling the
bechmarks. Thanks @myd7349 (#961, f4c737e)
* Fix spdlog not printing message if SPDLOG_NO_THREAD_ID is
defined. Thanks @scribam (#970, f4c737e)
* Fix depending on the order of inclusion of spdlog.h. Thanks
@gocarlos (#959, 23fdc0e)
Version 1.3.0
Improvements:
* Upgraded to the latest and greatest fmt library version
5.3.0.
* New API for default logger spdlog::trace(..),
spdlog::debug(..), spdlog::info(..), etc.
For convenience, spdlog now creates a default global logger
(to stdout, colored and multithreaded).
It can be used easily by calling spdlog::info(..),
spdlog::debug(..), etc directly without any preparations.
Its instance can be replaced to any other logger
(shared_ptr):
spdlog::set_default_logger(some_other_logger);
spdlog::info("Use the new default logger");
* Alignment support in log patterns.
Each pattern flag can be aligned by prepending a width
number(upto 128).
Use-(left align) or = (center align) to control the align
side:
align meaning example result
%<width><flag> Align to the right %8l " info"
%-<width><flag> Align to the left %-8l "info "
%=<width><flag> Align to the center %=8l " info "
* Support for logging source filename, line number, and
function name (thanks @possiblyhuman for contributing to this
effort)
flag meaning example
%@ Source file and line (use
SPDLOG_TRACE(..),SPDLOG_INFO(...) etc.) my_file.cpp:123
%s Source file (use SPDLOG_TRACE(..),
SPDLOG_INFO(...) etc.) my_file.cpp
%# Source line (use SPDLOG_TRACE(..),
SPDLOG_INFO(...) etc.) 123
%! Source function (use SPDLOG_TRACE(..),
SPDLOG_INFO(...) etc. see tweakme for
pretty-print) my_func
* Support for compile time check of log levels using
#define SPDLOG_ACTIVE_LEVEL <level>.
Use LOG_TRACE(..), LOG_DEBUG(..), LOG_INFO(..), etc. to
enable.
Those macros check at compile time the log level and
translate to empty statement if the log level is not high
enough. Even if a log macro evaluate to a log call, the
macro will check at runtime the level before evaluating
its arguments.
So for example the following won't evaluate
some_costly_function() because the logger's level is error:
#define SPDLOG_ACTIVE_LEVEL SPDLOG_LEVEL_DEBUG
#include "spdlog/spdlog.h"
..
spdlog::set_level(error);
SPDLOG_DEBUG("Some costly arg: {}",
some_costly_function());
* CMake improvements. Thanks @dpacbach (85b4d7c, f5dc166 ).
* Numerous small performance optimizations.
* Global option that disables global registration of loggers
set_automatic_registration(bool). Thanks @pabloariasal
(#892).
* Optimize logging of C strings by using string_view to avoid
unnecessary copy. Thanks @peergynt (cb71fea).
* Use google benchmark to test latencies.
Fixes:
* logger::error_handler() should be const (#881, thanks
@shoreadmin for reporting)
* Cleanup header file: remove log_msg.h include from
fmt_helper.h. Thanks @peergynt (1b391cc)
* Fix log_msg constructor doesn't initialize all fields (#888.
Thanks @curiouserrandy for reporting).
* Change log_msg&& to log_msg& params. Thanks @rwen2012
(794a636)
* Fix typo in Android example. Thanks @ZaMaZaN4iK (f5a2725)
* Fix Compiling error VS2017 #902 (Thanks @JaNurz for
reporting).
* Fix thread id is prefixed with zeros #908 (Thanks
@klrakiranpradeep for reporting).
* Fix and optimize usage of fmt::internal::count_digits(..)
for better support 32/64 bits. Thanks @DanielChabrowski
(c7f42d1, f1ab6fe).
* Better handling of rotation errors (b64e446).
* Do not attempt to default operator= when it is implicitly
deleted. Thanks @dpacbach (63a475d).
* Make an implicit cast from int --> uint32_t explicit. Thanks
@dpacbach (a6152eb).
* Enable testing in the Travis config file. Thanks @dpacbach
(f5dc166).
* Fix the text alignment in the example. Thanks @bzindovic
(d6086da4856df510657ffe4ef6b894e902b4b83).
* Fix typos. Thanks @peergynt (ce8cf1e).
* Fix handling of external fmt lib in cmake. Thanks @cneumann
(084bc72).
* Fix typo in file_helper.h. Thanks @brridder (fb702f9).
- Use system fmt library
------------------------------------------------------------------- -------------------------------------------------------------------
Mon Dec 3 12:03:20 UTC 2018 - Michał Rostecki <mrostecki@suse.de> Mon Dec 3 12:03:20 UTC 2018 - Michał Rostecki <mrostecki@suse.de>
- Update to version 1.2.1: - Update to version 1.2.1:
* Fix a compilation error of dist_sink.h * Fix a compilation error of dist_sink.h
-------------------------------------------------------------------
Sat Nov 17 10:27:21 UTC 2018 - Luigi Baldoni <aloisio@gmx.com>
- Update to version 1.2.1
* This fixes a compilation error of dist_sink.h (#864) .
Thanks @DimRochette !
Version 1.2.0
Improvements:
* Upgraded to latest fmt version 5.2.1.
* Binary data logging using spdlog::to_hex(binary_data). Many
types of std::container<char> can be logged in hex. See usage
examples.
* Added logger->clone() to ease the creation of new loggers
from an existing one.
* Numerous micro optimizations across the lib.
* Added set_sinks method to dist_sink for atomic updating set
of sinks in dist_sink. Thanks @jwnimmer-tri .
* Improved CmakeLists.txt to better handle third-party usage.
Thanks @taketwo .
Fixes:
* Fixed wchar logging (supported only in windows. #851 , #764).
* Fixed registry test. Thanks @DanielChabrowski .
* Removed invalid files from tests.sln. Thanks @yhchen .
* Some fixes to console_globals.h includes. Thanks
@DanielChabrowski
* Don't deny access to log files from other processes under
windows. Thanks @eruiz.
* Pessimizing move remove. Thanks @maciekgajewski
* ansicolor_sink.h - add missing sink include. Thanks
@AlexanderDalshov .
* Improved rotating sink error handling.
* Fixed Readme. Thanks @blackball .
* Fixed some clang tidy warnings.
------------------------------------------------------------------- -------------------------------------------------------------------
Thu Aug 16 11:22:45 UTC 2018 - mpluskal@suse.com Thu Aug 16 11:22:45 UTC 2018 - mpluskal@suse.com

View File

@ -1,7 +1,7 @@
# #
# spec file for package spdlog # spec file for package spdlog
# #
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
# #
# All modifications and additions to the file contributed by third parties # All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed # remain the property of their copyright owners, unless otherwise agreed
@ -17,16 +17,18 @@
Name: spdlog Name: spdlog
Version: 1.2.1 Version: 1.3.1
Release: 0 Release: 0
Summary: C++ header only logging library Summary: C++ header only logging library
License: MIT License: MIT
Group: Development/Languages/C and C++ Group: Development/Languages/C and C++
URL: https://github.com/gabime/spdlog URL: https://github.com/gabime/spdlog
Source0: https://github.com/gabime/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz Source0: https://github.com/gabime/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires: benchmark-devel >= 1.4.0
BuildRequires: cmake BuildRequires: cmake
BuildRequires: gcc-c++ BuildRequires: gcc-c++ >= 8
BuildRequires: pkgconfig BuildRequires: pkgconfig
BuildRequires: pkgconfig(fmt)
%description %description
This is a packaged version of the gabime/spdlog header-only C++ This is a packaged version of the gabime/spdlog header-only C++
@ -36,6 +38,7 @@ logging library available at Github.
Summary: Development files for %{name} Summary: Development files for %{name}
Group: Development/Languages/C and C++ Group: Development/Languages/C and C++
Requires: libstdc++-devel Requires: libstdc++-devel
Requires: pkgconfig(fmt)
Provides: %{name} = %{version} Provides: %{name} = %{version}
%description devel %description devel
@ -45,10 +48,10 @@ applications that use %{name}.
%prep %prep
%autosetup %autosetup
find . -name '.gitignore' -exec rm {} \; find . -name '.gitignore' -exec rm {} \;
sed -i -e "s,\r,," README.md sed -i -e "s,\r,," README.md LICENSE
%build %build
%cmake %cmake -DSPDLOG_FMT_EXTERNAL=ON
%make_jobs %make_jobs
%install %install
@ -58,8 +61,12 @@ sed -i -e "s,\r,," README.md
%ctest %ctest
%files devel %files devel
%doc README.md %if 0%{?sle_version} > 120200
%license LICENSE %license LICENSE
%else
%doc LICENSE
%endif
%doc README.md
%{_includedir}/%{name} %{_includedir}/%{name}
%{_libdir}/cmake/%{name} %{_libdir}/cmake/%{name}
%{_libdir}/pkgconfig/%{name}.pc %{_libdir}/pkgconfig/%{name}.pc