diff options
author | Dan Albert <danalbert@google.com> | 2018-10-25 13:36:51 -0700 |
---|---|---|
committer | Dan Albert <danalbert@google.com> | 2018-10-25 14:46:28 -0700 |
commit | dae41c79f8a14808071870bba73201f1d90ccfed (patch) | |
tree | 83ba0cbc06557d1bc950182a93c81982b4b2e66a /checkbuild.py | |
parent | 14f83f0357bce4e2cc178f3a93c769ae1e8032c0 (diff) | |
download | ndk-dae41c79f8a14808071870bba73201f1d90ccfed.tar.gz |
Put the new toolchain back in to toolchains/llvm.
Moving this to an entirely separate directory will likely be too
disruptive. While not very difficult to fix in any given build system,
there's a significant number of third-party projects that do not even
use standalone toolchains. Those few of them using Clang can be kept
working for the time being (they'll still break when we remove
$NDK/sysroot if they're using `--sysroot` like they should be rather
than `-isystem`).
This also saves us a small amount of space in the transition period.
Although we still need to duplicate binutils, libc++, the sysroot,
etc, we can at least dedup Clang.
Test: ./checkbuild.py && ./run_tests.py
Bug: https://github.com/android-ndk/ndk/issues/780
Change-Id: I5760e55240fc3ff0ed2fe5385b8dca9394327dd1
Diffstat (limited to 'checkbuild.py')
-rwxr-xr-x | checkbuild.py | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/checkbuild.py b/checkbuild.py index 6a85d1f3e..ddcde98dd 100755 --- a/checkbuild.py +++ b/checkbuild.py @@ -1483,7 +1483,8 @@ class BaseToolchain(ndk.builds.Module): """ name = 'base-toolchain' - path = 'toolchain' + # This is installed to the Clang location to avoid migration pain. + path = 'toolchains/llvm/prebuilt/{host}' notice_group = ndk.builds.NoticeGroup.TOOLCHAIN deps = { 'binutils', @@ -1506,7 +1507,6 @@ class BaseToolchain(ndk.builds.Module): def install(self): install_dir = self.get_install_path() - clang_dir = self.get_dep('clang').get_install_path() host_tools_dir = self.get_dep('host-tools').get_install_path() libandroid_support_dir = self.get_dep( 'libandroid_support').get_install_path() @@ -1514,10 +1514,6 @@ class BaseToolchain(ndk.builds.Module): sysroot_dir = self.get_dep('sysroot').get_install_path() system_stl_dir = self.get_dep('system-stl').get_install_path() - if os.path.exists(install_dir): - shutil.rmtree(install_dir) - - copy_tree(clang_dir, install_dir) copy_tree(sysroot_dir, os.path.join(install_dir, 'sysroot')) exe = '.exe' if self.host.startswith('windows') else '' @@ -1668,7 +1664,8 @@ class Toolchain(ndk.builds.Module): """ name = 'toolchain' - path = 'toolchain' + # This is installed to the Clang location to avoid migration pain. + path = 'toolchains/llvm/prebuilt/{host}' notice_group = ndk.builds.NoticeGroup.TOOLCHAIN deps = { 'base-toolchain', |