Replaced distutils to shutil when copying files in a tree
This commit is contained in:
parent
9bcb006ec7
commit
4d3cf77ad5
@ -9,6 +9,12 @@ import io
|
|||||||
from shutil import copyfile
|
from shutil import copyfile
|
||||||
from pprint import pformat
|
from pprint import pformat
|
||||||
from string import Template
|
from string import Template
|
||||||
|
|
||||||
|
if sys.version_info >= (3, 8): # Python 3.8+
|
||||||
|
from shutil import copytree
|
||||||
|
def copy_tree(src, dst):
|
||||||
|
copytree(src, dst, dirs_exist_ok=True)
|
||||||
|
else:
|
||||||
from distutils.dir_util import copy_tree
|
from distutils.dir_util import copy_tree
|
||||||
|
|
||||||
try:
|
try:
|
||||||
|
|||||||
@ -34,6 +34,11 @@ Adding --dynamic parameter will build {framework_name}.framework as App Store dy
|
|||||||
from __future__ import print_function, unicode_literals
|
from __future__ import print_function, unicode_literals
|
||||||
import glob, os, os.path, shutil, string, sys, argparse, traceback, multiprocessing, codecs, io
|
import glob, os, os.path, shutil, string, sys, argparse, traceback, multiprocessing, codecs, io
|
||||||
from subprocess import check_call, check_output, CalledProcessError
|
from subprocess import check_call, check_output, CalledProcessError
|
||||||
|
|
||||||
|
if sys.version_info >= (3, 8): # Python 3.8+
|
||||||
|
def copy_tree(src, dst):
|
||||||
|
shutil.copytree(src, dst, dirs_exist_ok=True)
|
||||||
|
else:
|
||||||
from distutils.dir_util import copy_tree
|
from distutils.dir_util import copy_tree
|
||||||
|
|
||||||
sys.path.insert(0, os.path.abspath(os.path.abspath(os.path.dirname(__file__))+'/../apple'))
|
sys.path.insert(0, os.path.abspath(os.path.abspath(os.path.dirname(__file__))+'/../apple'))
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user