diff options
author | John Mylchreest <johnm@gentoo.org> | 2005-06-30 17:27:02 +0000 |
---|---|---|
committer | John Mylchreest <johnm@gentoo.org> | 2005-06-30 17:27:02 +0000 |
commit | 705e9780d67bea524b0c1745fadf6525eca4f643 (patch) | |
tree | cdaf6d88a1187b1f25ce6bea50a93bb6aab0d41c /sys-kernel | |
parent | Fix use invocation (diff) | |
download | historical-705e9780d67bea524b0c1745fadf6525eca4f643.tar.gz historical-705e9780d67bea524b0c1745fadf6525eca4f643.tar.bz2 historical-705e9780d67bea524b0c1745fadf6525eca4f643.zip |
Moving root check. Fixing bug #94424 - thanks mostly to Timothy Kilbourn.
Package-Manager: portage-2.0.51.22-r1
Diffstat (limited to 'sys-kernel')
-rw-r--r-- | sys-kernel/module-rebuild/ChangeLog | 9 | ||||
-rw-r--r-- | sys-kernel/module-rebuild/Manifest | 14 | ||||
-rw-r--r-- | sys-kernel/module-rebuild/files/digest-module-rebuild-0.3 (renamed from sys-kernel/module-rebuild/files/digest-module-rebuild-0.2) | 0 | ||||
-rwxr-xr-x | sys-kernel/module-rebuild/files/module-rebuild-0.3 (renamed from sys-kernel/module-rebuild/files/module-rebuild-0.2) | 38 | ||||
-rw-r--r-- | sys-kernel/module-rebuild/module-rebuild-0.3.ebuild (renamed from sys-kernel/module-rebuild/module-rebuild-0.2.ebuild) | 2 |
5 files changed, 37 insertions, 26 deletions
diff --git a/sys-kernel/module-rebuild/ChangeLog b/sys-kernel/module-rebuild/ChangeLog index 1c7799fdaf11..b4acaf5a9548 100644 --- a/sys-kernel/module-rebuild/ChangeLog +++ b/sys-kernel/module-rebuild/ChangeLog @@ -1,6 +1,13 @@ # ChangeLog for sys-kernel/module-rebuild # Copyright 1999-2005 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/sys-kernel/module-rebuild/ChangeLog,v 1.3 2005/05/19 17:40:00 dang Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-kernel/module-rebuild/ChangeLog,v 1.4 2005/06/30 17:27:02 johnm Exp $ + +*module-rebuild-0.3 (30 Jun 2005) + + 30 Jun 2005; John Mylchreest <johnm@gentoo.org> -files/module-rebuild-0.2, + +files/module-rebuild-0.3, -module-rebuild-0.2.ebuild, + +module-rebuild-0.3.ebuild: + Moving root check. Fixing bug #94424 - thanks mostly to Timothy Kilbourn. 19 May 2005; <dang@gentoo.org> module-rebuild-0.2.ebuild: Added ~amd64 diff --git a/sys-kernel/module-rebuild/Manifest b/sys-kernel/module-rebuild/Manifest index 84503b3499d7..24a4c790e687 100644 --- a/sys-kernel/module-rebuild/Manifest +++ b/sys-kernel/module-rebuild/Manifest @@ -1,18 +1,18 @@ -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 -MD5 e4528ac1b48b6761df5530f5a3c827c2 module-rebuild-0.2.ebuild 477 MD5 ea0963c42faaa0ae11ab458207259875 module-rebuild-0.1.ebuild 472 -MD5 34937bdd4693e594dc01a553930b1a9b ChangeLog 745 +MD5 9083bb199ee180c12ed5fb575b1543f7 module-rebuild-0.3.ebuild 478 +MD5 527572b8737f17a62b79e501e93e3db0 ChangeLog 1022 MD5 4f16a183ffde9bcb9ad32bc19fafa1aa metadata.xml 526 MD5 2a7d0f8657e4bd140b33d1cd4a6a81d9 files/module-rebuild-0.1 4381 -MD5 be437effac25aad429f612c4db2390e8 files/module-rebuild-0.2 5618 +MD5 3a02ecf4e5fd37282e54011daaafc3cc files/module-rebuild-0.3 5697 MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-module-rebuild-0.1 0 -MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-module-rebuild-0.2 0 +MD5 d41d8cd98f00b204e9800998ecf8427e files/digest-module-rebuild-0.3 0 -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.1 (GNU/Linux) -iD8DBQFCjM+QomPajV0RnrERAkJjAJ99UQ2cN6aZMzitGaF0UIQxOqr3dwCdEvwT -lwi8nqmZU1uhyyHT6Pm1L/U= -=Dqg2 +iD8DBQFCxCtnz7mlh8wQzGMRAop7AJ0QJvqo2ytBInmg1bxB/gfskNxOGwCgi64w ++CtZuHFM8/JLHXhS/fJ4j1g= +=fp8Q -----END PGP SIGNATURE----- diff --git a/sys-kernel/module-rebuild/files/digest-module-rebuild-0.2 b/sys-kernel/module-rebuild/files/digest-module-rebuild-0.3 index e69de29bb2d1..e69de29bb2d1 100644 --- a/sys-kernel/module-rebuild/files/digest-module-rebuild-0.2 +++ b/sys-kernel/module-rebuild/files/digest-module-rebuild-0.3 diff --git a/sys-kernel/module-rebuild/files/module-rebuild-0.2 b/sys-kernel/module-rebuild/files/module-rebuild-0.3 index 42bdc7c035c1..d70d29966e1c 100755 --- a/sys-kernel/module-rebuild/files/module-rebuild-0.2 +++ b/sys-kernel/module-rebuild/files/module-rebuild-0.3 @@ -7,7 +7,12 @@ # Written by John Mylchreest (johnm@gentoo.org) # Copyright Gentoo Linux -R_VERSION="0.2" +if [[ `id -u` != 0 ]]; then + echo "This application must be ran as root." + exit 1 +fi + +R_VERSION="0.3" R_MODULES="${ROOT}/usr/share/module-rebuild/moduledb" R_PORTAGEQ="`which portageq 2>/dev/null`" if [[ -z ${R_PORTAGEQ} ]]; then @@ -31,13 +36,13 @@ package_valid() { package_valid_strict() { local package=${1} - package_valid ${package} && [[ -z ${package//*-[0-9]*} ]] && return 0 || return 1 + package_valid ${package} && [[ -z ${package%-[0-9]*} ]] && return 0 || return 1 } package_exists() { local package=${1} - package=${package//-[0-9]*} + package=${package%-[0-9]*} if $(${R_PORTAGEQ} has_version / ${package}); then return 0 else @@ -128,16 +133,20 @@ db_module_list() { echo -e "${C_BOLD}${C_RED}** There are no known modules. Quitting.${C_NORM}" exit 1 fi - - echo -e "${C_BOLD}${C_GREEN}** Packages which I will emerge are:${C_NORM}" - for pkg in ${tomerge[@]}; do - echo -e "\t${pkg}" - done - echo -e "${C_BOLD}${C_GREEN}** Packages which I will ignore are:${C_NORM}" - for pkg in ${toignore[@]}; do - echo -e "\t${pkg}" - done + if [[ -n ${tomerge[@]} ]]; then + echo -e "${C_BOLD}${C_GREEN}** Packages which I will emerge are:${C_NORM}" + for pkg in ${tomerge[@]}; do + echo -e "\t${pkg}" + done + fi + + if [[ -n ${toignore[@]} ]]; then + echo -e "${C_BOLD}${C_GREEN}** Packages which I will ignore are:${C_NORM}" + for pkg in ${toignore[@]}; do + echo -e "\t${pkg}" + done + fi } db_module_populate() { @@ -209,11 +218,6 @@ EOF } -if [[ `id -u` != 0 ]]; then - echo "This application must be ran as root." - exit 1 -fi - if [[ ! -f ${ROOT}/usr/share/module-rebuild/moduledb ]]; then [[ ! -d ${ROOT}/usr/share/module-rebuild/ ]] && mkdir ${ROOT}/usr/share/module-rebuild/ touch ${ROOT}/usr/share/module-rebuild/moduledb diff --git a/sys-kernel/module-rebuild/module-rebuild-0.2.ebuild b/sys-kernel/module-rebuild/module-rebuild-0.3.ebuild index 0d662f291f63..c0d0d56c39c4 100644 --- a/sys-kernel/module-rebuild/module-rebuild-0.2.ebuild +++ b/sys-kernel/module-rebuild/module-rebuild-0.3.ebuild @@ -1,6 +1,6 @@ # Copyright 1999-2005 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/sys-kernel/module-rebuild/module-rebuild-0.2.ebuild,v 1.2 2005/05/19 17:40:00 dang Exp $ +# $Header: /var/cvsroot/gentoo-x86/sys-kernel/module-rebuild/module-rebuild-0.3.ebuild,v 1.1 2005/06/30 17:27:02 johnm Exp $ DESCRIPTION="A utility to rebuild any kernel modules which you have installed." HOMEPAGE="http://www.gentoo.org/" |