SHA256
1
0
forked from pool/spdlog
spdlog/spdlog.spec
Bernd Ritter caf0b5ff53 - Update to version 1.11.0
* Update to fmt lib version 9.1.0 #2346, #2485, #2512, #2517 . Thanks @sylveon, @YunchengLiu, @tt4g, @tycho and @vitaut
  * Fix template instantiation warning #2336 . Thanks @aengusjiang
  * Event handlers improvements #2342, #2375 . Thanks @espkk and @kslattery
  * Allow modifying the used Android buffer ID #2358. Thanks @tiolan
  * Fix clone in async test #2364. Thanks @stkw0
  * Custom formatter optimization #2365. Thanks @conr2d
  * Fix C++14 builds for gcc 4.x (#2333) #2372 . Thanks @kslattery
  * Add minor version to CMake's SOVERSION #2376
  * Allow compilation with FMT_ENFORCE_COMPILE_STRING #2381. Thanks @john4744
  * Fix pkg-config generation #2383. Thanks @alexshpilkin
  * Remove unused code from null_mutex #2385. Thanks @panzhongxian
  * Fix redundant std::move #2396. Thanks @polesapart
  * Remove the empty file if in first period in hourly logger #2386. Thanks @panzhongxian
  * Add reset_overrun_counter() function to the async logging #2399 Thanks @bergen4
  * Set C++20 in CMake when SPDLOG_USE_STD_FORMAT option is turned on #2402. Thanks @cookcocck
  * Fix mingw test #2415. Thanks @neheb
  * Support for any std::chrono::duration type in flush_every(..) #2439. Thanks @LucasChollet
  * Fix implicit casting of level_enum #2443. Thanks @ibmibmibm
  * Comment fix #2445. Thanks @Hish15
  * Fix gcc 4.x build #2449. Thanks @Simon-Janos
  * Add openSUSE installation instructions #2468. Thanks @LorenDB
  * Fixed missing include file in stopwatch.h #2434. Thanks @fabianbuettner
  * Support for omitting source info by defining SPDLOG_NO_SOURCE_LOC #2476. Thanks @nigels-com
  * Added SPDLOG_BUILD_PIC build option to CMake #2475. Thanks @nigels-com
  * Fix include windows.h #2495. Thanks @panicgh
  * Workaround gcc 12 warnings #2498, #2499 . Thanks @offa
  * Migrate to Github Actions CI #2500. Thanks @offa
  * Replace iterator difference with std::distance #2509 Thanks @kin4stat
  * Export targets file to build directory at configure time #2514, #2515. Thanks @puneetmatharu

OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/spdlog?expand=0&rev=74
2022-11-02 22:55:52 +00:00

111 lines
2.8 KiB
RPMSpec

#
# spec file for package spdlog
#
# Copyright (c) 2022 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: spdlog
%define lname libspdlog1_11
%define sover 1.11
Version: 1.11.0
Release: 0
Summary: C++ logging library
License: MIT
URL: https://github.com/gabime/spdlog
Source0: https://github.com/gabime/%{name}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
Source99: baselibs.conf
BuildRequires: cmake >= 3.10
%if 0%{?suse_version} > 1500
BuildRequires: gcc-c++ >= 8
%else
BuildRequires: gcc8-c++
%endif
BuildRequires: ninja
BuildRequires: pkgconfig
BuildRequires: (pkgconfig(catch2) >= 2.13.4 with pkgconfig(catch2) < 3)
BuildRequires: pkgconfig(fmt) >= 8.0.0
BuildRequires: pkgconfig(libsystemd)
%description
A header-only/compiled, C++ logging library.
* Asynchronous mode (optional)
* Multi/Single threaded loggers.
* Various log targets (rotating/daily files, console, with colors,
syslog, custom target)
%package devel
Summary: Header files for spdlog
Requires: %{lname} = %{version}
Requires: libstdc++-devel
Requires: pkgconfig(fmt)
%description devel
The %{name}-devel package contains C++ header files for developing
applications that use %{name}.
%package -n %{lname}
Summary: C++ logging library
%description -n %{lname}
A header-only/compiled, C++ logging library.
* Asynchronous mode (optional)
* Multi/Single threaded loggers.
* Various log targets (rotating/daily files, console, with colors,
syslog, custom target)
%prep
%autosetup -p1
find . -name .gitignore -delete
sed -i -e "s,\r,," README.md LICENSE
%build
export CXX=g++
test -x "$(type -p g++-8)" && export CXX=g++-8
%cmake -G Ninja \
-DSPDLOG_BUILD_TESTS=ON \
-DSPDLOG_BUILD_BENCH=OFF \
-DSPDLOG_FMT_EXTERNAL=ON \
-DCMAKE_BUILD_TYPE=Release \
-DSPDLOG_BUILD_EXAMPLES=OFF \
-DSPDLOG_BUILD_SHARED=ON \
..
%ninja_build
%install
%ninja_install -C build
%check
export LD_LIBRARY_PATH="$PWD/build"
%ctest
%post -n %{lname} -p /sbin/ldconfig
%postun -n %{lname} -p /sbin/ldconfig
%files devel
%license LICENSE
%doc README.md
%{_includedir}/spdlog/
%{_libdir}/libspdlog.so
%{_libdir}/cmake/spdlog/
%{_libdir}/pkgconfig/spdlog.pc
%files -n %{lname}
%{_libdir}/libspdlog.so.*
%changelog