File it87.spec of Package it87
#
# spec file for package it87
#
# Copyright (c) 2019 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 https://bugs.opensuse.org/
#
Name: it87
Version: 1.0.125
Release: 0
Summary: Kernel module for IT8[67]xxxx Super-I/O chips
License: GPL-2.0-only
Group: System/Kernel
URL: https://github.com/frankcrawford/it87
Source0: %{name}-%{version}.tar.xz
Source1: %{name}-kmp-preamble
Source2: 70-it87.conf
BuildRequires: %{kernel_module_package_buildreqs}
%kernel_module_package -p %{name}-kmp-preamble default
%description
This driver implements support for the IT8603E, IT8620E, IT8622E, IT8623E,
IT8628E, IT8705F, IT8712F, IT8716F, IT8718F, IT8720F, IT8721F, IT8726F, IT8728F,
IT8732F, IT8758E, IT8771E, IT8772E, IT8781F, IT8782F, IT8783E/F, IT8786E,
IT8790E, and SiS950 chips.
%package KMP
Summary: Kernel module for IT8[67]xxxx Super-I/O chips
Group: System/Kernel
Provides: multiversion(kernel)
%description KMP
This driver implements support for the IT8603E, IT8620E, IT8622E, IT8623E,
IT8628E, IT8705F, IT8712F, IT8716F, IT8718F, IT8720F, IT8721F, IT8726F, IT8728F,
IT8732F, IT8758E, IT8771E, IT8772E, IT8781F, IT8782F, IT8783E/F, IT8786E,
IT8790E, and SiS950 chips.
%prep
%setup -q
sed -i "s/<unknown>/%{version}/" Makefile
set -- *
mkdir source
mv "$@" source/
mkdir obj
%build
for flavor in %{flavors_to_build}; do
rm -rf obj/$flavor
cp -r source obj/$flavor
make %{?_smp_mflags} -C %{kernel_source $flavor} %{?linux_make_arch} \
modules M=$PWD/obj/$flavor
done
%install
export INSTALL_MOD_PATH=%{buildroot}
export INSTALL_MOD_DIR="updates"
for flavor in %{flavors_to_build}; do
make -C %{kernel_source $flavor} modules_install M=$PWD/obj/$flavor
done
install -m 0644 -D -t %{buildroot}%{_sysconfdir}/modprobe.d/ %{SOURCE2}
%files
%dir %{_sysconfdir}/modprobe.d
%config(noreplace) %{_sysconfdir}/modprobe.d/70-it87.conf
%changelog