chiark / gitweb /
Fix silly object name issue, also clean jni dirs
authorDaniel Martí <mvdan@mvdan.cc>
Thu, 10 Oct 2013 14:30:32 +0000 (16:30 +0200)
committerDaniel Martí <mvdan@mvdan.cc>
Thu, 10 Oct 2013 14:30:32 +0000 (16:30 +0200)
fdroidserver/build.py
fdroidserver/common.py

index d9cb830923b129da23726119e9f75ac4dbce1994..39e233e4d035875bdcf00a980f12f7f0bdd56505 100644 (file)
@@ -390,6 +390,16 @@ def build_local(app, thisbuild, vcs, build_dir, output_dir, srclib_dir, extlib_d
         else:
             error += line
 
+    # Also clean jni
+    print "Cleaning jni dirs..."
+    for baddir in [
+            'libs/armeabi-v7a', 'libs/armeabi',
+            'libs/mips', 'libs/x86']:
+        badpath = os.path.join(build_dir, baddir)
+        if os.path.exists(badpath):
+            print "Removing '%s'" % badpath
+            shutil.rmtree(badpath)
+
     # Scan before building...
     print "Scanning source for common problems..."
     buildprobs = common.scan_source(build_dir, root_dir, thisbuild)
index 3bb6c491be2bd92a24073dce9fd600ff62ded569..62bf816fdc7f3ba0d64431de224bfb97a05ad0b1 100644 (file)
@@ -1208,7 +1208,7 @@ def prepare_source(vcs, app, build, build_dir, srclib_dir, extlib_dir, sdk_path,
         p.communicate()
         if p.returncode != 0:
             raise BuildException("Error running init command for %s:%s" %
-                    (app['id'], thisbuild['version']), output, error)
+                    (app['id'], build['version']), output, error)
 
     # Generate (or update) the ant build file, build.xml...
     updatemode = build.get('update', '.')
@@ -1430,7 +1430,7 @@ def prepare_source(vcs, app, build, build_dir, srclib_dir, extlib_dir, sdk_path,
         p.communicate()
         if p.returncode != 0:
             raise BuildException("Error running prebuild command for %s:%s" %
-                    (app['id'], thisbuild['version']), output, error)
+                    (app['id'], build['version']), output, error)
     print "Applying generic clean-ups..."
 
     if build.get('anal-tics', 'no') == 'yes':