1 |
commit: f92d7f194f0abffc587b0b3112cd3a8890657cc2 |
2 |
Author: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
3 |
AuthorDate: Thu Mar 28 16:19:20 2013 +0000 |
4 |
Commit: Mike Frysinger <vapier <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Mar 28 16:19:20 2013 +0000 |
6 |
URL: http://git.overlays.gentoo.org/gitweb/?p=proj/crossdev.git;a=commit;h=f92d7f19 |
7 |
|
8 |
crossdev: set up categories in the output overlay too |
9 |
|
10 |
For tools that operate on the repo level (like egencache), make sure |
11 |
we have a categories file set up in there since they won't search the |
12 |
/etc/portage system path. |
13 |
|
14 |
URL: http://bugs.gentoo.org/460106 |
15 |
Reported-by: Dennis Schridde <devurandom <AT> gmx.net> |
16 |
Signed-off-by: Mike Frysinger <vapier <AT> gentoo.org> |
17 |
|
18 |
--- |
19 |
crossdev | 18 ++++++++++-------- |
20 |
1 files changed, 10 insertions(+), 8 deletions(-) |
21 |
|
22 |
diff --git a/crossdev b/crossdev |
23 |
index 3cab8c3..193ac4e 100755 |
24 |
--- a/crossdev |
25 |
+++ b/crossdev |
26 |
@@ -967,16 +967,18 @@ set_metadata() { |
27 |
EOF |
28 |
} |
29 |
|
30 |
-mkdir -p "${CONFIGROOT}" |
31 |
-check_trailing_newline "${CONFIGROOT}"/categories |
32 |
-grep -qs "^cross-${CTARGET}$" "${CONFIGROOT}"/categories \ |
33 |
- || echo cross-${CTARGET} >> "${CONFIGROOT}"/categories |
34 |
-mkdir -p "${CROSSDEV_OVERLAY}"/cross-${CTARGET} || exit 1 |
35 |
-cd "${CONFIGROOT}" |
36 |
+mkdir -p "${CONFIGROOT}" "${CROSSDEV_OVERLAY}"/{cross-${CTARGET},profiles} || die "wtf!?" |
37 |
+for f in "${CONFIGROOT}" "${CROSSDEV_OVERLAY}"/profiles ; do |
38 |
+ f+="/categories" |
39 |
+ check_trailing_newline "${f}" |
40 |
+ grep -qs "^cross-${CTARGET}$" "${f}" \ |
41 |
+ || echo cross-${CTARGET} >> "${f}" |
42 |
+done |
43 |
+cd "${CONFIGROOT}" || die "wtf!?" |
44 |
for f in package.{env,keywords,mask,use} env/cross-${CTARGET} profile/package.use.{force,mask} ; do |
45 |
[[ -f ${f} ]] && die "please convert ${CONFIGROOT}/${f} to a directory" |
46 |
- mkdir -p ${f} || die "wtf!?" |
47 |
- rm -f ${f}/cross-${CTARGET} |
48 |
+ mkdir -p "${f}" || die "wtf!?" |
49 |
+ rm -f "${f}/cross-${CTARGET}" |
50 |
done |
51 |
|
52 |
for v in B G K L D ; do |