diff options
author | Mike Frysinger <vapier@gentoo.org> | 2008-12-30 11:35:54 +0000 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2008-12-30 11:35:54 +0000 |
commit | a49fb135bf87efc393b1c5c08783c76a24408722 (patch) | |
tree | d5b345300803bd7545a24a20c9cf9ccb114b4b21 /sys-boot | |
parent | Get ready for xulrunner 1.9.1, patch spotted by loki_val (diff) | |
download | historical-a49fb135bf87efc393b1c5c08783c76a24408722.tar.gz historical-a49fb135bf87efc393b1c5c08783c76a24408722.tar.bz2 historical-a49fb135bf87efc393b1c5c08783c76a24408722.zip |
Fix install paths and add support for USE=multislot so people can toy with grub2 while keeping grub1.
Package-Manager: portage-2.2_rc20/cvs/Linux 2.6.28 x86_64
Diffstat (limited to 'sys-boot')
-rw-r--r-- | sys-boot/grub/ChangeLog | 7 | ||||
-rw-r--r-- | sys-boot/grub/Manifest | 14 | ||||
-rw-r--r-- | sys-boot/grub/grub-1.96.ebuild | 39 | ||||
-rw-r--r-- | sys-boot/grub/grub-9999.ebuild | 39 | ||||
-rw-r--r-- | sys-boot/grub/metadata.xml | 1 |
5 files changed, 78 insertions, 22 deletions
diff --git a/sys-boot/grub/ChangeLog b/sys-boot/grub/ChangeLog index 6bb7d7eac97a..390ba4df7a2e 100644 --- a/sys-boot/grub/ChangeLog +++ b/sys-boot/grub/ChangeLog @@ -1,6 +1,11 @@ # ChangeLog for sys-boot/grub # Copyright 1999-2008 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-boot/grub/ChangeLog,v 1.107 2008/12/30 02:18:04 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-boot/grub/ChangeLog,v 1.108 2008/12/30 11:35:54 vapier Exp $ + + 30 Dec 2008; Mike Frysinger <vapier@gentoo.org> metadata.xml, + grub-1.96.ebuild, grub-9999.ebuild: + Fix install paths and add support for USE=multislot so people can toy with + grub2 while keeping grub1. 30 Dec 2008; Mike Frysinger <vapier@gentoo.org> grub-1.96.ebuild, grub-9999.ebuild: diff --git a/sys-boot/grub/Manifest b/sys-boot/grub/Manifest index 84c191ee145e..9360d824c65a 100644 --- a/sys-boot/grub/Manifest +++ b/sys-boot/grub/Manifest @@ -32,14 +32,14 @@ EBUILD grub-0.97-r5.ebuild 6880 RMD160 942a63d78c6c1f58f7139b5df863c89466484828 EBUILD grub-0.97-r6.ebuild 8833 RMD160 d49c9ecff3d451a318fdcf4d5367549b4ae946c6 SHA1 ebf3222a1eaac1c272de84617a64e2e3da80a315 SHA256 c7fb9191776c0bacf6b9160f1e78cb1fa6ccefbed03b85a219a1ab355bc5f36b EBUILD grub-0.97-r8.ebuild 8871 RMD160 c6255b0e4de7b0c03611e7227d5fb3ce48db5cce SHA1 9557b2edc8ba61766cd35a2a4d37e26434aaeff7 SHA256 34a4d4ffb38e0bf0ba2647933b7aa341c72537add518bc4ec217419619c1f960 EBUILD grub-0.97.ebuild 4527 RMD160 bc8dec8916cd52bbd0403d3e504f8a407d9e897c SHA1 7fc00e33d980842ed65b242ac53522b51894fa7c SHA256 2c20b9c10a242d15b17b48d73e5136c7f350cd313f77dd177c54a08f663be02a -EBUILD grub-1.96.ebuild 1244 RMD160 39d6c28a7df823c74b0e02440d1e578eb9574413 SHA1 6bc806a4c499cd2a07841d0b50050e2cddbbd81b SHA256 6520c3fe6f3ac37a14453c1f307b8be863e0e41f50224966078076c4016cb209 -EBUILD grub-9999.ebuild 1244 RMD160 b9a87645d42ac22686cc3e4a5da3008029328eb5 SHA1 8c1a2a74fd45aaa468031993bfabb8dc79b2c712 SHA256 313e65c1376be7eefc837c2a8b2cd34889a60ab800cc163459ccfeaf34fce971 -MISC ChangeLog 24256 RMD160 a693ba76cddaf4f841bc8a494744b60a17815663 SHA1 cc79a3c8c7f05db8087366a6977bc35f57ac0e5a SHA256 f24d183526ca238a0fe56dffc65afc38bfbf3eaa998bd1d3feadc1e9d3a47d3a -MISC metadata.xml 250 RMD160 5d297cf8754c72fea2a5afa5b9e3b35c2e131f31 SHA1 37c9d016076a9869497199b1d2280437b01aa9ee SHA256 9cc0f0e1b861d82b2396fa0ea25e5ea3f41d066fbce9ef9404d651a011020be3 +EBUILD grub-1.96.ebuild 1975 RMD160 3662ce1cef0bafa6ecb3f052db0f168c93731587 SHA1 335cfb29f288cd31c3bde4bf9946bea9229d6200 SHA256 6a397833c67ac64664f5016f1da244769883d64ed00de263962c9dfd9f87c454 +EBUILD grub-9999.ebuild 1975 RMD160 c8c32858e2939ded6e0fe8fcecc2c7788d47089d SHA1 1049c6db01691a7e3bbeb8fd15a36380e7b0126f SHA256 d116b8c2578b52f7b3ae9e9e22777b9a94928e375dc36d43d980f77e82a3a5b6 +MISC ChangeLog 24465 RMD160 a5b272a150b052d1d50872d9389157f1eacd7115 SHA1 d65d276bbb61242cf26aecc82bc6a87c8b5d8b68 SHA256 3272403a7ac31bb2db7440517eb2160c694b74a7bd60920996f04082a6c80e12 +MISC metadata.xml 335 RMD160 0b3dc4adad396efff41ba497f8b1f2181592885f SHA1 84ef61b0ab9dff3cdb0ac4697643156c019d0318 SHA256 ee3c63b09962a2686c0d32def9ca19ecfcd602cebbf0679cb57cfc02a9661c75 -----BEGIN PGP SIGNATURE----- Version: GnuPG v2.0.9 (GNU/Linux) -iEYEARECAAYFAklZhOIACgkQn/5bYzqsSmGO7wCfaklvf30pxXSngbc0dUbEx7Kz -qeMAnibGJl4qJWcX5gQ54QA0YnylqVxn -=E7wS +iEYEARECAAYFAklaB6IACgkQn/5bYzqsSmHVWwCbBRiy/2DrpOiDziSEvBwXW8Ru +2tcAnijhy/yN87AbS5IEKB7ygiKow9fr +=JWMB -----END PGP SIGNATURE----- diff --git a/sys-boot/grub/grub-1.96.ebuild b/sys-boot/grub/grub-1.96.ebuild index 3fc7686a570a..1ccfb8e38ddd 100644 --- a/sys-boot/grub/grub-1.96.ebuild +++ b/sys-boot/grub/grub-1.96.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2008 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-boot/grub/grub-1.96.ebuild,v 1.7 2008/12/30 02:18:04 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-boot/grub/grub-1.96.ebuild,v 1.8 2008/12/30 11:35:54 vapier Exp $ inherit mount-boot eutils flag-o-matic toolchain-funcs @@ -17,15 +17,16 @@ DESCRIPTION="GNU GRUB 2 boot loader" HOMEPAGE="http://www.gnu.org/software/grub/" LICENSE="GPL-2" -SLOT="0" +use multislot && SLOT="2" || SLOT="0" KEYWORDS="" -IUSE="static custom-cflags" +IUSE="custom-cflags multislot static" DEPEND=">=sys-libs/ncurses-5.2-r5 dev-libs/lzo" PROVIDE="virtual/bootloader" STRIP_MASK="/lib*/grub/*/*.mod" +QA_EXECSTACK="sbin/grub-probe sbin/grub-setup" src_compile() { use amd64 && multilib_toolchain_setup x86 @@ -33,8 +34,9 @@ src_compile() { use static && append-ldflags -static econf \ - --prefix=/ \ - --datadir=/usr/lib \ + --sbindir=/sbin \ + --bindir=/bin \ + --libdir=/$(get_libdir) \ || die "econf failed" emake -j1 || die "making regular stuff" } @@ -42,9 +44,32 @@ src_compile() { src_install() { emake DESTDIR="${D}" install || die dodoc AUTHORS ChangeLog NEWS README THANKS TODO + if use multislot ; then + sed -i s:grub-install:grub2-install: "${D}"/sbin/grub-install + mv "${D}"/sbin/grub{,2}-install || die + mv "${D}"/usr/share/man/man8/grub{,2}-install.8 || die + fi +} + +setup_boot_dir() { + local boot_dir=$1 + local dir=${boot_dir}/grub + + if [[ ! -e ${dir}/grub.cfg ]] ; then + einfo "Running: grub-mkconfig -o '${dir}/grub.cfg'" + grub-mkconfig -o "${dir}/grub.cfg" + fi + + #local install=grub-install + #use multislot && install="grub2-install --grub-setup=/bin/true" + #einfo "Running: ${install} " + #${install} } pkg_postinst() { - elog "To automatically generate a grub configuration file:" - elog "# /sbin/grub-mkconfig -o /boot/grub/grub.cfg" + if use multislot ; then + elog "You have installed grub2 with USE=multislot, so to coexist" + elog "with grub1, the grub2 install binary is named grub2-install." + fi + setup_boot_dir "${ROOT}"boot } diff --git a/sys-boot/grub/grub-9999.ebuild b/sys-boot/grub/grub-9999.ebuild index 2c62773b4ec8..51b9a4a11d75 100644 --- a/sys-boot/grub/grub-9999.ebuild +++ b/sys-boot/grub/grub-9999.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2008 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-boot/grub/grub-9999.ebuild,v 1.2 2008/12/30 02:18:04 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-boot/grub/grub-9999.ebuild,v 1.3 2008/12/30 11:35:54 vapier Exp $ inherit mount-boot eutils flag-o-matic toolchain-funcs @@ -17,15 +17,16 @@ DESCRIPTION="GNU GRUB 2 boot loader" HOMEPAGE="http://www.gnu.org/software/grub/" LICENSE="GPL-2" -SLOT="0" +use multislot && SLOT="2" || SLOT="0" KEYWORDS="" -IUSE="static custom-cflags" +IUSE="custom-cflags multislot static" DEPEND=">=sys-libs/ncurses-5.2-r5 dev-libs/lzo" PROVIDE="virtual/bootloader" STRIP_MASK="/lib*/grub/*/*.mod" +QA_EXECSTACK="sbin/grub-probe sbin/grub-setup" src_compile() { use amd64 && multilib_toolchain_setup x86 @@ -33,8 +34,9 @@ src_compile() { use static && append-ldflags -static econf \ - --prefix=/ \ - --datadir=/usr/lib \ + --sbindir=/sbin \ + --bindir=/bin \ + --libdir=/$(get_libdir) \ || die "econf failed" emake -j1 || die "making regular stuff" } @@ -42,9 +44,32 @@ src_compile() { src_install() { emake DESTDIR="${D}" install || die dodoc AUTHORS ChangeLog NEWS README THANKS TODO + if use multislot ; then + sed -i s:grub-install:grub2-install: "${D}"/sbin/grub-install + mv "${D}"/sbin/grub{,2}-install || die + mv "${D}"/usr/share/man/man8/grub{,2}-install.8 || die + fi +} + +setup_boot_dir() { + local boot_dir=$1 + local dir=${boot_dir}/grub + + if [[ ! -e ${dir}/grub.cfg ]] ; then + einfo "Running: grub-mkconfig -o '${dir}/grub.cfg'" + grub-mkconfig -o "${dir}/grub.cfg" + fi + + #local install=grub-install + #use multislot && install="grub2-install --grub-setup=/bin/true" + #einfo "Running: ${install} " + #${install} } pkg_postinst() { - elog "To automatically generate a grub configuration file:" - elog "# /sbin/grub-mkconfig -o /boot/grub/grub.cfg" + if use multislot ; then + elog "You have installed grub2 with USE=multislot, so to coexist" + elog "with grub1, the grub2 install binary is named grub2-install." + fi + setup_boot_dir "${ROOT}"boot } diff --git a/sys-boot/grub/metadata.xml b/sys-boot/grub/metadata.xml index 6a65231a2cf2..410891a6f015 100644 --- a/sys-boot/grub/metadata.xml +++ b/sys-boot/grub/metadata.xml @@ -4,5 +4,6 @@ <herd>base-system</herd> <use> <flag name='custom-cflags'>Enable custom CFLAGS (not supported)</flag> + <flag name='multislot'>Allow grub1 and grub2 to be installed simultaneously</flag> </use> </pkgmetadata> |