From: Rob Cakebread Date: Wed, 23 Jul 2008 22:40:36 +0000 (+0000) Subject: Use ~x86 if absolutely no ACCEPT_KEYWORDS found. X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=16c79cbe7e8310d6f3e517dd9d896620074fdf7a;p=g-pypi.git Use ~x86 if absolutely no ACCEPT_KEYWORDS found. git-svn-id: http://g-pypi.googlecode.com/svn/trunk@4 118783bc-b352-0410-bbc3-0f610f6f7ae8 --- diff --git a/g_pypi/portage_utils.py b/g_pypi/portage_utils.py index ee0e724..c2f6a88 100644 --- a/g_pypi/portage_utils.py +++ b/g_pypi/portage_utils.py @@ -191,8 +191,12 @@ def get_portdir(): def get_keyword(): """Return first ACCEPT_KEYWORDS from /etc/make.conf""" #Choose the first arch they have, in case of multiples. - - arch = ENV["ACCEPT_KEYWORDS"].split(' ')[0] + + try: + arch = ENV["ACCEPT_KEYWORDS"].split(' ')[0] + except KeyError: + self.logger.error("No ACCEPT_KEYWORDS found, using ~x86") + arch = '~x86' #New ebuilds must be ~arch