correctly check requirements if a specific version is used (package==version will check the requirement only on package, not the full requirement token.)

This commit is contained in:
Mathieu Virbel 2013-12-16 17:36:38 +01:00
parent 5a720e24c9
commit 10606c53f1
2 changed files with 4 additions and 2 deletions

View file

@ -364,7 +364,8 @@ class Buildozer(object):
target_available_packages = self.target.get_available_packages()
# remove all the requirements that the target can compile
requirements = [x for x in requirements if x not in
onlyname = lambda x: x.split('==')[0]
requirements = [x for x in requirements if onlyname(x) not in
target_available_packages]
# did we already installed the libs ?

View file

@ -344,7 +344,8 @@ class TargetAndroid(Target):
# we need to extract the requirements that python-for-android knows
# about
available_modules = self.get_available_packages()
android_requirements = [x for x in app_requirements if x in
onlyname = lambda x: x.split('==')[0]
android_requirements = [x for x in app_requirements if onlyname(x) in
available_modules]
need_compile = 0