Blame SPECS/os-prober.spec

a27a5b
Name:           os-prober
a27a5b
Version:        1.77
8c8245
Release:        10%{?dist}
a27a5b
Summary:        Probes disks on the system for installed operating systems
a27a5b
a27a5b
# For more information about licensing, see copyright file.
a27a5b
License:        GPLv2+ and GPL+
a27a5b
URL:            http://kitenet.net/~joey/code/os-prober/
a27a5b
Source0:        http://ftp.us.debian.org/debian/pool/main/o/os-prober/%{name}_%{version}.tar.xz
a27a5b
Patch0:         os-prober-no-dummy-mach-kernel.patch
a27a5b
# Sent upstream
a27a5b
Patch1:         os-prober-mdraidfix.patch
a27a5b
Patch2:         os-prober-btrfsfix.patch
a27a5b
Patch3:         os-prober-bootpart-name-fix.patch
a27a5b
Patch4:         os-prober-mounted-partitions-fix.patch
a27a5b
Patch5:         os-prober-factor-out-logger.patch
a27a5b
# To be sent upstream
a27a5b
Patch6:         os-prober-factored-logger-efi-fix.patch
a27a5b
Patch7:         os-prober-umount-fix.patch
a27a5b
Patch8:         os-prober-grub2-parsefix.patch
a27a5b
Patch9:         os-prober-grepfix.patch
a27a5b
Patch10:        os-prober-gentoo-fix.patch
a27a5b
Patch11:        os-prober-grub2-mount-workaround.patch
a27a5b
a27a5b
Requires:       udev coreutils util-linux
a27a5b
Requires:       grep /bin/sed /sbin/modprobe
a27a5b
Requires:       grub2-tools-minimal
a27a5b
a27a5b
BuildRequires: make
a27a5b
BuildRequires:  gcc git
a27a5b
a27a5b
%description
a27a5b
This package detects other OSes available on a system and outputs the results
a27a5b
in a generic machine-readable format. Support for new OSes and Linux
a27a5b
distributions can be added easily. 
a27a5b
a27a5b
%prep
a27a5b
%autosetup -n %{name}-%{version} -S git
a27a5b
a27a5b
find -type f -exec sed -i -e 's|usr/lib|usr/libexec|g' {} \;
a27a5b
sed -i -e 's|grub-probe|grub2-probe|g' os-probes/common/50mounted-tests \
a27a5b
     linux-boot-probes/common/50mounted-tests
a27a5b
sed -i -e 's|grub-mount|grub2-mount|g' os-probes/common/50mounted-tests \
a27a5b
     linux-boot-probes/common/50mounted-tests common.sh
a27a5b
a27a5b
%build
a27a5b
%set_build_flags
8c8245
%make_build LDFLAGS="$LDFLAGS -fPIC" CFLAGS="$CFLAGS" CPPFLAGS="$CPPFLAGS"
a27a5b
a27a5b
%install
a27a5b
install -m 0755 -d %{buildroot}%{_bindir}
a27a5b
install -m 0755 -d %{buildroot}%{_var}/lib/%{name}
a27a5b
a27a5b
install -m 0755 -p os-prober linux-boot-prober %{buildroot}%{_bindir}
a27a5b
install -m 0755 -Dp newns %{buildroot}%{_libexecdir}/os-prober/newns
a27a5b
install -m 0644 -Dp common.sh %{buildroot}%{_datadir}/%{name}/common.sh
a27a5b
a27a5b
%ifarch m68k
a27a5b
ARCH=m68k
a27a5b
%endif
a27a5b
%ifarch ppc ppc64
a27a5b
ARCH=powerpc
a27a5b
%endif
a27a5b
%ifarch sparc sparc64
a27a5b
ARCH=sparc
a27a5b
%endif
a27a5b
%ifarch %{ix86} x86_64
a27a5b
ARCH=x86
a27a5b
%endif
a27a5b
a27a5b
for probes in os-probes os-probes/mounted os-probes/init \
a27a5b
              linux-boot-probes linux-boot-probes/mounted; do
