changeset 17013:0b2675391d01

mx library: support platform/architecture specific libraries
author Bernhard Urban <bernhard.urban@jku.at>
date Tue, 02 Sep 2014 14:46:22 +0200
parents ad10671d1bbd
children 6a30738791f7
files mxtool/mx.py
diffstat 1 files changed, 5 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/mxtool/mx.py	Tue Sep 02 14:45:51 2014 +0200
+++ b/mxtool/mx.py	Tue Sep 02 14:46:22 2014 +0200
@@ -905,6 +905,11 @@
             self.jreLibs.append(l)
 
         for name, attrs in libsMap.iteritems():
+            if "|" in name:
+                assert name.count("|") == 2, "syntax: libname|os-platform|architecture"
+                name, platform, architecture = name.split("|")
+                if platform != get_os() or architecture != get_arch():
+                    continue
             path = attrs.pop('path')
             urls = pop_list(attrs, 'urls')
             sha1 = attrs.pop('sha1', None)