Accepting request 896933 from home:jengelh:branches:Base:System

- Drop old rpm constructs and sections.
- Implement shared library packaging guideline.

OBS-URL: https://build.opensuse.org/request/show/896933
OBS-URL: https://build.opensuse.org/package/show/Base:System/sysfsutils?expand=0&rev=26
This commit is contained in:
Lee Duncan 2021-06-04 00:29:31 +00:00 committed by Git OBS Bridge
parent 2866e38643
commit ef898bcffd
2 changed files with 30 additions and 27 deletions

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Wed Jun 2 13:57:08 UTC 2021 - Jan Engelhardt <jengelh@inai.de>
- Drop old rpm constructs and sections.
- Implement shared library packaging guideline.
-------------------------------------------------------------------
Tue Jun 1 18:52:15 UTC 2021 - Lee Duncan <lduncan@suse.com>

View File

@ -17,11 +17,11 @@
Name: sysfsutils
Summary: System Utilities Package / Libsysfs
License: LGPL-2.1-or-later
Group: System/Libraries
Version: 2.1.1
Release: 0
Summary: System Utilities Package / Libsysfs
License: LGPL-2.1-or-later
Group: Development/Libraries/C and C++
URL: https://github.com/linux-ras/sysfsutils
Source: sysfsutils-2_1_1.tar.gz
Provides: libsysfs
@ -29,7 +29,6 @@ BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
BuildRequires: make
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
This package's purpose is to provide a library for interfacing with the
@ -37,21 +36,23 @@ kernel's sys filesystem mounted at /sys. The library was an attempt to
create a stable interface to sysfs, but it failed. It is still provided
for the current users, but no new software should use this library.
%package -n libsysfs2
Summary: Library for interfacing with the kernel's sysfs filesystem
Group: System/Libraries
Authors:
--------
Ananth Mavinakayanahalli <ananth@in.ibm.com>
Daniel Stekloff <dsteklof@us.ibm.com>
Mohan Kumar <mohan@in.ibm.com>
%description -n libsysfs2
This package's purpose is to provide a library for interfacing with the
kernel's sys filesystem mounted at /sys. The library was an attempt to
create a stable interface to sysfs, but it failed. It is still provided
for the current users, but no new software should use this library.
%package devel
Summary: Development files for libsysfs
Group: Development/Libraries/C and C++
Requires: %{name} = %{version}
Requires: libsysfs2 = %{version}
%description devel
Libsysfs' purpose is to provide a library for interfacing with the
Libsysfs's purpose is to provide a library for interfacing with the
kernel's sys filesystem mounted at /sys. The library was an attempt to
create a stable interface to sysfs, but it failed. It is still provided
for the current users, but no new software should use this library.
@ -59,17 +60,17 @@ for the current users, but no new software should use this library.
This package contains the development files for libsysfs.
%prep
%setup -n sysfsutils-2.1.1
%autosetup -p1
%build
%global optflags %{optflags} -fcommon
autoreconf -fi
%configure --disable-static --with-pic
%{__make} %{?_smp_mflags}
%configure --disable-static
%make_build
%install
make install DESTDIR=%{buildroot}
%{__rm} -v %{buildroot}/%{_libdir}/libsysfs.la
%make_install
rm -v %{buildroot}/%{_libdir}/libsysfs.la
# don't install the tools
rm -f %{buildroot}/%{_bindir}/dlist_test
rm -f %{buildroot}/%{_bindir}/get_device
@ -77,27 +78,23 @@ rm -f %{buildroot}/%{_bindir}/get_driver
rm -f %{buildroot}/%{_bindir}/get_module
rm -f %{buildroot}/%{_bindir}/testlibsysfs
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%clean
rm -rf $RPM_BUILD_ROOT
%post -n libsysfs2 -p /sbin/ldconfig
%postun -n libsysfs2 -p /sbin/ldconfig
%files
%defattr(-,root,root)
/usr/bin/systool
%{_bindir}/systool
%{_mandir}/man1/systool.1.gz
%files -n libsysfs2
%{_libdir}/libsysfs.so.*
%{_libdir}/pkgconfig/libsysfs.pc
%doc README
%license COPYING
%files devel
%defattr(-,root,root)
%dir %{_includedir}/sysfs
%{_includedir}/sysfs/libsysfs.h
%{_includedir}/sysfs/dlist.h
%{_libdir}/libsysfs.so
%{_libdir}/pkgconfig/libsysfs.pc
%changelog