Reland "dist: copy dir allow dir to already exist & don't copy permissions"

This reverts commit e23b37a27ac5509d85e3ca036c8db3bd136a4559.

Reason for revert: relanding change

Use copyfile function instead of copy2. Also,
set dirs_exist_ok to be consistent with the sementics
for copying files.

Change-Id: I83f56d29b39b76946eac399e6c195afb6ea96257
Test: run dist rule twice
Bug: 229264037
1 file changed
tree: 0fc708550a2d91e5e00e78efecffd5f177dbd788
  1. dist/
  2. docs/
  3. exec/
  4. OWNERS
  5. README.md
README.md

Bazel Common Rules

This directory contains common Bazel rules and tools shared between the Platform and Kernel builds.

For platform-specific rules, place them in the platform checkout's //build/bazel/rules directory.

For kernel-specific rules, place them in kernel checkout's //build/kleaf directory.