Skip to content

Added temporary fix for buildozer 0.32 #824

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 6, 2016
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions pythonforandroid/toolchain.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,18 @@ def _get_option_tuples(self, option_string):
class ToolchainCL(object):

def __init__(self):

argv = sys.argv
# Buildozer used to pass these arguments in a now-invalid order
# If that happens, apply this fix
# This fix will be removed once a fixed buildozer is released
if (len(argv) > 2 and
argv[1].startswith('--color') and
argv[2].startswith('--storage-dir') and
argv[3] == 'apk'):
argv.append(argv.pop(1)) # the --color arg
argv.append(argv.pop(1)) # the --storage-dir arg

parser = NoAbbrevParser(
description=('A packaging tool for turning Python scripts and apps '
'into Android APKs'))
Expand Down