File libmpsse.spec of Package libmpsse

#
# spec file for package libmpsse
#
# Copyright (c) 2017 Frank Kunz
#
# 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.

%global _lto_cflags %{?_lto_cflags} -ffat-lto-objects
Name:           libmpsse
Version:        1464883061.a2eafa2
Release:        0
Summary:        SPI/I2C control via FTDI chips
License:        BSD-2-Clause
Group:          Hardware/Other
Url:            https://github.com/devttys0/libmpsse
Source0:        %{name}-%{version}.tar.gz
BuildRequires:  libftdi0-devel

%description
Open source library for SPI/I2C control via FTDI chips.

%package devel
Summary:        Header files and static libraries for %{name}
Group:          System/Libraries
Group:          Development/Libraries/C and C++
Requires:       %{name} = %{version}

%description devel
Header files and static libraries for %{name}.
Open source library for SPI/I2C control via FTDI chips.

%prep
%autosetup -p1

%build
cd src
%configure --disable-python
make %{?_smp_mflags}

%install
cd src
%make_install
chmod +x %{buildroot}%{_libdir}/libmpsse.so

%check

%post -n %{name} -p /sbin/ldconfig
%postun -n %{name} -p /sbin/ldconfig

%files -n %{name}
%defattr(-,root,root)
%{_libdir}/libmpsse.so

%files devel
%defattr(-,root,root)
%{_libdir}/libmpsse.a
%{_includedir}/mpsse.h

%changelog
openSUSE Build Service is sponsored by