File cxxopts.spec of Package cxxopts
#
# spec file for package cxxopts
#
# Copyright (c) 2020 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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 http://bugs.opensuse.org/
#
Name: cxxopts
Version: 3.3.1
Release: 0
Summary: Lightweight C++ command line option parser
License: MIT
Url: https://github.com/jarro2783/cxxopts
Source: %{name}-%{version}.tar.gz
BuildRequires: gcc-c++
BuildRequires: cmake
BuildRequires: ninja
BuildArch: noarch
%description
This is a lightweight C++ option parser library, supporting the standard GNU style syntax for options.
%package devel
Summary: Development files for %{name}
Provides: %{name}-static = %{version}
Provides: %{name} = %{version}
Requires: libstdc++-devel
%description devel
%{summary}.
%prep
%autosetup -p1
%build
%define __builder ninja
%cmake \
-DCMAKE_BUILD_TYPE=Release \
-DCXXOPTS_ENABLE_INSTALL=ON \
-DCXXOPTS_BUILD_EXAMPLES=OFF \
-DCXXOPTS_BUILD_TESTS=ON
%cmake_build
%install
%cmake_install
%files devel
%license LICENSE
%doc CHANGELOG.md README.md
%{_includedir}/%{name}.hpp
%{_datadir}/cmake/%{name}/
%{_datadir}/pkgconfig/cxxopts.pc
%changelog