1 |
commit: f9802e09d6f311ccc870beff6f166c51dc653aa8 |
2 |
Author: James Le Cuirot <chewi <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sun Apr 16 09:44:25 2017 +0000 |
4 |
Commit: James Le Cuirot <chewi <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Apr 27 21:41:22 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=f9802e09 |
7 |
|
8 |
cdrom.eclass: Rename CDROM_NAME_SET array to CDROM_NAMES |
9 |
|
10 |
vapier seemed confused about what he wanted this variable to do as can |
11 |
be seen in bug #139196. The eclass used it for the names of each disc, |
12 |
regardless of the set, while ebuilds used it for the name of each |
13 |
single-disc set. This was not helped by the fact that the set feature |
14 |
has been totally undocumented. The former behaviour makes more sense |
15 |
so let's rename the array to something less confusing. |
16 |
|
17 |
This will not break ebuilds already using CDROM_NAME_SET. As they all |
18 |
use just a single disc, they currently do not display the names given |
19 |
in this variable anyway. |
20 |
|
21 |
eclass/cdrom.eclass | 8 ++++---- |
22 |
1 file changed, 4 insertions(+), 4 deletions(-) |
23 |
|
24 |
diff --git a/eclass/cdrom.eclass b/eclass/cdrom.eclass |
25 |
index 4c4922fe341..29418ecb1a8 100644 |
26 |
--- a/eclass/cdrom.eclass |
27 |
+++ b/eclass/cdrom.eclass |
28 |
@@ -44,7 +44,7 @@ fi |
29 |
# etc... If you want to give the cds better names, then just export |
30 |
# the appropriate CDROM_NAME variable before calling cdrom_get_cds(). |
31 |
# Use CDROM_NAME for one cd, or CDROM_NAME_# for multiple cds. You can |
32 |
-# also use the CDROM_NAME_SET bash array. |
33 |
+# also use the CDROM_NAMES bash array. |
34 |
# |
35 |
# For those multi cd ebuilds, see the cdrom_load_next_cd() function. |
36 |
cdrom_get_cds() { |
37 |
@@ -102,12 +102,12 @@ cdrom_get_cds() { |
38 |
einfo "export CD_ROOT=/mnt/cdrom" |
39 |
echo |
40 |
else |
41 |
- if [[ -n ${CDROM_NAME_SET} ]] ; then |
42 |
- # Translate the CDROM_NAME_SET array into CDROM_NAME_# |
43 |
+ if [[ -n ${CDROM_NAMES} ]] ; then |
44 |
+ # Translate the CDROM_NAMES array into CDROM_NAME_# |
45 |
cdcnt=0 |
46 |
while [[ ${cdcnt} -lt ${CDROM_TOTAL_CDS} ]] ; do |
47 |
((++cdcnt)) |
48 |
- export CDROM_NAME_${cdcnt}="${CDROM_NAME_SET[$((${cdcnt}-1))]}" |
49 |
+ export CDROM_NAME_${cdcnt}="${CDROM_NAMES[$((${cdcnt}-1))]}" |
50 |
done |
51 |
fi |