Commit c31cdbc
Bundle and re-sign libusb for the signed macOS CLI
The released MCCOutletCLI linked libusb by absolute Homebrew path. Once
the CLI is Developer-ID signed with the hardened runtime it is subject to
library validation and may only load dylibs signed by Apple or the same
Team ID. Homebrew's libusb bottle is signed by a different team, so dyld
refused it unconditionally and the shipped CLI was unrunnable on every
machine (including ones with `brew install libusb`).
CI missed this because the smoke test runs in the build job, before the
sign-macos job adds the hardened runtime, on a runner that has brew libusb.
Fix, in the sign-macos job before the CLI is signed: treat libusb exactly
like lsl.framework. Copy the dylib into the CLI's Frameworks/ dir
(preferring the macdeployqt'd app copy, falling back to the CLI's current
reference so it works on both /opt/homebrew and /usr/local runners),
normalize its install name to @rpath, repoint the CLI, and sign the dylib
with the Developer ID before the CLI (dependency before dependent). The
dylib ships automatically since Frameworks is already in the tarball.
Also add a guardrail: after signing, fail the build if the CLI still
links any absolute brew dylib.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent 4d07421 commit c31cdbc
1 file changed
Lines changed: 49 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
218 | 218 | | |
219 | 219 | | |
220 | 220 | | |
221 | | - | |
| 221 | + | |
222 | 222 | | |
223 | 223 | | |
224 | 224 | | |
225 | | - | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
226 | 262 | | |
227 | 263 | | |
228 | 264 | | |
229 | 265 | | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
230 | 269 | | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
231 | 278 | | |
232 | 279 | | |
233 | 280 | | |
| |||
0 commit comments