a9eb1f4
Name: grubby
5ad2971
Version: 8.35
13b3f1d
Release: 9%{?dist}
a9eb1f4
Summary: Command line tool for updating bootloader configs
a9eb1f4
Group: System Environment/Base
a9eb1f4
License: GPLv2+
a9eb1f4
URL: http://git.fedorahosted.org/git/grubby.git
a9eb1f4
# we only pull git snaps at the moment
a9eb1f4
# git clone git://git.fedorahosted.org/git/grubby.git
a9eb1f4
# git archive --format=tar --prefix=grubby-%{version}/ HEAD |bzip2 > grubby-%{version}.tar.bz2
a9eb1f4
Source0: %{name}-%{version}.tar.bz2
0370b22
Patch0001: 0001-Don-t-go-past-the-last-element-of-indexVars-in-findE.patch
0370b22
Patch0002: 0002-Add-bls-test-harness-bits.patch
0370b22
Patch0003: 0003-grubby-fix-initrd-updating-when-multiboot-exist.patch
0370b22
Patch0004: 0004-Tell-a-slightly-better-fib-about-default-bootloader-.patch
0370b22
Patch0005: 0005-Make-findTemplate-actually-return-the-saved-default.patch
ee98474
Patch0006: 0006-Revert-Add-bls-test-harness-bits.patch
ee98474
Patch0007: 0007-Always-error-check-getLineByType.patch
ee98474
Patch0008: 0008-Add-devtree-support-to-extlinux-1088933.patch
ee98474
Patch0009: 0009-add-support-for-devicetree-directories-for-use-on-ar.patch
ee98474
Patch0010: 0010-cleanup-dtb-handling-to-work-in-the-supported-usecas.patch
e2a3f9c
Patch0011: 0001-Treat-kernel-and-kernel-core-as-identical-in-terms-o.patch
c8c92c6
a9eb1f4
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
a9eb1f4
BuildRequires: pkgconfig glib2-devel popt-devel 
d344961
BuildRequires: libblkid-devel git
bd6fd92
# for make test / getopt:
bd6fd92
BuildRequires: util-linux-ng
e0c126c
%ifarch aarch64 i686 x86_64 ppc ppc64
c8c92c6
BuildRequires: /usr/bin/grub2-editenv
0d3237c
%endif
b3b4435
%ifarch s390 s390x
ab7ba06
Requires: s390utils-base
b3b4435
%endif
f62abfe
%ifarch %{arm}
f62abfe
Requires: uboot-tools
f62abfe
%endif
a9eb1f4
a9eb1f4
%description
a9eb1f4
grubby  is  a command line tool for updating and displaying information about 
a9eb1f4
the configuration files for the grub, lilo, elilo (ia64),  yaboot (powerpc)  
a9eb1f4
and zipl (s390) boot loaders. It is primarily designed to be used from scripts
a9eb1f4
which install new kernels and need to find information about the current boot 
a9eb1f4
environment.
a9eb1f4
a9eb1f4
%prep
a9eb1f4
%setup -q
a9eb1f4
d344961
git init
d344961
git config user.email "noone@example.com"
d344961
git config user.name "no one"
d344961
git add .
d344961
git commit -a -q -m "%{version} baseline"
d344961
git am %{patches} 
ac7dcc0
git config --unset user.email
ac7dcc0
git config --unset user.name
d344961
a9eb1f4
%build
a9eb1f4
make %{?_smp_mflags}
a9eb1f4
13b3f1d
%ifnarch aarch64 %{arm}
a9eb1f4
%check
a9eb1f4
make test
13b3f1d
%endif
a9eb1f4
a9eb1f4
%install
a9eb1f4
rm -rf $RPM_BUILD_ROOT
a9eb1f4
make install DESTDIR=$RPM_BUILD_ROOT mandir=%{_mandir}
f62abfe
%ifarch %{arm}
f62abfe
mkdir -p $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/
f62abfe
install -p uboot $RPM_BUILD_ROOT%{_sysconfdir}/sysconfig/uboot
0352db6
mkdir -p $RPM_BUILD_ROOT/boot
0352db6
echo " " >> $RPM_BUILD_ROOT/boot/boot.scr
f62abfe
%endif
a9eb1f4
a9eb1f4
%clean
a9eb1f4
rm -rf $RPM_BUILD_ROOT
a9eb1f4
a9eb1f4
%files
a9eb1f4
%defattr(-,root,root,-)
961d5e3
%{!?_licensedir:%global license %%doc}
961d5e3
%license COPYING
a9eb1f4
/sbin/installkernel
a9eb1f4
/sbin/new-kernel-pkg
a9eb1f4
/sbin/grubby
17d5f29
%{_mandir}/man8/*.8*
f62abfe
%ifarch %{arm}
302c25e
%config(noreplace) %{_sysconfdir}/sysconfig/uboot
0352db6
%config(noreplace) /boot/boot.scr
f62abfe
%endif
a9eb1f4
a9eb1f4
%changelog
13b3f1d
* Thu Nov 13 2014 Peter Jones <pjones@redhat.com> - 8.35-9
13b3f1d
- Disable "make check" on arm builds; right now the test suite is broken
13b3f1d
  there and raises false positives constantly.
13b3f1d
e2a3f9c
* Mon Oct 27 2014 Peter Jones <pjones@redhat.com> - 8.35-8
e2a3f9c
- Treat kernel and kernel-core as identical in terms of --make-default
e2a3f9c
  Resolves: rhbz#1141414
e2a3f9c
ee98474
* Thu Oct 16 2014 Peter Jones <pjones@redhat.com> - 8.35-7
ee98474
- Revert "debug" image creation for now
ee98474
  Resolves: rhbz#1153410
ee98474
- Fix minor quoting errors in dtbdir code
ee98474
  Resolves: rhbz#1088933
ee98474
635a3b8
* Wed Oct 15 2014 Peter Jones <pjones@redhat.com> - 8.35-6
635a3b8
- Update grubby to support device tree options for arm.  Again.
635a3b8
  Resolves: rhbz#1088933
635a3b8
0370b22
* Fri Sep 26 2014 Peter Jones <pjones@redhat.com> - 8.35-5
0370b22
- See if what people are seeing in 1141414 is actually 957681
0370b22
  Related: rhbz#957681
0370b22
  Related: rhbz#1141414
0370b22
271f511
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.35-4
271f511
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
271f511
961d5e3
* Sat Jul 12 2014 Tom Callaway <spot@fedoraproject.org> - 8.35-3
961d5e3
- fix license handling
961d5e3
d8d47e3
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.35-2
d8d47e3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
d8d47e3
5ad2971
* Wed May 21 2014 Peter Jones <pjones@redhat.com> - 8.35-1
5ad2971
- Fix a minor test case error that causes koji builds to fail.
5ad2971
  Related: rhbz#1096358
5ad2971
03801fd
* Wed May 21 2014 Peter Jones <pjones@redhat.com> - 8.34-1
03801fd
- Make grub2 "--copy-default --add-kernel=foo --initrd=bar" work when default
03801fd
  has no initrd line.
03801fd
  Resolves: rhbz#1099627
03801fd
  Related: rhbz#1096358
03801fd
facc9c5
* Tue Apr 01 2014 Peter Jones <pjones@redhat.com> - 8.33-1
facc9c5
- Fix --devtree test in new-kernel-pkg even harder (#1082318)
facc9c5
dcde681
* Mon Mar 31 2014 Peter Jones <pjones@redhat.com> - 8.32-1
dcde681
- Fix --devtree test in new-kernel-pkg (#1082318)
dcde681
- Fix aarch64 #define test.
dcde681
58f61ff
* Fri Mar 28 2014 Peter Jones <pjones@redhat.com> - 8.31-1
58f61ff
- Update to 8.31
58f61ff
- Fold in patches from Fedora and RHEL 7 trees
58f61ff
dc1eb4a
* Mon Jan 20 2014 Lubomir Rintel <lkundrak@v3.sk> - 8.28-2
dc1eb4a
- Fix extlinux default
dc1eb4a
c8c92c6
* Fri Aug 02 2013 Peter Jones <pjones@redhat.com> - 8.28-1
c8c92c6
- More work on grub's "saved_entry" system. 
c8c92c6
  Resolves: rhbz#768106
c8c92c6
  Resolves: rhbz#736188
c8c92c6
0d3237c
* Tue Jul 30 2013 Peter Jones <pjones@redhat.com> - 8.27-1
8e77304
- Make grubby understand grub's "saved_entry" system
8e77304
  Resolves: rhbz#768106
8e77304
  Resolves: rhbz#736188
0d3237c
- BuildRequire grub2 on appropriate platforms, for the test suite.
8e77304
223896f
* Fri Jun 07 2013 Dennis Gilmore <dennis@ausil.us> - 8.26-2
223896f
- add patch to update extlinux.conf file on arm if it exists
223896f
efdb493
* Fri May 10 2013 Peter Jones <pjones@redhat.com> - 8.26-1
efdb493
- Conditionally call arm-boot-config's boot.scr generator if available
efdb493
  Resolves: rhbz#952428
efdb493
e7dc179
* Tue Apr 09 2013 Peter Jones <pjones@redhat.com> - 8.25-1
e7dc179
- Error instead of segfaulting if we can't find any working config
e7dc179
  Resolves: rhbz#912873
e7dc179
  Resolves: rhbz#751608
e7dc179
8766289
* Tue Mar 19 2013 Peter Jones <pjones@redhat.com> - 8.24-1
8766289
- Fix module remove code from Harald (#923441)
8766289
440ec26
* Mon Mar 11 2013 Peter Jones <pjones@redhat.com> - 8.23-1
440ec26
- Update to 8.23
440ec26
- Fix empty root device in case of an empty /etc/fstab (lemenkov)
440ec26
- General refactoring and cleanup (harald)
440ec26
- Don't clean up modules.* so aggressively (harald)
440ec26
a103458
* Wed Feb 20 2013 Peter Jones <pjones@redhat.com> - 8.22-3
a103458
- Add --debug style logging (for both success and failures) to /var/log/grubby
a103458
24e2f46
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.22-2
24e2f46
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
24e2f46
5360404
* Fri Jan 04 2013 Peter Jones <pjones@redhat.com> - 8.22-1
5360404
- Revert test case for rhbz#742885 - it's a work in progress that isn't
5360404
  ready yet.
5360404
18940b4
* Fri Jan 04 2013 Peter Jones <pjones@redhat.com> - 8.21-1
18940b4
- Use systemd vconsole.conf and locale.conf if present
18940b4
  Resolves rhbz#881908
18940b4
- Avoid unnecessary stat calls (from Ville Skyttä)
18940b4
  Resolves rhbz#741135
18940b4
- Spelling fixes (Ville Skyttä)
18940b4
- Add a test case for rhbz#742885
18940b4
- Handle case-insensitive extlinux config files properly (from Johannes Weiner)
18940b4
1952dd2
* Tue Oct 02 2012 Peter Jones <pjones@redhat.com> - 8.20-1
1952dd2
- Handle linuxefi initrd and removal correctly.
1952dd2
  Resolves: rhbz#859285
1952dd2
6ca16bf
* Wed Sep 26 2012 Peter Jones <pjones@redhat.com> - 8.19-1
6ca16bf
- Don't accidentally migrate from linuxefi back to linux
1952dd2
  Related: rhbz#859285
6ca16bf
bfdd281
* Fri Sep 21 2012 Peter Jones <pjones@redhat.com> - 8.18-1
bfdd281
- Change the way the kernel load address is determined for ARM U-Boot.
bfdd281
64eecaa
* Wed Aug 08 2012 Peter Jones <pjones@redhat.com> - 8.17-1
64eecaa
- Update to 8.17
64eecaa
- Fixes a "make test" failure.
64eecaa
bc96cb6
* Wed Aug 08 2012 Peter Jones <pjones@redhat.com> - 8.16-1
bc96cb6
- Update to 8.16
bc96cb6
- Handle "linuxefi" directive on grub2/uefi machines.
bc96cb6
6e0c65a
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.15-2
6e0c65a
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
6e0c65a
eb38b67
* Mon Jun 25 2012 Peter Jones <pjones@redhat.com> - 8.15-1
eb38b67
- Update to 8.15
eb38b67
- Revert dirname change from 8.13; it was wrong.
eb38b67
a376a87
* Thu Jun 14 2012 Peter Jones <pjones@redhat.com> - 8.14-1
a376a87
- Update to 8.14 to fix a build problem.
a376a87
41ada0d
* Thu Jun 14 2012 Peter Jones <pjones@redhat.com> - 8.13-1
41ada0d
- Update to 8.13
41ada0d
- Add some more ARM tweaks (dmartin)
41ada0d
- Better support for other distros (crosa)
41ada0d
d344961
* Tue Jun 12 2012 Peter Jones <pjones@redhat.com> - 8.12-2
d344961
- Support UBOOT_IMGADDR override on ARM (blc)
d344961
94529bf
* Thu May 31 2012 Peter Jones <pjones@redhat.com> - 8.12-1
94529bf
- Update to 8.12
94529bf
- Preserve trailing indentation when splitting line elements (mads)
94529bf
  Resolves: rhbz#742720
94529bf
- Pick last device mounted on / (pjones,bcl)
94529bf
  Related: rhbz#820340
94529bf
  Related: rhbz#820351
94529bf
7cb2f55
* Wed Mar 21 2012 Peter Jones <pjones@redhat.com> - 8.11-1
7cb2f55
- Update to 8.11
7cb2f55
  Resolves: rhbz#805310
7cb2f55
fe70e86
* Thu Mar 15 2012 Peter Jones <pjones@redhat.com> - 8.10-1
fe70e86
- Update to 8.10
fe70e86
- Use "isquote" where appropriate
fe70e86
- Make --remove-kenrel support titles in grub2 (jianzhong.huang)
fe70e86
- Use grub2 if it's there on ppc.
fe70e86
a1dfda3
* Fri Mar 02 2012 Peter Jones <pjones@redhat.com> - 8.9-1
a1dfda3
- Refactor grub2 title extraction, making it a function (Cleber Rosa)
a1dfda3
- Include prefix when printing kernel information (Cleber Rosa)
a1dfda3
- Implement support for "default saved" for grub2 (Cleber Rosa)
a1dfda3
- Try to display title when printing information with '--info' (Cleber Rosa)
a1dfda3
- new-kernel-pkg fails to find U-Boot. (D. Marlin)
a1dfda3
- Add support to new-kernel-pkg to recognize ARCH == armv5tel needed for Kir
a1dfda3
  (D.Marlin)
a1dfda3
- Include a / when one is missing in paths (#769641)
a1dfda3
- Fix hard coded paths so kernel's "make install" will DTRT.
a1dfda3
- Fix endswith() to correctly test its input for validity.
dbb2308
f62abfe
* Tue Feb 07 2012 Dennis Gilmore <dennis@ausil.us> - 8.8-3
f62abfe
- add uboot-tools requires on arm arches
f62abfe
- add uboot config file on arm arches
f62abfe
7698149
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 8.8-2
7698149
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
7698149
992cb97
* Tue Dec 20 2011 Peter Jones <pjones@redhat.com> - 8.8-1
992cb97
- Fix test cases from 8.7 to work on a system without /boot mounted.
992cb97
9d9412e
* Tue Dec 20 2011 Peter Jones <pjones@redhat.com> - 8.7-1
9d9412e
- Add a --debug to try to help diagnose "No suitable template". (sandeen,pjones)
9d9412e
c021fe6
* Mon Dec 19 2011 Peter Jones <pjones@redhat.com> - 8.6-1
c021fe6
- Fix a "make test" errors introduced in 8.4-1
c021fe6
afb5036
* Sat Dec 17 2011 Peter Jones <pjones@redhat.com> - 8.5-1
afb5036
- Don't hardcode dracut path
afb5036
  Resolves: #768645
afb5036
203e662
* Thu Dec 08 2011 Adam Williamson <awilliam@redhat.com> - 8.4-1
203e662
- Update to 8.4:
203e662
	+ fix Loading... line for updated kernels
203e662
	+ Add new '--default-title' feature
203e662
	+ Add new '--default-index' feature
203e662
	+ add feature for testing the output of a grubby command
203e662
	+ Fix detection when comparing stage1 to MBR
203e662
	+ do not link against glib-2.0
203e662
	+ Don't crash if grubConfig not found
203e662
	+ Adding extlinux support for new-kernel-pkg
203e662
	+ Look for Debian / Ubuntu grub config files (#703260)
203e662
	+ Make grubby recognize Ubuntu's spin of Grub2 (#703260)
203e662
1ad83f1
* Thu Sep 29 2011 Peter Jones <pjones@redhat.com> - 8.3-1
1ad83f1
- Fix new-kernel-pkg invocation of grubby for grub (patch from Mads Kiilerich)
1ad83f1
  Resolves: rhbz#725185
1ad83f1
8bea9bd
* Wed Sep 14 2011 Peter Jones <pjones@redhat.com> - 8.2-1
8bea9bd
- Fixes for xen (from Michael Petullo)
8bea9bd
  Resolves: rhbz#658387
8bea9bd
bd7a6ca
* Fri Jul 22 2011 Peter Jones <pjones@redhat.com> - 8.1-1
bd7a6ca
- Update to 8.1
bd7a6ca
- Fix miss-spelled variable name in new-kernel-pkg
bd7a6ca
e98683f
* Thu Jul 21 2011 Peter Jones <pjones@redhat.com> - 8.0-1
e98683f
- Add support for grub2.
e98683f
0305287
* Tue Jun 07 2011 Brian C. Lane <bcl@redhat.com> - 7.0.18-1
0305287
- Bump version to 7.0.18 (bcl)
0305287
- Fixup new-kernel-pkg errors (#711493) (bcl)
0305287
8518bc6
* Mon Jun 06 2011 Peter Jones <pjones@redhat.com> - 7.0.17-1
8518bc6
- Fix references to wrong program name in new-kernel-pkg.8
8518bc6
  Resolves: rhbz#663981
8518bc6
ddaad05
* Wed Feb 09 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 7.0.16-3
ddaad05
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
ddaad05
bd6fd92
* Mon Jan 24 2011 Karsten Hopp <karsten@redhat.com> 7.0.16-2
bd6fd92
- add BR utils-linux-ng for getopt
bd6fd92
604a496
* Tue Jul 13 2010 Brian C. Lane <bcl@redhat.com> - 7.0.16-1
604a496
- Update to 7.0.16
604a496
- Add patch to check the return value of getuuidbydev
604a496
- Resolves: rhbz#592294
604a496
5bc936b
* Wed Apr 14 2010 Peter Jones <pjones@redhat.com> - 7.0.15-1
5bc936b
- Update to 7.0.15
17d5f29
- Add man pages for installkernel and new-kernel-pkg
17d5f29
  Resolves: rhbz#529333
17d5f29
5bc936b
* Wed Apr 14 2010 Peter Jones <pjones@redhat.com> - 7.0.14-1
5bc936b
- Update to 7.0.14
5bc936b
f515ba7
* Thu Feb 11 2010 Peter Jones <pjones@redhat.com> - 7.0.13-1
f515ba7
- Strip boot partition prefix from initrd path if present during --update.
f515ba7
  Related: rhbz#557922
f515ba7
- add host only support for local kernel compiles (airlied)
f515ba7
b7db526
* Mon Feb 08 2010 Peter Jones <pjones@redhat.com> - 7.0.12-1
b7db526
- compare rootdev using uuid instead of stat, for better btrfs support (josef)
b7db526
  Resolves: rhbz#530108
b7db526
2a3cb67
* Mon Feb 08 2010 Peter Jones <pjones@redhat.com> - 7.0.11-1
2a3cb67
- Make it possible to update the initrd without any other change.
2a3cb67
  Related: rhbz#557922
2a3cb67
79918d5
* Fri Feb 05 2010 Peter Jones <pjones@redhat.com> - 7.0.10-1
2dc2064
- Make --update able to add an initramfs.
2dc2064
  Related: rhbz#557922
2dc2064
ab7ba06
* Mon Nov 30 2009 Peter Jones <pjones@redhat.com> - 7.0.9-3
ab7ba06
- Use s390utils-base as the s390 dep, not s390utils
ab7ba06
  Related: rhbz#540565
ab7ba06
b3b4435
* Tue Nov 24 2009 Peter Jones <pjones@redhat.com> - 7.0.9-2
b3b4435
- Add s390utils dep when on s390, since new-kernel-package needs it.
b3b4435
  Resolves: rhbz#540565
b3b4435
4eebdab
* Fri Oct 30 2009 Peter Jones <pjones@redhat.com> - 7.0.9-1
4eebdab
- Add support for dracut to installkernel (notting)
4eebdab
e22efb9
* Thu Oct  1 2009 Hans de Goede <hdegoede@redhat.com> - 7.0.8-1
e22efb9
- Stop using nash
e22efb9
149e660
* Fri Sep 11 2009 Hans de Goede <hdegoede@redhat.com> - 7.0.7-1
149e660
- Remove writing rd_plytheme=$theme to kernel args in dracut mode (hansg)
149e660
- Add a couple of test cases for extra initrds (rstrode)
149e660
- Allow tmplLine to be NULL in getInitrdVal (rstrode)
149e660
03f900c
* Fri Sep 11 2009 Peter Jones <pjones@redhat.com> - 7.0.6-1
03f900c
- Fix test case breakage from 7.0.5 (rstrode)
03f900c
8c939a3
* Fri Sep 11 2009 Peter Jones <pjones@redhat.com> - 7.0.5-1
03f900c
- Add support for plymouth as a second initrd. (rstrode)
8c939a3
  Resolves: rhbz#520515
8c939a3
c1491bd
* Wed Sep 09 2009 Hans de Goede <hdegoede@redhat.com> - 7.0.4-1
c1491bd
- Add --dracut cmdline argument for %post generation of dracut initrd
c1491bd
fe7d7fa
* Wed Aug 26 2009 Hans de Goede <hdegoede@redhat.com> - 7.0.3-1
fe7d7fa
- Silence error when no /etc/sysconfig/keyboard (#517187)
fe7d7fa
2d87e7e
* Fri Aug  7 2009 Hans de Goede <hdegoede@redhat.com> - 7.0.2-1
2d87e7e
- Add --add-dracut-args new-kernel-pkg cmdline option
2d87e7e
eb17b79
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 7.0.1-2
eb17b79
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
eb17b79
01ded24
* Fri Jul 17 2009 Jeremy Katz <katzj@redhat.com> - 7.0.1-1
01ded24
- Fix blkid usage (#124246)
01ded24
a9eb1f4
* Wed Jun 24 2009 Jeremy Katz <katzj@redhat.com> - 7.0-1
a9eb1f4
- BR libblkid-devel now instead of e2fsprogs-devel
a9eb1f4
- Add bits to switch to using dracut for new-kernel-pkg
a9eb1f4
a9eb1f4
* Wed Jun  3 2009 Jeremy Katz <katzj@redhat.com> - 6.0.86-2
a9eb1f4
- add instructions for checking out from git
a9eb1f4
a9eb1f4
* Tue Jun  2 2009 Jeremy Katz <katzj@redhat.com> - 6.0.86-1
a9eb1f4
- initial build after splitting out from mkinitrd
a9eb1f4