VirtualBox

Changeset 99206 in vbox for trunk/src/libs/xpcom18a4/python


Ignore:
Timestamp:
Mar 29, 2023 11:52:22 AM (22 months ago)
Author:
vboxsync
Message:

xpcom18a4/python: Avoid distutils starting with python 3.10.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/libs/xpcom18a4/python/gen_python_deps.py

    r98103 r99206  
    2525from __future__ import print_function
    2626import os,sys
    27 from distutils.version import StrictVersion
     27if sys.version_info >= (3, 10)
     28    from packaging.version import Version
     29else:
     30    from distutils.version import StrictVersion as Version
    2831
    2932versions = ["2.6", "2.7", "3.1", "3.2", "3.2m", "3.3", "3.3m", "3.4", "3.4m", "3.5", "3.5m", "3.6", "3.6m", "3.7", "3.7m", "3.8", "3.8m", "3.9", "3.9m", "3.10", "3.10m", "3.11", "3.11m" ]
     
    121124        else:
    122125            realversion = v
    123         if StrictVersion(realversion) < StrictVersion('2.6'):
     126        if Version(realversion) < Version('2.6'):
    124127            continue
    125128        for p in prefixes:
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette