mirror of
https://github.com/f-droid/fdroidserver.git
synced 2025-09-13 22:42:29 +03:00
A few minor scanner improvements
This commit is contained in:
parent
e906cf2c64
commit
e15baaffcb
1 changed files with 13 additions and 10 deletions
23
scanner.py
23
scanner.py
|
@ -93,18 +93,19 @@ for app in apps:
|
||||||
refreshed_source = True
|
refreshed_source = True
|
||||||
|
|
||||||
# Scan for common known non-free blobs:
|
# Scan for common known non-free blobs:
|
||||||
usual_suspects = ['flurryagent.jar',
|
usual_suspects = ['flurryagent',
|
||||||
'paypal_mpl.jar',
|
'paypal_mpl',
|
||||||
'libgoogleanalytics.jar',
|
'libgoogleanalytics',
|
||||||
'admob-sdk-android.jar',
|
'admob-sdk-android',
|
||||||
'googleadview.jar',
|
'googleadview',
|
||||||
'googleadmobadssdk-4.3.1.jar']
|
'googleadmobadssdk']
|
||||||
for r,d,f in os.walk(build_dir):
|
for r,d,f in os.walk(build_dir):
|
||||||
for curfile in f:
|
for curfile in f:
|
||||||
if curfile.lower() in usual_suspects:
|
for suspect in usual_suspects:
|
||||||
msg = 'Found probable non-free blob ' + os.path.join(r, curfile)
|
if curfile.lower().find(suspect) != -1:
|
||||||
msg += ' in ' + app['id'] + ' ' + thisbuild['version']
|
msg = 'Found probable non-free blob ' + os.path.join(r, curfile)
|
||||||
problems.append(msg)
|
msg += ' in ' + app['id'] + ' ' + thisbuild['version']
|
||||||
|
problems.append(msg)
|
||||||
|
|
||||||
# Presence of a jni directory without buildjni=yes might
|
# Presence of a jni directory without buildjni=yes might
|
||||||
# indicate a problem...
|
# indicate a problem...
|
||||||
|
@ -118,9 +119,11 @@ for app in apps:
|
||||||
# shouldn't be there and mess up our source tarballs...
|
# shouldn't be there and mess up our source tarballs...
|
||||||
if os.path.exists(os.path.join(root_dir, 'bin')):
|
if os.path.exists(os.path.join(root_dir, 'bin')):
|
||||||
msg = "There shouldn't be a bin directory"
|
msg = "There shouldn't be a bin directory"
|
||||||
|
msg += ' in ' + app['id'] + ' ' + thisbuild['version']
|
||||||
problems.append(msg)
|
problems.append(msg)
|
||||||
if os.path.exists(os.path.join(root_dir, 'gen')):
|
if os.path.exists(os.path.join(root_dir, 'gen')):
|
||||||
msg = "There shouldn't be a gen directory"
|
msg = "There shouldn't be a gen directory"
|
||||||
|
msg += ' in ' + app['id'] + ' ' + thisbuild['version']
|
||||||
problems.append(msg)
|
problems.append(msg)
|
||||||
|
|
||||||
except BuildException as be:
|
except BuildException as be:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue