	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function subst_packagesite
_subst_packagesite:                     ## @subst_packagesite
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	_c@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_PACKAGESITE@GOTPCREL(%rip), %r13
	movq	(%r13), %rcx
	shlq	$4, %rcx
	movq	(%rax,%rcx), %rbx
	testq	%rbx, %rbx
	jne	LBB0_2
## %bb.1:
	movq	8(%rax,%rcx), %rbx
LBB0_2:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_strstr
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	%rax, %r15
	xorl	%eax, %eax
	callq	_sbuf_new_auto
	movq	%rax, %r12
	movl	%r15d, %edx
	subl	%ebx, %edx
	movq	%rax, %rdi
	movq	%rbx, %rsi
	callq	_sbuf_bcat
	movq	%r12, %rdi
	movq	%r14, %rsi
	callq	_sbuf_cat
	leaq	L_.str(%rip), %rdi
	callq	_strlen
	movslq	%eax, %rsi
	addq	%r15, %rsi
	movq	%r12, %rdi
	callq	_sbuf_cat
	movq	%r12, %rdi
	callq	_sbuf_finish
	movq	_c@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rax
	movq	(%r13), %rcx
	shlq	$4, %rcx
	movq	(%rax,%rcx), %rdi
	callq	_free
	movq	%r12, %rdi
	callq	_sbuf_data
	movl	%eax, %edi
	callq	_strdup
	movq	(%rbx), %rcx
	movq	(%r13), %rdx
	shlq	$4, %rdx
	movq	%rax, (%rcx,%rdx)
LBB0_4:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_c,8,3                          ## @c
	.comm	_PACKAGESITE,8,3                ## @PACKAGESITE
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"${ABI}"

	.no_dead_strip	_subst_packagesite
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function subst_packagesite
_subst_packagesite:                     ; @subst_packagesite
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
Lloh0:
	adrp	x23, _c@GOTPAGE
Lloh1:
	ldr	x23, [x23, _c@GOTPAGEOFF]
	ldr	x8, [x23]
Lloh2:
	adrp	x24, _PACKAGESITE@GOTPAGE
Lloh3:
	ldr	x24, [x24, _PACKAGESITE@GOTPAGEOFF]
	ldr	x9, [x24]
	lsl	x10, x9, #4
	ldr	x20, [x8, x10]
	cbnz	x20, LBB0_2
; %bb.1:
	add	x8, x8, x9, lsl #4
	ldr	x20, [x8, #8]
LBB0_2:
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	bl	_strstr
	cbz	x0, LBB0_4
; %bb.3:
	mov	x21, x0
	bl	_sbuf_new_auto
	mov	x22, x0
	sub	w2, w21, w20
	mov	x1, x20
	bl	_sbuf_bcat
	mov	x0, x22
	mov	x1, x19
	bl	_sbuf_cat
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_strlen
	add	x1, x21, w0, sxtw
	mov	x0, x22
	bl	_sbuf_cat
	mov	x0, x22
	bl	_sbuf_finish
	ldr	x8, [x23]
	ldr	x9, [x24]
	lsl	x9, x9, #4
	ldr	x0, [x8, x9]
	bl	_free
	mov	x0, x22
	bl	_sbuf_data
	bl	_strdup
	ldr	x8, [x23]
	ldr	x9, [x24]
	lsl	x9, x9, #4
	str	x0, [x8, x9]
LBB0_4:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_c,8,3                          ; @c
	.comm	_PACKAGESITE,8,3                ; @PACKAGESITE
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"${ABI}"

	.no_dead_strip	_subst_packagesite
.subsections_via_symbols
