From 01fd3210d2b103dc7596b9a9e75c9d45bc17ec49 Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Thu, 16 Jun 2011 23:57:01 +0300 Subject: [PATCH 1/3] Read metadata in sorted order to make processing stable and reproducible. --- common.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common.py b/common.py index 16825eae..1c12f94c 100644 --- a/common.py +++ b/common.py @@ -153,7 +153,7 @@ def parse_metadata(metafile, **kw): def read_metadata(verbose=False): apps = [] - for metafile in glob.glob(os.path.join('metadata', '*.txt')): + for metafile in sorted(glob.glob(os.path.join('metadata', '*.txt'))): if verbose: print "Reading " + metafile apps.append(parse_metadata(metafile, verbose=verbose)) From 39354f00b699765ecef8b946f9a82760a43f2a81 Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Fri, 17 Jun 2011 00:08:07 +0300 Subject: [PATCH 2/3] Be more verbose about build skips and failures. Dump reasons and locations. --- build.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/build.py b/build.py index 9a27a792..8621fc06 100755 --- a/build.py +++ b/build.py @@ -58,6 +58,11 @@ if not os.path.exists(built_dir): for app in apps: + if app['disabled']: + print "Skipping %s: disabled" % app['id'] + elif not app['builds']: + print "Skipping %s: no builds specified" % app['id'] + if (app['disabled'] is None and app['repo'] != '' and app['repotype'] != '' and (options.package is None or options.package == app['id']) and len(app['builds']) > 0): @@ -414,7 +419,7 @@ for app in apps: output = p.communicate()[0] if p.returncode != 0: print output - print "NDK build failed" + print "NDK build failed for %s:%s" % (app['id'], thisbuild['version']) sys.exit(1) elif options.verbose: print output @@ -434,7 +439,7 @@ for app in apps: output = p.communicate()[0] if p.returncode != 0: print output - print "Build failed" + print "Build failed for %s:%s" % (app['id'], thisbuild['version']) sys.exit(1) elif options.verbose: print output From c35de9ba77f0deffb7694dd9231fe7a328b1e809 Mon Sep 17 00:00:00 2001 From: Paul Sokolovsky Date: Fri, 17 Jun 2011 00:13:22 +0300 Subject: [PATCH 3/3] Make build directories under build/ subdir. Otherwise, top-level dir gets very crowded. --- build.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/build.py b/build.py index 8621fc06..0e6169b6 100755 --- a/build.py +++ b/build.py @@ -56,6 +56,9 @@ if options.clean: if not os.path.exists(built_dir): os.mkdir(built_dir) +if not os.path.isdir('build'): + os.makedirs('build') + for app in apps: if app['disabled']: @@ -69,7 +72,7 @@ for app in apps: print "Processing " + app['id'] - build_dir = 'build_' + app['id'] + build_dir = 'build/' + app['id'] got_source = False