chiark / gitweb /
Add check for unbuilt jni to scanner
authorCiaran Gultnieks <ciaran@ciarang.com>
Fri, 13 Jan 2012 19:28:49 +0000 (19:28 +0000)
committerCiaran Gultnieks <ciaran@ciarang.com>
Fri, 13 Jan 2012 19:28:49 +0000 (19:28 +0000)
scanner.py

index f4d63e350bea75de8d5655312aa69777208dd4f7..2f30b439cc3b2250d768b0115be68be78a5779ba 100755 (executable)
@@ -102,6 +102,14 @@ for app in apps:
                                 msg += ' in ' + app['id'] + ' ' + thisbuild['version']
                                 problems.append(msg)
 
+                    # Presence of a jni directory without buildjni=yes might
+                    # indicate a problem...
+                    if (os.path.exists(os.path.join(root_dir, 'jni')) and 
+                            thisbuild.get('buildjni', 'no') != 'yes'):
+                        msg = 'Found jni directory, but buildjni is not enabled'
+                        msg += ' in ' + app['id'] + ' ' + thisbuild['version']
+                        problems.append(msg)
+
         except BuildException as be:
             msg = "Could not scan app %s due to BuildException: %s" % (app['id'], be)
             problems.append(msg)