Blob Blame History Raw
%global	project_name	idxd-config

Name:		accel-config
Release:	1%{?dist}
Summary:	Configure accelerator subsystem devices
# The entire source code is under GPLv2 except for accel-config
# library which is mostly LGPLv2, ccan/list which is BSD-MIT and
# the rest of ccan which is CC0.
License:	GPLv2 and LGPLv2+ and MIT and CC0
Source0:	%{URL}/archive/%{name}-v%{version}.tar.gz
Patch0: 0001-testing-vercheck.patch

Requires:	%{name}-libs%{?_isa} = %{version}-%{release}
BuildRequires:	gcc
BuildRequires:	autoconf
BuildRequires:	asciidoc
BuildRequires:	xmlto
BuildRequires:	automake
BuildRequires:	libtool
BuildRequires:	pkgconfig
BuildRequires:	pkgconfig(libkmod)
BuildRequires:	pkgconfig(uuid)
BuildRequires:	pkgconfig(json-c)
BuildRequires:	pkgconfig(libudev)
BuildRequires:	systemd

# accel-config is for configuring Intel DSA (Data-Streaming
# Accelerator) subsystem in the Linux kernel. It supports x86 only.
ExclusiveArch:	%{ix86} x86_64

Utility library for configuring the accelerator subsystem.

%package devel
Summary:	Development files for libaccfg
License:	LGPLv2+
Requires:	%{name}-libs%{?_isa} = %{version}-%{release}

%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.

%package libs
Summary:	Configuration library for accelerator subsystem devices
# All source code of configuration library is LGPLv2, except
# ccan/list which is BSD-MIT and the rest of ccan/ which is CC0.
License:	LGPLv2+ and MIT and CC0
Requires:	%{name}%{?_isa} = %{version}-%{release}

%description libs
Libraries for %{name}.

%package test
Summary:        Tests for accel-config
License:        GPLv2
Requires:       %{name}-libs%{?_isa} = %{version}-%{release}

%description test
Tests for accel-config command.

%autosetup -p1 -n %{project_name}-%{name}-v%{version}

echo %{version} > version
%configure --disable-static --disable-silent-rules --enable-test

find $RPM_BUILD_ROOT -name '*.la' -exec rm -f {} ';'

make check

%license Documentation/COPYING licenses/BSD-MIT licenses/CC0
%license licenses/accel-config-licenses LICENSE_GPL_2_0

%files libs
%license Documentation/COPYING licenses/BSD-MIT licenses/CC0
%license licenses/libaccel-config-licenses accfg/lib/LICENSE_LGPL_2_1

%files devel
%license Documentation/COPYING

%files test
%license Documentation/COPYING LICENSE_GPL_2_0
#%doc test/

* Sun Apr 03 2022 Jerry Snitselaar <> -
- Rebase to release.
resolves: rhbz#2040076

* Thu Sep 09 2021 Jerry Snitselaar <> - 3.4.2-1
- Rebase to 3.4.2 and add test subpackage.
resolves: rhbz#1971910

* Tue May 18 2021 Jerry Snitselaar <> - 3.1-1
- Rebase to 3.1 release.
resolves: rhbz#1920762

* Fri Nov 6 2020 Yunying Sun <> - 2.8-1
- Initial Packaging