From d846f7e966ebb885dfe109919045e55f33d41e93 Mon Sep 17 00:00:00 2001 From: Ben Rousch Date: Tue, 29 Oct 2013 13:28:40 -0400 Subject: [PATCH] Added --private and --dir Android storage option --- buildozer/default.spec | 3 +++ buildozer/targets/android.py | 4 +++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/buildozer/default.spec b/buildozer/default.spec index 6a0c83c..3345a61 100644 --- a/buildozer/default.spec +++ b/buildozer/default.spec @@ -66,6 +66,9 @@ fullscreen = 1 # (str) Android NDK version to use #android.ndk = 9 +# (bool) Use --private data storage (True) or --dir public storage (False) +#android.privatestorage = True + # (str) Android NDK directory (if empty, it will be automatically downloaded.) #android.ndk_path = diff --git a/buildozer/targets/android.py b/buildozer/targets/android.py index a3e1e55..153ebec 100644 --- a/buildozer/targets/android.py +++ b/buildozer/targets/android.py @@ -403,13 +403,15 @@ class TargetAndroid(Target): '{python} build.py --name {name}' ' --version {version}' ' --package {package}' - ' --private {appdir}' + ' --{storage_type} {appdir}' ' --sdk {androidsdk}' ' --minsdk {androidminsdk}').format( python=executable, name=quote(config.get('app', 'title')), version=version, package=package, + storage_type='private' if config.getbooldefault( + 'app', 'android.privatestorage', True) else 'dir', appdir=self.buildozer.app_dir, androidminsdk=config.getdefault( 'app', 'android.minsdk', 8),