File xpad-noone.spec of Package xpad-noone

Name:           xpad-noone
Version:        0.1
Release:        0
Summary:        This is the original xpad kernel driver with support for Xbox One controllers removed
License:        GPL-2.0-only
Group:          System/Kernel
URL:            https://github.com/TobiPeterG/xpad-noone
Source:         xpad-noone-%version.tar.xz
BuildRequires:  %kernel_module_package_buildreqs
BuildRequires:  xz
Requires:       xone-dongle-firmware

%kernel_module_package

%description
This is the original xpad kernel driver with support for Xbox One controllers removed.
If you are running the xone driver you will have to replace the xpad kernel module with
this one to retain the functionality of Xbox and Xbox 360 controllers.

%package KMP
Summary:        This is the original xpad kernel driver with support for Xbox One controllers removed

%description KMP
This is the original xpad kernel driver with support for Xbox One controllers removed.
If you are running the xone driver you will have to replace the xpad kernel module with
this one to retain the functionality of Xbox and Xbox 360 controllers.

%prep
%autosetup -p1

%build
pushd ../
for flavor in %flavors_to_build; do
	cp -a "%name-%version" "%name-$flavor-%version"
	pushd "%name-$flavor-%version/"
	# kernel's make install is picky about flags changing/being the same between %%build and %%install
	%make_build -C "/usr/src/linux-obj/%_target_cpu/$flavor" M=$PWD KCFLAGS="-DDEBUG"
	popd
done

%install
pushd ../
for flavor in %flavors_to_build; do
	pushd "%name-$flavor-%version/"
	%make_build -C "/usr/src/linux-obj/%_target_cpu/$flavor" M=$PWD KCFLAGS="-DDEBUG" \
		INSTALL_MOD_PATH="%buildroot" modules_install
	popd
done

%changelog
openSUSE Build Service is sponsored by