0e22be
%global __remake_config 1
0e22be
0e22be
Name:    opensm
0e22be
Version: 3.3.24
0e22be
Release: 2%{?dist}
0e22be
Summary: OpenIB InfiniBand Subnet Manager and management utilities
0e22be
License: GPLv2 or BSD
0e22be
Url:     https://github.com/linux-rdma/opensm
0e22be
0e22be
Source0: https://github.com/linux-rdma/opensm/releases/download/%{version}/%{name}-%{version}.tar.gz
0e22be
Source2: opensm.logrotate
0e22be
Source4: opensm.sysconfig
0e22be
Source5: opensm.service
0e22be
Source6: opensm.launch
0e22be
Source7: opensm.rwtab
0e22be
Source8: opensm.partitions
0e22be
0e22be
BuildRequires: make
0e22be
BuildRequires:  gcc
0e22be
BuildRequires: libibumad-devel, systemd, systemd-units
0e22be
BuildRequires: bison, flex, byacc
0e22be
%if %{__remake_config}
0e22be
BuildRequires: libtool, autoconf, automake
0e22be
%endif
0e22be
Requires: %{name}-libs%{?_isa} = %{version}-%{release}, logrotate, rdma
0e22be
Requires(post): systemd
0e22be
Requires(preun): systemd
0e22be
Requires(postun): systemd
0e22be
# RDMA is not currently built on 32-bit ARM: #1484155
0e22be
ExcludeArch: s390 %{arm}
0e22be
0e22be
%description
0e22be
OpenSM is the OpenIB project's Subnet Manager for Infiniband networks.
0e22be
The subnet manager is run as a system daemon on one of the machines in
0e22be
the infiniband fabric to manage the fabric's routing state.  This package
0e22be
also contains various tools for diagnosing and testing Infiniband networks
0e22be
that can be used from any machine and do not need to be run on a machine
0e22be
running the opensm daemon.
0e22be
0e22be
%package libs
0e22be
Summary: Libraries used by opensm and included utilities
0e22be
0e22be
%description libs
0e22be
Shared libraries for Infiniband user space access
0e22be
0e22be
%package devel
0e22be
Summary: Development files for the opensm-libs libraries
0e22be
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
0e22be
0e22be
%description devel
0e22be
Development environment for the opensm libraries
0e22be
0e22be
%package static
0e22be
Summary: Static version of the opensm libraries
0e22be
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
0e22be
%description static
0e22be
Static version of opensm libraries
0e22be
0e22be
%prep
0e22be
%setup -q
0e22be
0e22be
%build
0e22be
%if %{__remake_config}
0e22be
./autogen.sh
0e22be
%endif
0e22be
%configure --with-opensm-conf-sub-dir=rdma
0e22be
%make_build
0e22be
cd opensm
0e22be
./opensm -c ../opensm-%{version}.conf
0e22be
0e22be
%install
0e22be
%make_install
0e22be
# remove unpackaged files from the buildroot
0e22be
rm -f %{buildroot}%{_libdir}/*.la
0e22be
rm -fr %{buildroot}%{_sysconfdir}/init.d
0e22be
install -D -m644 opensm-%{version}.conf %{buildroot}%{_sysconfdir}/rdma/opensm.conf
0e22be
install -D -m644 %{SOURCE2} %{buildroot}%{_sysconfdir}/logrotate.d/opensm
0e22be
install -D -m644 %{SOURCE4} %{buildroot}%{_sysconfdir}/sysconfig/opensm
0e22be
install -D -m644 %{SOURCE5} %{buildroot}%{_unitdir}/opensm.service
0e22be
install -D -m755 %{SOURCE6} %{buildroot}%{_libexecdir}/opensm-launch
0e22be
install -D -m644 %{SOURCE7} %{buildroot}%{_sysconfdir}/rwtab.d/opensm
0e22be
install -D -m644 %{SOURCE8} %{buildroot}%{_sysconfdir}/rdma/partitions.conf
0e22be
mkdir -p ${RPM_BUILD_ROOT}/var/cache/opensm
0e22be
0e22be
%post
0e22be
%systemd_post opensm.service
0e22be
0e22be
%preun
0e22be
%systemd_preun opensm.service
0e22be
0e22be
%postun
0e22be
if [ -d /var/cache/opensm ]; then
0e22be
	rm -fr /var/cache/opensm
0e22be
fi
0e22be
%systemd_postun_with_restart opensm.service
0e22be
0e22be
%ldconfig_scriptlets libs
0e22be
0e22be
%files
0e22be
%dir /var/cache/opensm
0e22be
%{_sbindir}/*
0e22be
%{_mandir}/*/*
0e22be
%{_unitdir}/*
0e22be
%{_libexecdir}/*
0e22be
%config(noreplace) %{_sysconfdir}/logrotate.d/opensm
0e22be
%config(noreplace) %{_sysconfdir}/rdma/opensm.conf
0e22be
%config(noreplace) %{_sysconfdir}/rdma/partitions.conf
0e22be
%config(noreplace) %{_sysconfdir}/sysconfig/opensm
0e22be
%{_sysconfdir}/rwtab.d/opensm
0e22be
%doc AUTHORS ChangeLog INSTALL README NEWS
0e22be
%license COPYING
0e22be
0e22be
%files libs
0e22be
%{_libdir}/lib*.so.*
0e22be
0e22be
%files devel
0e22be
%{_libdir}/lib*.so
0e22be
%{_includedir}/infiniband
0e22be
0e22be
%files static
0e22be
%{_libdir}/lib*.a
0e22be
0e22be
%changelog
0e22be
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 3.3.24-2
0e22be
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
0e22be
  Related: rhbz#1991688
0e22be
0e22be
* Wed Jun 16 2021 Honggang Li <honli@redhat.com> - 3.3.24-1
0e22be
- Rebase opensm to latest upstream release 3.3.24
0e22be
- Resolves: bz1961963
0e22be
0e22be
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 3.3.23-7
0e22be
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
0e22be
0e22be
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.23-6
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
0e22be
0e22be
* Thu Dec 10 2020 Timm Bäder <tbaeder@redhat.com> 3.3.23.5
0e22be
- Use make macros
0e22be
  https://docs.fedoraproject.org/en-US/packaging-guidelines/#_parallel_make
0e22be
0e22be
* Thu Dec 10 2020 Honggang Li <honli@redhat.com> - 3.3.23-4
0e22be
- opensm service should after rdma-hw.target
0e22be
0e22be
* Thu Oct 29 2020 Honggang Li <honli@redhat.com> -3.3.23-3
0e22be
- Update systemd service file
0e22be
0e22be
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.23-2
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
0e22be
0e22be
* Mon Mar 16 2020 Honggang Li <honli@redhat.com> - 3.3.23-1
0e22be
- Rebase opensm to latest upstream release 3.3.23
0e22be
- Resolves: bz1813779
0e22be
0e22be
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.22-3
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
0e22be
0e22be
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.22-2
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
0e22be
0e22be
* Wed Apr 17 2019 Honggang Li <honli@redhat.com> - 3.3.22-1
0e22be
- Rebase opensm to latest upstream release 3.3.22
0e22be
- Resolves: bz1700766
0e22be
0e22be
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.21-3
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
0e22be
0e22be
* Mon Jan 21 2019 Honggang Li <honli@redhat.com> - 3.3.21-2
0e22be
- Restore the subnet prefix patch
0e22be
- Resolves: bz1663785
0e22be
0e22be
* Mon Oct  8 2018 Honggang Li <honli@redhat.com> - 3.3.21-1
0e22be
- Rebase opensm to latest upstream release 3.3.21
0e22be
- Resolves: bz1637260
0e22be
0e22be
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.20-9
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
0e22be
0e22be
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.20-8
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
0e22be
0e22be
* Thu Feb  1 2018 Honggang Li <honli@redhat.com> - 3.3.20-7
0e22be
- Fix BuildRequires
0e22be
- Fix preuninstall script
0e22be
- Resolves: bz1540934
0e22be
0e22be
* Mon Aug 28 2017 Honggang Li <honli@redhat.com> - 3.3.20-6
0e22be
- Add support for s309x
0e22be
0e22be
* Sat Aug 26 2017 Honggang Li <honli@redhat.com> - 3.3.20-5
0e22be
- Disable support for ARM32.
0e22be
- Resolves: bz1484155
0e22be
0e22be
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.20-4
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
0e22be
0e22be
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.20-3
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
0e22be
0e22be
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.20-2
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
0e22be
0e22be
* Fri Jun 10 2016 Honggang Li <honli@redhat.com> - 3.3.20-1
0e22be
- Update to latest upstream release
0e22be
- Resolves: bz1344691
0e22be
0e22be
* Wed Mar 16 2016 Doug Ledford <dledford@redhat.com> - 3.3.19-1
0e22be
- Update to latest upstream release
0e22be
- Incorporate features from RHEL opensm
0e22be
- Resolves: bz1124202
0e22be
0e22be
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.3.17-6
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
0e22be
0e22be
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.17-5
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
0e22be
0e22be
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.17-4
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
0e22be
0e22be
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.17-3
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
0e22be
0e22be
* Thu May 29 2014 Michael Schwendt <mschwendt@fedoraproject.org> - 3.3.17-2
0e22be
- Don't include manual page directories (#1089412).
0e22be
- Use standard group Development/Libraries in library devel packages.
0e22be
- Use %%?_isa in base package dependencies.
0e22be
0e22be
* Mon Mar 17 2014 Peter Robinson <pbrobinson@fedoraproject.org> 3.3.17-1
0e22be
- Update to 3.3.17
0e22be
0e22be
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.15-7
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
0e22be
0e22be
* Mon Mar 25 2013 Doug Ledford <dledford@redhat.com> - 3.3.15-6
0e22be
- Oops, forgot to remove the -B option to opensm when starting it
0e22be
0e22be
* Mon Mar 25 2013 Doug Ledford <dledford@redhat.com> - 3.3.15-5
0e22be
- Drop the old sysv init script
0e22be
- Fix opensm-launch to restart opensm in a loop.  This works around the
0e22be
  fact that systemd starts opensm so early that we very well might not have
0e22be
  sync on the link yet.  Without the physical link being up, opensm exits
0e22be
  immediately.  This way opensm will get restarted every 30 seconds until
0e22be
  sync is active on the link or until the opensm service is stopped.
0e22be
- Always install the newly generated opensm-%%{version}.conf as opensm.conf
0e22be
- Make the launch work properly in the event that no GUIDs are set and
0e22be
  there are no numbered config files
0e22be
0e22be
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.15-4
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
0e22be
0e22be
* Wed Dec 05 2012 Doug Ledford <dledford@redhat.com> - 3.3.15-3
0e22be
- Fix startup on read only root
0e22be
- Update default config file
0e22be
- Resolves: bz817591
0e22be
0e22be
* Wed Dec 05 2012 Doug Ledford <dledford@redhat.com> - 3.3.15-2
0e22be
- More tweaks to systemd setup (proper scriptlets now)
0e22be
- More tweaks to old sysv init script support (fix Requires)
0e22be
0e22be
* Tue Nov 27 2012 Doug Ledford <dledford@redhat.com> - 3.3.15-1
0e22be
- Update to latest upstream release
0e22be
- Update to systemd startup
0e22be
0e22be
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.13-3
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
0e22be
0e22be
* Tue Mar 13 2012 Doug Ledford <dledford@redhat.com> - 3.3.13-2
0e22be
- Fix the config file comment in the opensm init script
0e22be
- Resolves: bz802727
0e22be
0e22be
* Tue Feb 28 2012 Doug Ledford <dledford@redhat.com> - 3.3.13-1
0e22be
- Update to latest upstream version
0e22be
- Fix a minor issue in init scripts that would cause systemd to try and
0e22be
  start/stop things in the wrong order
0e22be
- Add a patch to allow us to specify the subnet prefix on the command line
0e22be
0e22be
* Tue Jan 03 2012 Doug Ledford <dledford@redhat.com> - 3.3.12-1
0e22be
- Update to latest upstream version
0e22be
0e22be
* Mon Aug 15 2011 Kalev Lember <kalevlember@gmail.com> - 3.3.9-2
0e22be
- Rebuilt for rpm bug #728707
0e22be
0e22be
* Wed Jul 20 2011 Doug Ledford <dledford@redhat.com> - 3.3.9-1
0e22be
- Update to latest upstream version
0e22be
- Add /etc/sysconfig/opensm for use by opensm init script
0e22be
- Enable the ability to start more than one instance of opensm for multiple
0e22be
  fabric support
0e22be
- Enable the ability to start opensm with a priority other than default for
0e22be
  support of backup opensm instances
0e22be
0e22be
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.5-2
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
0e22be
0e22be
* Mon Mar 08 2010 Doug Ledford <dledford@redhat.com> - 3.3.5-1
0e22be
- Update to latest upstream release.  We need various defines in ib_types.h
0e22be
  for the latest ibutils package to build properly, and the latest ibutils
0e22be
  package is needed because we found licensing problems in the older
0e22be
  tarballs during review.
0e22be
0e22be
* Mon Jan 11 2010 Doug Ledford <dledford@redhat.com> - 3.3.3-2
0e22be
- ExcludeArch s390(x) as there's no hardware support there
0e22be
0e22be
* Thu Dec 03 2009 Doug Ledford <dledford@redhat.com> - 3.3.3-1
0e22be
- Update to latest upstream release
0e22be
- Minor tweaks to init script for LSB compliance
0e22be
0e22be
* Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.3.2-2
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
0e22be
0e22be
* Mon Jul 20 2009 Doug Ledford <dledford@redhat.com> - 3.3.2-1
0e22be
- Update to latest upstream version
0e22be
0e22be
* Wed Apr 22 2009 Doug Ledford <dledford@redhat.com> - 3.3.1-1
0e22be
- Update to latest upstream version
0e22be
0e22be
* Fri Mar 06 2009 Caolán McNamara <caolanm@redhat.com> - 3.2.1-3
0e22be
- fix bare elifs to rebuild
0e22be
0e22be
* Thu Feb 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 3.2.1-2
0e22be
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
0e22be
0e22be
* Sun Jun 08 2008 Doug Ledford <dledford@redhat.com> - 3.2.1-1
0e22be
- Initial package for Fedora review process