File input-utils.spec of Package input-utils
#
# spec file for package input-utils (Version 2007.06.22)
#
# Copyright (c) 2010 SUSE LINUX Products 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/
#
# norootforbuild
Name: input-utils
BuildRequires: SDL-devel linux-kernel-headers
PreReq: %fillup_prereq
Version: 2007.06.22
Release: 167
Provides: joystick
Obsoletes: joystick
Group: Hardware/Joystick
License: GPL-2.0+
Url: http://linuxconsole.sourceforge.net/input/input.html
Summary: A Set of Utilities for Input Devices
Source: %{name}-%{version}.tar.bz2
Source1: inputattach.init
Source2: inputattach.sysconfig
Patch0: %{name}-makefile.patch
Patch1: %{name}-on_exit.patch
Patch2: %{name}-dtor.patch
Patch3: %{name}-absset.patch
Patch4: %{name}-eviocgbit.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%define programs absset evtest ffcfstress ffmvforce ffset fftest inputattach jscal jstest
%description
Utilities for input devices. It includes joystick testing and
calibration, force feedback testing, and generic event tools.
Authors:
--------
Vojtech Pavlik <vojtech@suse.cz>
%prep
%setup -q -n utils
%patch0
%patch1
%patch2
%patch3
%patch4
%build
# This package failed when testing with -Wl,-as-needed being default.
# So we disable it here, if you want to retest, just delete this comment and the line below.
export SUSE_ASNEEDED=0
make CFLAGS="$RPM_OPT_FLAGS -Wall" PROGRAMS="%{programs}"
%install
install -m 0755 -d $RPM_BUILD_ROOT%{_bindir}
install -m 0755 -t $RPM_BUILD_ROOT%{_bindir} %{programs}
# init script
install -D -m 0755 %{SOURCE1} $RPM_BUILD_ROOT%{_sysconfdir}/init.d/inputattach
mkdir -p $RPM_BUILD_ROOT%{_sbindir}
ln -sf %{_sysconfdir}/init.d/inputattach $RPM_BUILD_ROOT%{_sbindir}/rcinputattach
# sysconfig
install -D -m 700 %{SOURCE2} $RPM_BUILD_ROOT/var/adm/fillup-templates/sysconfig.inputattach-%{name}
%clean
rm -rf $RPM_BUILD_ROOT
%post
%{fillup_only -an inputattach}
%files
%defattr(-,root,root)
%{_bindir}/*
%{_sysconfdir}/init.d/inputattach
%{_sbindir}/rcinputattach
/var/adm/fillup-templates/sysconfig.inputattach-%{name}
%changelog