Blame SPECS/sid.spec

4b6366
#global commit 13a0dd86874b5d7558a0e131f3deaa42cd7d9d23
4b6366
%{?commit:%global shortcommit %(c=%{commit}; echo ${c:0:7})}
4b6366
%{?commit:%global commitdate 20200828}
4b6366
%{?commit:%global scmsnap %{commitdate}git%{shortcommit}}
4b6366
4b6366
%global enable_dm_mpath_support 1
4b6366
4b6366
##############################################################################
4b6366
# SID
4b6366
##############################################################################
4b6366
4b6366
Name: sid
4b6366
%if 0%{?rhel}
4b6366
Epoch: %{rhel}
4b6366
%endif
4b6366
Version: 0.0.4
4b6366
Release: 6%{?scmsnap:.%{scmsnap}}%{?dist}
4b6366
Summary: Storage Instantiation Daemon (SID)
4b6366
4b6366
License: GPLv2+
4b6366
URL: http://sid-project.github.io
4b6366
%if %{defined commit}
4b6366
Source0: https://github.com/sid-project/%{name}/archive/%{commit}/%{name}-%{shortcommit}.tar.gz
4b6366
%else
4b6366
Source0: https://github.com/sid-project/%{name}/archive/v%{version}/%{name}-%{version}.tar.gz
4b6366
%endif
4b6366
4b6366
Patch0: sid-0-0-5-modules-ucmd-dm_mpath-sync-with-mpath_valid-changes.patch
4b6366
4b6366
BuildRequires: make
4b6366
BuildRequires: autoconf
4b6366
BuildRequires: automake
4b6366
BuildRequires: libtool
4b6366
BuildRequires: gcc
4b6366
BuildRequires: systemd-rpm-macros
4b6366
BuildRequires: systemd-devel >= 221
4b6366
BuildRequires: libudev-devel >= 174
4b6366
BuildRequires: libuuid-devel
4b6366
BuildRequires: libblkid-devel
4b6366
%if %{enable_dm_mpath_support}
4b6366
BuildRequires: device-mapper-multipath-devel >= 0.8.4-7
4b6366
%endif
4b6366
4b6366
Requires: systemd
4b6366
Requires: systemd-udev
4b6366
Requires: %{name}-base-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-log-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-resource-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-tools = %{?epoch}:%{version}-%{release}
4b6366
4b6366
%description
4b6366
Storage Instantiation Daemon (SID) aims to help with Linux storage
4b6366
device state tracking that encompasses device layers, groups and whole
4b6366
stacks by monitoring progression of events. Based on monitored states
4b6366
and further recorded information, it is able to trigger associated
4b6366
actions for well-defined triggers, including activation and deactivation
4b6366
of devices and their layers in the stack.
4b6366
4b6366
%prep
4b6366
%if %{defined commit}
4b6366
%autosetup -p1 -n sid-%{commit}
4b6366
%else
4b6366
%autosetup -p1 -n sid-%{version}
4b6366
%endif
4b6366
4b6366
%if ! %{enable_dm_mpath_support}
4b6366
%global configure_dm_mpath --disable-mod-dm_mpath
4b6366
%endif
4b6366
4b6366
%build
4b6366
./autogen.sh
4b6366
%configure %{?configure_dm_mpath}
4b6366
%make_build
4b6366
4b6366
%install
4b6366
make DESTDIR=%{buildroot} install
4b6366
rm -f %{buildroot}/%{_libdir}/sid/*.{a,la}
4b6366
rm -f %{buildroot}/%{_libdir}/sid/modules/ucmd/block/*.{a,la}
4b6366
rm -f %{buildroot}/%{_libdir}/sid/modules/ucmd/type/*.{a,la}
4b6366
4b6366
%files
4b6366
%license COPYING
4b6366
%{_sbindir}/sid
4b6366
%config(noreplace) %{_sysconfdir}/sysconfig/sid.sysconfig
4b6366
%{_udevrulesdir}/00-sid.rules
4b6366
%{_unitdir}/sid.socket
4b6366
%{_unitdir}/sid.service
4b6366
%{_mandir}/man8/sid.8.gz
4b6366
%doc README.md
4b6366
4b6366
%post
4b6366
%systemd_post sid.socket sid.service
4b6366
4b6366
%preun
4b6366
%systemd_preun sid.service sid.socket
4b6366
4b6366
%postun
4b6366
%systemd_postun sid.service sid.socket
4b6366
4b6366
##############################################################################
4b6366
# SID-BASE-LIBS
4b6366
##############################################################################
4b6366
4b6366
%package base-libs
4b6366
Summary: Libraries for Storage Instantiation Daemon (SID) base
4b6366
License: GPLv2+
4b6366
%description base-libs
4b6366
This package contains shared libraries with low-level functionality needed for
4b6366
Storage Instantiation Daemon (SID), its modules and related tools. Currently,
4b6366
it contains basic support for bitmaps, buffering, IPC, hashing, lists, memory
4b6366
handling and other helper functions.
4b6366
4b6366
%files base-libs
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidbase.so.*
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-BASE-LIBS-DEVEL
4b6366
##############################################################################
4b6366
4b6366
%package base-libs-devel
4b6366
Summary: Development files for Storage Instantiation Daemon (SID) base
4b6366
License: GPLv2+
4b6366
Requires: %{name}-base-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
%description base-libs-devel
4b6366
This package contains development files for Storage Instantiation Daemon (SID)
4b6366
base libraries.
4b6366
4b6366
%files base-libs-devel
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidbase.so
4b6366
%dir %{_includedir}/sid
4b6366
%{_includedir}/sid/config.h
4b6366
%dir %{_includedir}/sid/base
4b6366
%{_includedir}/sid/base/bitmap.h
4b6366
%{_includedir}/sid/base/buffer-common.h
4b6366
%{_includedir}/sid/base/buffer.h
4b6366
%{_includedir}/sid/base/common.h
4b6366
%{_includedir}/sid/base/comms.h
4b6366
%{_includedir}/sid/base/list.h
4b6366
%{_includedir}/sid/base/mem.h
4b6366
%{_includedir}/sid/base/util.h
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-LOG-LIBS
4b6366
##############################################################################
4b6366
4b6366
%package log-libs
4b6366
Summary: Libraries for Storage Instantiation Daemon (SID) logging
4b6366
License: GPLv2+
4b6366
%description log-libs
4b6366
This package contains shared libraries with logging support needed for Storage
4b6366
Instantiation daemon (SID), its modules and related tools.
4b6366
4b6366
%files log-libs
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidlog.so.*
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-LOG-LIBS-DEVEL
4b6366
##############################################################################
4b6366
4b6366
%package log-libs-devel
4b6366
Summary: Development files for Storage Instantiation Daemon (SID) logging
4b6366
License: GPLv2+
4b6366
Requires: %{name}-log-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
%description log-libs-devel
4b6366
This package contains development files for Storage Instantiation Daemon (SID)
4b6366
logging libraries.
4b6366
4b6366
%files log-libs-devel
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidlog.so
4b6366
%dir %{_includedir}/sid
4b6366
%dir %{_includedir}/sid/log
4b6366
%{_includedir}/sid/log/log.h
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-IFACE-LIBS
4b6366
##############################################################################
4b6366
4b6366
%package iface-libs
4b6366
Summary: Libraries for Storage Instantiation Daemon (SID) interfaces
4b6366
License: GPLv2+
4b6366
Requires: %{name}-base-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
%description iface-libs
4b6366
This package contains shared libraries to support interfaces used in Storage
4b6366
Instantiation Daemon (SID), its modules and related tools.
4b6366
4b6366
%files iface-libs
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidiface_servicelink.so.*
4b6366
%{_libdir}/sid/libsidiface_usid.so.*
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-IFACE-LIBS-DEVEL
4b6366
##############################################################################
4b6366
4b6366
%package iface-libs-devel
4b6366
Summary: Development files for Storage Instantiation Daemon (SID) interfaces
4b6366
License: GPLv2+
4b6366
Requires: %{name}-iface-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
%description iface-libs-devel
4b6366
This package contains development files for Storage Instantiation Daemon (SID)
4b6366
interface libraries.
4b6366
4b6366
%files iface-libs-devel
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidiface_servicelink.so
4b6366
%{_libdir}/sid/libsidiface_usid.so
4b6366
%dir %{_includedir}/sid
4b6366
%dir %{_includedir}/sid/iface
4b6366
%{_includedir}/sid/iface/service-link.h
4b6366
%{_includedir}/sid/iface/usid.h
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-RESOURCE-LIBS
4b6366
##############################################################################
4b6366
4b6366
%package resource-libs
4b6366
Summary: Libraries for Storage Instantiation Daemon (SID) resources
4b6366
License: GPLv2+
4b6366
Requires: %{name}-base-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-log-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-iface-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
# Systemd supports event loop since v221
4b6366
Requires: systemd-libs >= 221
4b6366
%description resource-libs
4b6366
This package contains shared libraries to support high-level resources that
4b6366
represent hierarchical units of reusable code used in Storage Instantiation
4b6366
Daemon (SID), its modules and related tools. Currently, it contains support
4b6366
for aggregation, key-value store, module loading and registry, worker process
4b6366
control, bridging SID core and udev and creating an instance of SID as a whole.
4b6366
4b6366
%files resource-libs
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidresource.so.*
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-RESOURCE-LIBS-DEVEL
4b6366
##############################################################################
4b6366
4b6366
%package resource-libs-devel
4b6366
Summary: Development files for Storage Instantiation Daemon (SID) resources
4b6366
License: GPLv2+
4b6366
Requires: %{name}-resource-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
%description resource-libs-devel
4b6366
This package contains development files for Storage Instantiation Daemon (SID)
4b6366
resource libraries.
4b6366
4b6366
%files resource-libs-devel
4b6366
%dir %{_libdir}/sid
4b6366
%{_libdir}/sid/libsidresource.so
4b6366
%dir %{_includedir}/sid
4b6366
%dir %{_includedir}/sid/resource
4b6366
%{_includedir}/sid/resource/kv-store.h
4b6366
%{_includedir}/sid/resource/module-registry.h
4b6366
%{_includedir}/sid/resource/module.h
4b6366
%{_includedir}/sid/resource/resource-type-regs.h
4b6366
%{_includedir}/sid/resource/resource.h
4b6366
%{_includedir}/sid/resource/ucmd-module.h
4b6366
%{_includedir}/sid/resource/worker-control.h
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-TOOLS
4b6366
##############################################################################
4b6366
4b6366
%package tools
4b6366
Summary: Storage Instantiation Daemon (SID) supporting tools
4b6366
Requires: %{name}-base-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-log-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-iface-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: systemd-udev
4b6366
%description tools
4b6366
This package contains tools to support Storage Instantiation Daemon (SID).
4b6366
4b6366
4b6366
%files tools
4b6366
%{_udevrulesdir}/../usid
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-MOD-DUMMIES
4b6366
##############################################################################
4b6366
%package mod-dummies
4b6366
Summary: Dummy block and type module for Storage Instantiation Daemon (SID)
4b6366
Requires: %{name}-log-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-resource-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
%description mod-dummies
4b6366
This package contains dummy block and type modules for Storage Instantiation
4b6366
Daemon (SID). Their only purpose is to test SID module functionality and hook
4b6366
execution.
4b6366
4b6366
%files mod-dummies
4b6366
%dir %{_libdir}/sid
4b6366
%dir %{_libdir}/sid/modules/
4b6366
%dir %{_libdir}/sid/modules/ucmd
4b6366
%dir %{_libdir}/sid/modules/ucmd/block
4b6366
%dir %{_libdir}/sid/modules/ucmd/type
4b6366
%{_libdir}/sid/modules/ucmd/block/dummy_block.so
4b6366
%{_libdir}/sid/modules/ucmd/type/dummy_type.so
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-MOD-BLOCK-BLKID
4b6366
##############################################################################
4b6366
4b6366
%package mod-block-blkid
4b6366
Summary: Blkid block module for Storage Instantiation Daemon (SID)
4b6366
Requires: %{name}-log-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-resource-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
%description mod-block-blkid
4b6366
This package contains blkid block module for Storage Instantiation Daemon (SID).
4b6366
4b6366
%files mod-block-blkid
4b6366
%dir %{_libdir}/sid
4b6366
%dir %{_libdir}/sid/modules
4b6366
%dir %{_libdir}/sid/modules/ucmd
4b6366
%dir %{_libdir}/sid/modules/ucmd/block
4b6366
%{_libdir}/sid/modules/ucmd/block/blkid.so
4b6366
%doc README.md
4b6366
4b6366
4b6366
##############################################################################
4b6366
# SID-MOD-BLOCK-DM_MPATH
4b6366
##############################################################################
4b6366
4b6366
%if %{enable_dm_mpath_support}
4b6366
4b6366
%package mod-block-dm-mpath
4b6366
Summary: Device-mapper multipath block module for Storage Instantiation Daemon (SID)
4b6366
Requires: %{name}-log-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: %{name}-resource-libs%{?_isa} = %{?epoch}:%{version}-%{release}
4b6366
Requires: device-mapper-multipath-libs >= 0.8.4-7
4b6366
%description mod-block-dm-mpath
4b6366
This package contains device-mapper multipath block module for Storage
4b6366
Instantiation Daemon (SID).
4b6366
4b6366
%files mod-block-dm-mpath
4b6366
%dir %{_libdir}/sid
4b6366
%dir %{_libdir}/sid/modules
4b6366
%dir %{_libdir}/sid/modules/ucmd
4b6366
%dir %{_libdir}/sid/modules/ucmd/block
4b6366
%{_libdir}/sid/modules/ucmd/block/dm_mpath.so
4b6366
%doc README.md
4b6366
4b6366
%endif
4b6366
4b6366
4b6366
%changelog
4b6366
* Tue Aug 10 2021 Mohan Boddu <mboddu@redhat.com> - 8:0.0.4-6
4b6366
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
4b6366
  Related: rhbz#1991688
4b6366
4b6366
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 8:0.0.4-5
4b6366
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
4b6366
4b6366
* Fri Jan 29 2021 Peter Rajnoha <prajnoha@redhat.com> - 0.0.4-4
4b6366
- Add epoch to rpm spec file for RHEL-based releases.
4b6366
4b6366
* Fri Jan 29 2021 Peter Rajnoha <prajnoha@redhat.com> - 0.0.4-3
4b6366
- Sync with mpath_valid changes.
4b6366
4b6366
* Wed Jan 27 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.0.4-2
4b6366
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
4b6366
4b6366
* Tue Oct 06 2020 Peter Rajnoha <prajnoha@redhat.com> - 0.0.4-1
4b6366
- Initial release.