Skip to content

Commit b7e076c

Browse files
committed
Fix Linux build: guard cbm_macos_adhoc_sign with #ifdef __APPLE__
1 parent fa97ea5 commit b7e076c

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

src/cli/cli.c

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2252,20 +2252,17 @@ static int cbm_download_to_file_quiet(const char *url, const char *dest) {
22522252

22532253
/* ── macOS ad-hoc signing ─────────────────────────────────────── */
22542254

2255-
static int cbm_macos_adhoc_sign(const char *binary_path) {
22562255
#ifdef __APPLE__
2256+
static int cbm_macos_adhoc_sign(const char *binary_path) {
22572257
/* Remove quarantine xattr (best effort — may not exist) */
22582258
const char *xattr_argv[] = {"xattr", "-d", "com.apple.quarantine", binary_path, NULL};
22592259
(void)cbm_exec_no_shell(xattr_argv);
22602260

22612261
/* Ad-hoc sign (required for arm64, harmless for x86_64) */
22622262
const char *sign_argv[] = {"codesign", "--sign", "-", "--force", binary_path, NULL};
22632263
return cbm_exec_no_shell(sign_argv);
2264-
#else
2265-
(void)binary_path;
2266-
return 0;
2267-
#endif
22682264
}
2265+
#endif
22692266

22702267
/* ── Kill other MCP server instances ──────────────────────────── */
22712268

0 commit comments

Comments
 (0)