2016-10-19 17:57:33 +02:00
|
|
|
Index: VirtualBox-5.1.8/src/libs/xpcom18a4/python/gen_python_deps.py
|
2014-01-19 01:52:50 +01:00
|
|
|
===================================================================
|
2016-10-19 17:57:33 +02:00
|
|
|
--- VirtualBox-5.1.8.orig/src/libs/xpcom18a4/python/gen_python_deps.py
|
|
|
|
+++ VirtualBox-5.1.8/src/libs/xpcom18a4/python/gen_python_deps.py
|
|
|
|
@@ -86,7 +86,7 @@ def main(argv):
|
2011-02-08 08:32:31 +01:00
|
|
|
else:
|
|
|
|
multi = 1
|
|
|
|
|
|
|
|
- if multi == 0:
|
|
|
|
+ if not multi:
|
|
|
|
prefixes = ["/usr"]
|
2016-10-19 17:57:33 +02:00
|
|
|
versions = [str(sys.version_info[0])+'.'+str(sys.version_info[1]),
|
|
|
|
str(sys.version_info[0])+'.'+str(sys.version_info[1])+'m']
|
|
|
|
@@ -114,24 +114,25 @@ def main(argv):
|
2016-07-26 18:15:55 +02:00
|
|
|
continue
|
2011-02-08 08:32:31 +01:00
|
|
|
for p in prefixes:
|
|
|
|
c = checkPair(p, v, dllpre, dllsuff, bitness_magic)
|
|
|
|
- if c is not None:
|
|
|
|
+ if c:
|
|
|
|
known[v] = c
|
|
|
|
break
|
2016-07-26 18:15:55 +02:00
|
|
|
- keys = list(known.keys())
|
2011-02-08 08:32:31 +01:00
|
|
|
- # we want default to be the lowest versioned Python
|
|
|
|
- keys.sort()
|
|
|
|
- d = None
|
|
|
|
# We need separator other than newline, to sneak through $(shell)
|
|
|
|
sep = "|"
|
|
|
|
- for k in keys:
|
|
|
|
- if d is None:
|
|
|
|
- d = k
|
2016-09-16 10:32:23 +02:00
|
|
|
- vers = k.replace('.', '').upper()
|
2011-02-08 08:32:31 +01:00
|
|
|
- print_vars(vers, known[k], sep, bitness_magic)
|
|
|
|
- if d is not None:
|
|
|
|
- print_vars("DEF", known[d], sep, bitness_magic)
|
|
|
|
+
|
|
|
|
+ if not known:
|
|
|
|
+ # this type of problem should be detected in configure
|
|
|
|
+ # print_vars("DEF", defaultpaths, sep, bitness_magic)
|
|
|
|
+ pass
|
2016-10-19 17:57:33 +02:00
|
|
|
else:
|
|
|
|
print(argv[0] + ": No Python development package found!", file=sys.stderr)
|
2011-02-08 08:32:31 +01:00
|
|
|
+ if multi:
|
|
|
|
+ for ver, paths in known.items():
|
2016-09-16 10:32:23 +02:00
|
|
|
+ print_vars(ver.replace('.', '').upper(), paths, sep, bitness_magic)
|
2011-02-08 08:32:31 +01:00
|
|
|
+ else:
|
|
|
|
+ ver = versions[0]
|
|
|
|
+ paths = known[ver]
|
|
|
|
+ print_vars(ver.replace('.', ''), paths, sep, bitness_magic)
|
|
|
|
|
|
|
|
if __name__ == '__main__':
|
|
|
|
main(sys.argv)
|