Skip to content

Commit ba6bbfe

Browse files
committed
Ensure readelf is part of the path
1 parent a36e7dc commit ba6bbfe

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

.github/workflows/stack-size.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,15 @@ jobs:
5757
# macOS has the benefit of packaging `oksh`, `osh`, and having distinct core tools
5858
if [ "$OS" = "macOS" ]; then
5959
brew install binutils # `readelf`
60+
61+
# `binutils` is not placed within the path, so find its `readelf` bin and manually move
62+
# it into our path. Due to the two possible prefixes, this consolidates them to a single
63+
# parent directory which is cursed, yet functional
64+
sudo mkdir -p /opt/homebrew
65+
sudo cp -r /opt/homebrew /usr/local/opt_homebrew
66+
sudo cp $(find /usr/local -name readelf) /usr/bin/
67+
sudo rm -rf /usr/local/opt_homebrew
68+
6069
brew install ksh93 bash dash-shell zsh mksh oksh yash oils-for-unix
6170
SHELLS="sh ksh bash dash zsh mksh oksh yash osh"
6271
fi

0 commit comments

Comments
 (0)