Sync with upstream script to properly handle symlinks #27
  Add this suggestion to a batch that can be applied as a single commit.
  This suggestion is invalid because no changes were made to the code.
  Suggestions cannot be applied while the pull request is closed.
  Suggestions cannot be applied while viewing a subset of changes.
  Only one suggestion per line can be applied in a batch.
  Add this suggestion to a batch that can be applied as a single commit.
  Applying suggestions on deleted lines is not supported.
  You must change the existing code in this line in order to create a valid suggestion.
  Outdated suggestions cannot be applied.
  This suggestion has been applied or marked resolved.
  Suggestions cannot be applied from pending reviews.
  Suggestions cannot be applied on multi-line comments.
  Suggestions cannot be applied while the pull request is queued to merge.
  Suggestion cannot be applied right now. Please check back later.
  
    
  
    
I ran a comparison of the chromium's sysroots with ours and found out, that symlinks look differently, e.g.
libutil.so -> ../../..//lib/x86_64-linux-gnu/libutil.so.1libutil.so -> /lib/x86_64-linux-gnu/libutil.so.1This might have worked in the past with Bazel 7, but with Bazel 8 in some situations (maybe due to Bazel 8's stricter sandboxing) it just fails. I was not able to reproduce it locally, it only happens in CI with enabled Bazel Cache.
This change enables the relative symlink handling instead of using absolute paths and syncs with the upstream script of the chromium project.
(
lapackandblasseem to be in the correct shape:liblapack.a -> ./lapack/liblapack.a)Tested in swift-nav/rules_swiftnav#200 (see testplan in PR description)