Skip to content

Commit

Permalink
Package bits/stdatomic.h
Browse files Browse the repository at this point in the history
Bionic change 76e2b15ad moved some part of stdatomic.h to
bits/stdatomic.h, we need to package the file in toolchain.

Test: build.py
Build: 138701943
Change-Id: I25a4f01603d55818740fb8a3a2c249fce67ae7fc
  • Loading branch information
kongy committed Aug 6, 2019
1 parent 538a144 commit e8b1d13
Showing 1 changed file with 11 additions and 3 deletions.
14 changes: 11 additions & 3 deletions build.py
Original file line number Diff line number Diff line change
Expand Up @@ -1585,13 +1585,21 @@ def package_toolchain(build_dir, build_name, host, dist_dir, strip=True):
if is_windows and not os.path.isfile(os.path.join(lib_dir, necessary_lib_file)):
raise RuntimeError('Did not find %s under lib64' % necessary_lib_file)

# Next, we copy over stdatomic.h from bionic.
stdatomic_path = utils.android_path('bionic', 'libc', 'include',
'stdatomic.h')
# Next, we copy over stdatomic.h and bits/stdatomic.h from bionic.
libc_include_path = utils.android_path('bionic', 'libc', 'include')
resdir_top = os.path.join(lib_dir, 'clang')
header_path = os.path.join(resdir_top, version.long_version(), 'include')

stdatomic_path = utils.android_path(libc_include_path, 'stdatomic.h')
install_file(stdatomic_path, header_path)

bits_install_path = os.path.join(header_path, 'bits')
if not os.path.isdir(bits_install_path):
os.mkdir(bits_install_path)
bits_stdatomic_path = utils.android_path(libc_include_path, 'bits', 'stdatomic.h')
install_file(bits_stdatomic_path, bits_install_path)


# Install license files as NOTICE in the toolchain install dir.
install_license_files(install_dir)

Expand Down

0 comments on commit e8b1d13

Please sign in to comment.