public inbox for gentoo-catalyst@lists.gentoo.org
 help / color / mirror / Atom feed
From: Brian Dolbec <dolsen@gentoo.org>
To: catalyst@gentoo.org, gentoo-catalyst@lists.gentoo.org
Subject: [gentoo-catalyst] [PATCH 3/7] stage1-controller.sh: Fix portage bin path hard coding
Date: Mon,  1 Sep 2014 19:31:37 -0700	[thread overview]
Message-ID: <1409625101-27112-4-git-send-email-dolsen@gentoo.org> (raw)
In-Reply-To: <1409625101-27112-1-git-send-email-dolsen@gentoo.org>

[-- Attachment #1: Type: text/plain, Size: 225 bytes --]


Also rework to use find's filters instead of piping several times through grep.
Code supplied by: Douglas Freed <dwfreed>
---
 targets/stage1/stage1-controller.sh | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0003-stage1-controller.sh-Fix-portage-bin-path-hard-codin.patch --]
[-- Type: text/x-patch; name="0003-stage1-controller.sh-Fix-portage-bin-path-hard-codin.patch", Size: 699 bytes --]

diff --git a/targets/stage1/stage1-controller.sh b/targets/stage1/stage1-controller.sh
index 8dbd16b..1b2eee2 100755
--- a/targets/stage1/stage1-controller.sh
+++ b/targets/stage1/stage1-controller.sh
@@ -33,9 +33,9 @@ case $1 in
 		find . -iname "*.py[co]" -exec rm -f {} \;
 		# Cleanup all .a files except libgcc.a, *_nonshared.a and
 		# /usr/lib/portage/bin/*.a
-		find . -type f -iname "*.a" | grep -v 'libgcc.a' | \
-			grep -v 'nonshared.a' | grep -v '/usr/lib/portage/bin/' | \
-			grep -v 'libgcc_eh.a' | xargs rm -f
+		find . -path usr/lib/portage -prune -o -type f \
+			-iname '*.a' ! -name 'libgcc.a' ! -name '*nonshared.a' \
+			! -name 'libgcc_eh.a' -print | xargs rm -f
 	;;
 
 	*)

  parent reply	other threads:[~2014-09-02  2:33 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-02  2:31 [gentoo-catalyst] [PATCH 0/7] Pending branch patches (various) Brian Dolbec
2014-09-02  2:31 ` [gentoo-catalyst] [PATCH 1/7] Remove unused urllib import Brian Dolbec
2014-09-02  5:22   ` W. Trevor King
2014-09-02  2:31 ` [gentoo-catalyst] [PATCH 2/7] Remove unused variable new and an undefined variable s Brian Dolbec
2014-09-02  5:43   ` W. Trevor King
2014-09-05 18:16     ` W. Trevor King
2014-09-02  2:31 ` Brian Dolbec [this message]
2014-09-02  3:35   ` [gentoo-catalyst] [PATCH 3/7] stage1-controller.sh: Fix portage bin path hard coding Rick "Zero_Chaos" Farina
2014-09-02  5:05   ` [gentoo-catalyst] [PATCH v2] stage1-controller.sh: Remove some old poor cleaning code Brian Dolbec
2014-09-02  5:19     ` [gentoo-catalyst] [PATCH v2 3/7] " Brian Dolbec
2014-09-02  5:31     ` [gentoo-catalyst] [PATCH v2] " W. Trevor King
2014-09-09 18:38     ` Brian Dolbec
2014-09-10 17:16       ` Rick "Zero_Chaos" Farina
2014-09-10 21:00         ` Anthony G. Basile
2014-09-02  2:31 ` [gentoo-catalyst] [PATCH 4/7] chroot-functions.sh: Remove --nodeps option from portage update Brian Dolbec
2014-09-02  2:31 ` [gentoo-catalyst] [PATCH 5/7] chroot-functions.sh: Fix a mis-worded comment Brian Dolbec
2014-09-02  2:31 ` [gentoo-catalyst] [PATCH 6/7] setup_pkgmgr(): WIP Make the 'build' use flag optional Brian Dolbec
2014-09-09 18:27   ` Brian Dolbec
2014-09-02  2:31 ` [gentoo-catalyst] [PATCH 7/7] Fix a relative path bug Brian Dolbec
2014-09-02  5:06   ` W. Trevor King
2014-09-02  5:26     ` Brian Dolbec
2014-09-09 17:20       ` Brian Dolbec
2014-09-11  3:30 ` [gentoo-catalyst] [PATCH 0/7] Pending branch patches (various) Brian Dolbec

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1409625101-27112-4-git-send-email-dolsen@gentoo.org \
    --to=dolsen@gentoo.org \
    --cc=catalyst@gentoo.org \
    --cc=gentoo-catalyst@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox