Skip to content

Commit dacfc50

Browse files
committed
Add macos runtime resolve.
1 parent 8f0619a commit dacfc50

3 files changed

Lines changed: 1 addition & 3 deletions

File tree

544 Bytes
Binary file not shown.
-216 Bytes
Binary file not shown.

src/setup.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -358,7 +358,6 @@ static bool arm64_apple_darwin(struct context *ctx) {
358358
}
359359

360360
str_buf_append_fmt(&libpath, ":{str}/{str}", macos_sdk, cstr("usr/lib"));
361-
str_buf_free(&macos_sdk);
362361

363362
str_buf_t osver = execute("sw_vers -productVersion");
364363
if (osver.len == 0) {
@@ -392,8 +391,7 @@ static bool arm64_apple_darwin(struct context *ctx) {
392391

393392
// Resolve c runtime
394393
str_buf_append_fmt(&optexec, "{str}/usr/lib/crt1.o ", macos_sdk);
395-
str_buf_append_fmt(&optexec, "{str}/usr/lib/crti.o ", macos_sdk);
396-
str_buf_append_fmt(&optexec, "{str}/usr/lib/crtn.o ", macos_sdk);
394+
str_buf_free(&macos_sdk);
397395

398396
str_buf_append(&optexec, LINKER_OPT_EXEC);
399397
str_buf_append(&optshared, LINKER_OPT_SHARED);

0 commit comments

Comments
 (0)