From: Chris Gianelloni Date: Thu, 13 Jan 2005 22:57:25 +0000 (+0000) Subject: Added a portage version check to each target that uses --newuse to ensure a high... X-Git-Tag: CATALYST_2_0_6_916~851 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=99989b9e0e53eb83bea12140a59eef075e0d935c;p=catalyst.git Added a portage version check to each target that uses --newuse to ensure a high enough version is used. This resolves bug #75336. git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@522 d1e1f19c-881f-0410-ab34-b69fee027534 --- diff --git a/ChangeLog b/ChangeLog index 18057f77..23256893 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for gentoo/src/catalyst # Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo/src/catalyst/ChangeLog,v 1.148 2005/01/13 20:52:17 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo/src/catalyst/ChangeLog,v 1.149 2005/01/13 22:57:25 wolf31o2 Exp $ + + 13 Jan 2005; Chris Gianelloni + targets/embedded/embedded-chroot.sh, targets/grp/grp-chroot.sh, + targets/livecd-stage1/livecd-stage1-chroot.sh, + targets/netboot/netboot-packages.sh, targets/stage1/stage1-chroot.sh, + targets/stage3/stage3-chroot.sh: + Added a portage version check to each target that uses --newuse to ensure a + high enough version is used. This resolves bug #75336. 13 Jan 2005; Chris Gianelloni livecd/files/livecd-local.start: diff --git a/targets/embedded/embedded-chroot.sh b/targets/embedded/embedded-chroot.sh index 85579d8a..c26a2507 100755 --- a/targets/embedded/embedded-chroot.sh +++ b/targets/embedded/embedded-chroot.sh @@ -1,7 +1,16 @@ #!/bin/bash # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo/src/catalyst/targets/embedded/embedded-chroot.sh,v 1.11 2005/01/11 14:10:19 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo/src/catalyst/targets/embedded/embedded-chroot.sh,v 1.12 2005/01/13 22:57:25 wolf31o2 Exp $ + +portage_version=`/usr/lib/portage/bin/portageq best_version / sys-apps/portage \ + | cut -d/ -f2 | cut -d- -f2,3` +if [ `echo ${portage_version} | cut -d- -f1 | cut -d. -f3` -lt 51 ] +then + echo "ERROR: Your portage version is too low in your seed stage. Portage version" + echo "2.0.51 or greater is required." + exit 1 +fi /usr/sbin/env-update source /etc/profile diff --git a/targets/grp/grp-chroot.sh b/targets/grp/grp-chroot.sh index 4e7f8226..8dd5c2eb 100755 --- a/targets/grp/grp-chroot.sh +++ b/targets/grp/grp-chroot.sh @@ -1,7 +1,17 @@ #!/bin/bash # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo/src/catalyst/targets/grp/grp-chroot.sh,v 1.11 2005/01/11 14:10:19 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo/src/catalyst/targets/grp/grp-chroot.sh,v 1.12 2005/01/13 22:57:25 wolf31o2 Exp $ + +# check portage version in seed stage +portage_version=`/usr/lib/portage/bin/portageq best_version / sys-apps/portage \ + | cut -d/ -f2 | cut -d- -f2,3` +if [ `echo ${portage_version} | cut -d- -f1 | cut -d. -f3` -lt 51 ] +then + echo "ERROR: Your portage version is too low in your seed stage. Portage version" + echo "2.0.51 or greater is required." + exit 1 +fi /usr/sbin/env-update source /etc/profile diff --git a/targets/livecd-stage1/livecd-stage1-chroot.sh b/targets/livecd-stage1/livecd-stage1-chroot.sh index 5ebcc841..0c0d7b93 100755 --- a/targets/livecd-stage1/livecd-stage1-chroot.sh +++ b/targets/livecd-stage1/livecd-stage1-chroot.sh @@ -1,7 +1,16 @@ #!/bin/bash # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo/src/catalyst/targets/livecd-stage1/livecd-stage1-chroot.sh,v 1.11 2005/01/11 14:10:19 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo/src/catalyst/targets/livecd-stage1/livecd-stage1-chroot.sh,v 1.12 2005/01/13 22:57:25 wolf31o2 Exp $ + +portage_version=`/usr/lib/portage/bin/portageq best_version / sys-apps/portage \ + | cut -d/ -f2 | cut -d- -f2,3` +if [ `echo ${portage_version} | cut -d- -f1 | cut -d. -f3` -lt 51 ] +then + echo "ERROR: Your portage version is too low in your seed stage. Portage version" + echo "2.0.51 or greater is required." + exit 1 +fi /usr/sbin/env-update source /etc/profile diff --git a/targets/netboot/netboot-packages.sh b/targets/netboot/netboot-packages.sh index 99518c51..e5d392e2 100644 --- a/targets/netboot/netboot-packages.sh +++ b/targets/netboot/netboot-packages.sh @@ -1,7 +1,16 @@ #!/bin/bash # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo/src/catalyst/targets/netboot/Attic/netboot-packages.sh,v 1.3 2005/01/11 14:10:19 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo/src/catalyst/targets/netboot/Attic/netboot-packages.sh,v 1.4 2005/01/13 22:57:25 wolf31o2 Exp $ + +portage_version=`/usr/lib/portage/bin/portageq best_version / sys-apps/portage \ + | cut -d/ -f2 | cut -d- -f2,3` +if [ `echo ${portage_version} | cut -d- -f1 | cut -d. -f3` -lt 51 ] +then + echo "ERROR: Your portage version is too low in your seed stage. Portage version" + echo "2.0.51 or greater is required." + exit 1 +fi /usr/sbin/env-update source /etc/profile diff --git a/targets/stage1/stage1-chroot.sh b/targets/stage1/stage1-chroot.sh index b72477f7..0be0e35c 100755 --- a/targets/stage1/stage1-chroot.sh +++ b/targets/stage1/stage1-chroot.sh @@ -1,8 +1,17 @@ #!/bin/bash # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo/src/catalyst/targets/stage1/stage1-chroot.sh,v 1.26 2005/01/11 14:10:19 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo/src/catalyst/targets/stage1/stage1-chroot.sh,v 1.27 2005/01/13 22:57:25 wolf31o2 Exp $ +portage_version=`/usr/lib/portage/bin/portageq best_version / sys-apps/portage \ + | cut -d/ -f2 | cut -d- -f2,3` +if [ `echo ${portage_version} | cut -d- -f1 | cut -d. -f3` -lt 51 ] +then + echo "ERROR: Your portage version is too low in your seed stage. Portage version" + echo "2.0.51 or greater is required." + exit 1 +fi + /usr/sbin/env-update source /etc/profile diff --git a/targets/stage3/stage3-chroot.sh b/targets/stage3/stage3-chroot.sh index 7865269e..7348e720 100755 --- a/targets/stage3/stage3-chroot.sh +++ b/targets/stage3/stage3-chroot.sh @@ -1,7 +1,16 @@ #!/bin/bash # Copyright 1999-2004 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo/src/catalyst/targets/stage3/stage3-chroot.sh,v 1.15 2005/01/11 14:10:19 wolf31o2 Exp $ +# $Header: /var/cvsroot/gentoo/src/catalyst/targets/stage3/stage3-chroot.sh,v 1.16 2005/01/13 22:57:25 wolf31o2 Exp $ + +portage_version=`/usr/lib/portage/bin/portageq best_version / sys-apps/portage \ + | cut -d/ -f2 | cut -d- -f2,3` +if [ `echo ${portage_version} | cut -d- -f1 | cut -d. -f3` -lt 51 ] +then + echo "ERROR: Your portage version is too low in your seed stage. Portage version" + echo "2.0.51 or greater is required." + exit 1 +fi /usr/sbin/env-update source /etc/profile