From bf6b88de3dd5de14abc3e025b685fc3d507a1ef1 Mon Sep 17 00:00:00 2001 From: Kjell Wooding Date: Thu, 17 Jan 2019 00:46:03 -0500 Subject: [PATCH] support the --add-frameworks flag in kivy-ios --- buildozer/targets/ios.py | 16 ++++++++++------ 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/buildozer/targets/ios.py b/buildozer/targets/ios.py index 3247278..a20ae54 100644 --- a/buildozer/targets/ios.py +++ b/buildozer/targets/ios.py @@ -180,15 +180,19 @@ class TargetIos(Target): app_name = self.buildozer.namify(self.buildozer.config.get('app', 'package.name')) + ios_frameworks = self.buildozer.config.getlist('app', 'ios.frameworks', '') + frameworks_cmd = '' + for framework in ios_frameworks: + frameworks_cmd += '--add-framework={} '.format(framework) + self.app_project_dir = join(self.ios_dir, '{0}-ios'.format(app_name.lower())) if not self.buildozer.file_exists(self.app_project_dir): - self.buildozer.cmd('./toolchain.py create {0} {1}'.format( - app_name, self.buildozer.app_dir), - cwd=self.ios_dir) + create_cmd = './toolchain.py create {0}{1} {2}'.format(frameworks_cmd, app_name, + self.buildozer.app_dir) + self.buildozer.cmd(create_cmd, cwd=self.ios_dir) else: - self.buildozer.cmd('./toolchain.py update {0}-ios'.format( - app_name), - cwd=self.ios_dir) + update_cmd = './toolchain.py update {0}{1}-ios'.format(frameworks_cmd, app_name) + self.buildozer.cmd(update_cmd, cwd=self.ios_dir) # fix the plist plist_fn = '{}-Info.plist'.format(app_name.lower())