71 lines
1.9 KiB
RPMSpec
71 lines
1.9 KiB
RPMSpec
|
|
%define sover 3
|
|
Name: zxing-cpp
|
|
Version: 2.3.0
|
|
Release: 0
|
|
Summary: Library for processing 1D and 2D barcodes
|
|
License: Apache-2.0 AND Zlib AND LGPL-2.1-with-Qt-Company-Qt-exception-1.1
|
|
Group: Development/Languages/C and C++
|
|
URL: https://github.com/nu-book/zxing-cpp/
|
|
Source0: %{url}/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
|
|
BuildRequires: cmake >= 3.5
|
|
BuildRequires: pkgconfig
|
|
BuildRequires: gcc
|
|
BuildRequires: gcc-c++
|
|
|
|
%description
|
|
ZXing ("zebra crossing") is an multi-format 1D/2D barcode image
|
|
processing library. This package provides a C++ implementation.
|
|
|
|
%package -n libZXing%{sover}
|
|
Summary: Library for processing 1D and 2D barcodes
|
|
# called libZXing in the 1.1.0 update
|
|
Group: System/Libraries
|
|
Provides: libZXingCore%{sover} = %{version}
|
|
Obsoletes: libZXingCore%{sover} < %{version}
|
|
|
|
%description -n libZXing%{sover}
|
|
ZXing ("zebra crossing") is an multi-format 1D/2D barcode image
|
|
processing library. This package provides a C++ implementation.
|
|
|
|
%package devel
|
|
Summary: Header files for zxing, a library for processing 1D and 2D barcodes
|
|
Group: Development/Languages/C and C++
|
|
Requires: libZXing%{sover} = %{version}
|
|
|
|
%description devel
|
|
ZXing ("zebra crossing") is an multi-format 1D/2D barcode image
|
|
processing library. This package provides header files to use ZXing in
|
|
other applications.
|
|
|
|
%prep
|
|
%autosetup -p1
|
|
|
|
%build
|
|
export CXXFLAGS="%{optflags} -std=c++17"
|
|
# Examples require QT5-base/multimedia, but doing so creates a cycle
|
|
# Blackbox tests require fmt
|
|
%cmake \
|
|
-DCMAKE_CXX_EXTENSIONS=ON \
|
|
-DBUILD_C_API=ON \
|
|
-DBUILD_EXAMPLES=OFF
|
|
%cmake_build
|
|
|
|
%install
|
|
%cmake_install
|
|
|
|
|
|
%files -n libZXing%{sover}
|
|
%doc README.md
|
|
%license LICENSE
|
|
%{_libdir}/libZXing.so.*
|
|
|
|
%files devel
|
|
%license LICENSE
|
|
%{_includedir}/ZXing/
|
|
%{_libdir}/cmake/ZXing/
|
|
%{_libdir}/libZXing.so
|
|
%{_libdir}/pkgconfig/zxing.pc
|
|
|
|
%changelog
|