a27a5b
        install -m 755 -d %{buildroot}%{_libexecdir}/$probes 
a27a5b
        cp -a $probes/common/* %{buildroot}%{_libexecdir}/$probes
a27a5b
        if [ -e "$probes/$ARCH" ]; then 
a27a5b
                cp -a $probes/$ARCH/* %{buildroot}%{_libexecdir}/$probes 
a27a5b
        fi
a27a5b
done
a27a5b
if [ "$ARCH" = x86 ]; then
a27a5b
        install -m 755 -p os-probes/mounted/powerpc/20macosx \
a27a5b
            %{buildroot}%{_libexecdir}/os-probes/mounted
a27a5b
fi
a27a5b
a27a5b
%files
a27a5b
%doc README TODO debian/changelog
a27a5b
%license debian/copyright
a27a5b
%{_bindir}/*
a27a5b
%{_libexecdir}/*
a27a5b
%{_datadir}/%{name}
a27a5b
%{_var}/lib/%{name}
a27a5b
a27a5b
%changelog
8c8245
* Mon Feb 27 2023 Robbie Harwood <rharwood@redhat.com> - 1.77-10
8c8245
- Fix inheritance of environment build flags
8c8245
- Resolves: #2144572
8c8245
a27a5b
* Mon Aug 09 2021 Mohan Boddu <mboddu@redhat.com> - 1.77-9
a27a5b
- Rebuilt for IMA sigs, glibc 2.34, aarch64 flags
a27a5b
  Related: rhbz#1991688
a27a5b
a27a5b
* Fri Apr 16 2021 Mohan Boddu <mboddu@redhat.com> - 1.77-8
a27a5b
- Rebuilt for RHEL 9 BETA on Apr 15th 2021. Related: rhbz#1947937
a27a5b
a27a5b
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 1.77-7
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
a27a5b
a27a5b
* Sat Oct 10 2020 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.77-6
a27a5b
- Workaround for grub2-mount slow wildcard file matching, fixes #1770599
a27a5b
a27a5b
* Tue Jul 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.77-5
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
a27a5b
a27a5b
* Wed Jan 29 2020 Fedora Release Engineering <releng@fedoraproject.org> - 1.77-4
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
a27a5b
a27a5b
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.77-3
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
a27a5b
a27a5b
* Tue May 14 2019 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.77-2
a27a5b
- Use distro LDFLAGS when building the package, fixes #1543863
a27a5b
a27a5b
* Tue May 14 2019 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.77-1
a27a5b
- Update to 1.77, use grub2-mount rather than device mapper for mounts, fixes #1447156
a27a5b
a27a5b
* Fri Feb 01 2019 Fedora Release Engineering <releng@fedoraproject.org> - 1.74-8
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
a27a5b
a27a5b
* Fri Jul 13 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.74-7
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
a27a5b
a27a5b
* Sun Feb 18 2018 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.74-6
a27a5b
- Add gcc build dependency
a27a5b
a27a5b
* Thu Feb 08 2018 Fedora Release Engineering <releng@fedoraproject.org> - 1.74-5
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
a27a5b
a27a5b
* Fri Dec 29 2017 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.74-4
a27a5b
- Fix a path problem in btrfsfix.patch, fixes #1529616
a27a5b
a27a5b
* Thu Aug 03 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.74-3
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
a27a5b
a27a5b
* Thu Jul 27 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.74-2
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
a27a5b
a27a5b
* Mon Mar 27 2017 Neal Gompa <ngompa13@gmail.com> - 1.74-1
a27a5b
- Update to upstream version 1.74
a27a5b
- Drop merged patches
a27a5b
- Rediff remaining patches
a27a5b
- Move newns to /usr/libexec/os-prober (debuginfo generation works)
a27a5b
- Mark copyright file as license file
a27a5b
a27a5b
* Sat Feb 11 2017 Fedora Release Engineering <releng@fedoraproject.org> - 1.71-2
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
a27a5b
a27a5b
* Fri Mar 04 2016 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.71-1
a27a5b
- Update to upstream version 1.71
a27a5b
- Use git based autosetup for applying patches
a27a5b
a27a5b
* Mon Feb 15 2016 Peter Jones <pjones@redhat.com> - 1.70-3
a27a5b
- Don't keep backups with 'patch -b'; they wind up in the ouput package.
a27a5b
a27a5b
* Thu Feb 04 2016 Fedora Release Engineering <releng@fedoraproject.org> - 1.70-2
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
a27a5b
a27a5b
* Fri Nov 13 2015 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.70-1
a27a5b
- Update to upstream version 1.70, fixes #1275641
a27a5b
- Fix bug #1236358 - os-prober duplicates grub entries for read/write btrfs
a27a5b
  subvolumes, thanks to Helmut Horvath
a27a5b
- Fix bug #1236649 - os-prober does not detect os on btrfs partition without
a27a5b
  any subvolume
a27a5b
a27a5b
* Tue Oct 20 2015 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.68-1
a27a5b
- Update to upstream version 1.68, bug #1267779
a27a5b
- Support a case where a kernel named vmlinuz/x is used under Gentoo, bug #1223237
a27a5b
a27a5b
* Thu Jun 18 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.65-3
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
a27a5b
a27a5b
* Tue Dec 23 2014 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.65-2
a27a5b
- Fix using grep for searching binary files, fixes #1172405. Thanks Paul Eggert
a27a5b
  for initial patch fixing grep usage in 83haiku
a27a5b
a27a5b
* Sun Dec 07 2014 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.65-1
a27a5b
- Using latest upstream version tarball to be consistent with upstream
a27a5b
  versioning
a27a5b
a27a5b
* Sat Oct 25 2014 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.58-11
a27a5b
- Fix parsing grub2's initrd/linux variations, rhbz #1108344
a27a5b
a27a5b
* Mon Sep 08 2014 Peter Jones <pjones@redhat.com> - 1.58-10
a27a5b
- Make os-prober output include partitions for UEFI chainloads.
a27a5b
  Resolves: rhbz#873207
a27a5b
a27a5b
* Sun Aug 17 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.58-9
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
a27a5b
a27a5b
* Sun Jul 06 2014 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.58-8
a27a5b
- Fix bug in counting LVM LVs which their name contains 'btrfs' as btrfs volumes
a27a5b
a27a5b
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.58-7
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
a27a5b
a27a5b
* Tue May 06 2014 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.58-6
a27a5b
- Fix separate /usr partitions for usrmove distros (bug #1044760)
a27a5b
- Fix umount error when directory is temporarily busy (bug #903906)
a27a5b
a27a5b
* Thu Apr 24 2014 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.58-5
a27a5b
- Fixed bug #982009: fix btrfs support
a27a5b
- Suppress some more debug messages when debug messages are disabled
a27a5b
a27a5b
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.58-4
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
a27a5b
a27a5b
* Tue Jul 02 2013 Adam Williamson <awilliam@redhat.com> - 1.58-3
a27a5b
- revert factored-logger-efi-fix.patch until grub2 is updated to match
a27a5b
a27a5b
* Tue Jun 18 2013 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.58-2
a27a5b
- Fix a bug in EFI detection because of redirecting result output
a27a5b
a27a5b
* Sun May 05 2013 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.58-1
a27a5b
- Update to upstream version 1.58, with UEFI support
a27a5b
a27a5b
* Sat Feb 02 2013 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.57-2
a27a5b
- Fix a bug in recent btrfs patch when an extended partition is examined. 
a27a5b
  (H.J. Lu) (bug #906847)
a27a5b
- Fix naming of /boot partitions according to their fstab entry (bug #893472)
a27a5b
- Don't generate .btrfsfix files which will be included in final rpm
a27a5b
- Fix wrong boot partition set by linux-boot-prober when / and /boot are
a27a5b
  mounted (bug #906886)
a27a5b
- Factor out 'logger', so that it is run once and logs are piped to it (John
a27a5b
  Reiser) (bug #875356)
a27a5b
a27a5b
* Tue Jan 22 2013 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.57-1
a27a5b
- Update to 1.57 (#890409)
a27a5b
- Use shell string processing rather than 'basename' (#875356)
a27a5b
- Make it possible to disable logging debug messages by assigning a value to
a27a5b
  OS_PROBER_DISABLE_DEBUG environment variable (Gene Czarcinski) (#893997).
a27a5b
- Detect multi btrfs pools/volumes (Gene Czarcinski) (#888341)
a27a5b
a27a5b
* Thu Oct 11 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.56-1
a27a5b
- Update to 1.56 with a bug fix and applied one of my patches
a27a5b
a27a5b
* Mon Aug 27 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.55-1
a27a5b
- Update to new upstream version: 1.55
a27a5b
a27a5b
* Fri Jul 20 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.53-4
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
a27a5b
a27a5b
* Sat Jun 02 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.53-3
a27a5b
- Consider usrmoved distribtions in fallback linux detector (bug #826754)
a27a5b
- Remove patch backup files from final rpm package (by not creating a backup!)
a27a5b
a27a5b
* Fri May 25 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.53-2
a27a5b
- Add support for OSes installed on Linux mdraid partitions, bug #752402
a27a5b
- Add Fedora's grub2 config path, fixes generating menu entries for other
a27a5b
  installed Fedora's
a27a5b
- Fixed bug in parsing yaboot.conf: accept spaces around '=' for append, 
a27a5b
  bug #825041
a27a5b
a27a5b
* Fri May 11 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.53-1
a27a5b
- Updated to 1.53 for a bugfix
a27a5b
- Fixed directory name in upstream tarbal
a27a5b
a27a5b
* Thu May 10 2012 Peter Jones <pjones@redhat.com> - 1.52-3
a27a5b
- Don't detect our Mac boot blocks as OS X.
a27a5b
  Resolves: rhbz#811412
a27a5b
a27a5b
* Sun Apr 29 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.52-2
a27a5b
- use correct directory name for setup
a27a5b
a27a5b
* Sun Apr 29 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.52-1
a27a5b
- Updated to 1.52, supports win 8
a27a5b
a27a5b
* Wed Mar 28 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.51-1
a27a5b
- Update to latest upstream version, 1.51
a27a5b
a27a5b
* Sat Jan 21 2012 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.48-3
a27a5b
- Remove dmraid and lvm2 dependency. bug #770393
a27a5b
a27a5b
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.48-2
a27a5b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
a27a5b
a27a5b
* Mon Jul 25 2011 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.48-1
a27a5b
- Updated to 1.48 release
a27a5b
a27a5b
* Thu May 19 2011 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.47-1
a27a5b
- Updated to the new upstream version 1.47
a27a5b
a27a5b
* Wed May 04 2011 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.46-2
a27a5b
- Removed obsolete parts (build tag, defattr, etc)
a27a5b
- Added a patch to move newns outside of os-prober subdirectory
a27a5b
- Added required utilities as package requires
a27a5b
a27a5b
* Sat Apr 30 2011 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.46-1
a27a5b
- Updated to 1.46 release
a27a5b
a27a5b
* Tue Feb 22 2011 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.42-2
a27a5b
- Remove executable permission from common.sh
a27a5b
a27a5b
* Thu Feb 17 2011 Hedayat Vatankhah <hedayat.fwd+rpmchlog@gmail.com> - 1.42-1
a27a5b
- Initial version