Skip to content

Commit

Permalink
[CI] Add shebang to shim wrapper scripts (#364)
Browse files Browse the repository at this point in the history
After the update of the Cmake binary on our CI fleet, the way Cmake
handles internal processes has changed and we need to explicitly set the
shebang on our wrapper shims to avoid
```
    Error running link command: Unknown system error -8
```
  • Loading branch information
justice-adams-apple authored Jan 23, 2025
1 parent af0a127 commit 3fff39d
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tasks/cmake/caches/util/xcode_sdk.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,8 @@ if (CMAKE_C_COMPILER)

macro(create_shim VARIABLE TOOLNAME)
xcrun_find(SDK_TOOL_BIN ${TOOLNAME})
file(WRITE ${CMAKE_BINARY_DIR}/${TOOLNAME} "
file(WRITE ${CMAKE_BINARY_DIR}/${TOOLNAME} "#!/usr/bin/env bash
# Shim to have the tool use the correct libLTO.dylib
DYLD_LIBRARY_PATH=\"${COMPILER_DIR}/../lib:$DYLD_LIBRARY_PATH\" ${SDK_TOOL_BIN} \"$@\"
")
Expand Down

0 comments on commit 3fff39d

Please sign in to comment.