summaryrefslogtreecommitdiff
path: root/python/build/boost.py
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2015-12-16 00:05:17 +0100
committerMax Kellermann <max@duempel.org>2015-12-16 00:05:21 +0100
commitcb1e64423016108ce0be8d484133e01d2c154512 (patch)
tree86c7460f5e3acbabe1241f54fc83ecce4a7e813c /python/build/boost.py
parent9bc0fada5c6737e255d63762da5caa43cafccfc2 (diff)
python/boost: use shutil.copytree()
Diffstat (limited to 'python/build/boost.py')
-rw-r--r--python/build/boost.py14
1 files changed, 3 insertions, 11 deletions
diff --git a/python/build/boost.py b/python/build/boost.py
index 0a68d7c2a..26cdfae4f 100644
--- a/python/build/boost.py
+++ b/python/build/boost.py
@@ -18,14 +18,6 @@ class BoostProject(Project):
# install the headers manually; don't build any library
# (because right now, we only use header-only libraries)
includedir = os.path.join(toolchain.install_prefix, 'include')
- for dirpath, dirnames, filenames in os.walk(os.path.join(src, 'boost')):
- relpath = dirpath[len(src)+1:]
- destdir = os.path.join(includedir, relpath)
- try:
- os.mkdir(destdir)
- except:
- pass
- for name in filenames:
- if name[-4:] == '.hpp':
- shutil.copyfile(os.path.join(dirpath, name),
- os.path.join(destdir, name))
+ dest = os.path.join(includedir, 'boost')
+ shutil.rmtree(dest, ignore_errors=True)
+ shutil.copytree(os.path.join(src, 'boost'), dest)