	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_main                           ## -- Begin function main
	.p2align	4, 0x90
_main:                                  ## @main
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movl	%edi, %r14d
	leaq	L_.str(%rip), %rdi
	callq	_system
	movq	_x11@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_fprintf
	movl	$2, %edi
	callq	_sleep
LBB0_2:
	xorl	%eax, %eax
	callq	_check_vt
	movq	_using_vt@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	jne	LBB0_4
## %bb.3:
	movq	_DEFAULT_SC_KEYMAP_DIR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_keymapdir@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movq	_DEFAULT_SC_FONT_DIR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_fontdir@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movq	_DEFAULT_SC_FONT@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_font_default@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
LBB0_4:
	movq	_head@GOTPCREL(%rip), %rdi
	callq	_SLIST_INIT
	xorl	%eax, %eax
	callq	_get_locale
	movq	_lang@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movq	(%r15), %rdi
	callq	_extract_name
	movq	_program@GOTPCREL(%rip), %rbx
	movl	%eax, (%rbx)
	xorl	%eax, %eax
	callq	_get_font
	movq	_font_current@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	testq	%rax, %rax
	jne	LBB0_6
## %bb.5:
	movq	_font_default@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, (%rcx)
LBB0_6:
	movl	(%rbx), %edi
	leaq	L_.str.2(%rip), %rsi
	callq	_strcmp
	testq	%rax, %rax
	jne	LBB0_7
## %bb.8:
	movq	_keymapdir@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_7:
	movq	_fontdir@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %eax
	movq	_dir@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movl	%r14d, %edi
	movq	%r15, %rsi
	callq	_parse_args
	xorl	%eax, %eax
	callq	_menu_read
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"kbdcontrol -d >/dev/null"

	.comm	_x11,8,3                        ## @x11
	.comm	_stderr,4,2                     ## @stderr
L_.str.1:                               ## @.str.1
	.asciz	"You are not on a virtual console - expect certain strange side-effects\n"

	.comm	_using_vt,8,3                   ## @using_vt
	.comm	_DEFAULT_SC_KEYMAP_DIR,4,2      ## @DEFAULT_SC_KEYMAP_DIR
	.comm	_keymapdir,4,2                  ## @keymapdir
	.comm	_DEFAULT_SC_FONT_DIR,4,2        ## @DEFAULT_SC_FONT_DIR
	.comm	_fontdir,4,2                    ## @fontdir
	.comm	_DEFAULT_SC_FONT,8,3            ## @DEFAULT_SC_FONT
	.comm	_font_default,8,3               ## @font_default
	.comm	_head,4,2                       ## @head
	.comm	_lang,4,2                       ## @lang
	.comm	_program,4,2                    ## @program
	.comm	_font_current,8,3               ## @font_current
L_.str.2:                               ## @.str.2
	.asciz	"kbdmap"

	.comm	_dir,4,2                        ## @dir
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_main                           ; -- Begin function main
	.p2align	2
_main:                                  ; @main
	.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, x1
	mov	x20, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_system
Lloh2:
	adrp	x8, _x11@GOTPAGE
Lloh3:
	ldr	x8, [x8, _x11@GOTPAGEOFF]
Lloh4:
	str	x0, [x8]
	cbz	x0, LBB0_2
; %bb.1:
Lloh5:
	adrp	x8, _stderr@GOTPAGE
Lloh6:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
Lloh8:
	adrp	x1, l_.str.1@PAGE
Lloh9:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_fprintf
	mov	w0, #2
	bl	_sleep
LBB0_2:
	bl	_check_vt
Lloh10:
	adrp	x8, _using_vt@GOTPAGE
Lloh11:
	ldr	x8, [x8, _using_vt@GOTPAGEOFF]
Lloh12:
	str	x0, [x8]
Lloh13:
	adrp	x21, _keymapdir@GOTPAGE
Lloh14:
	ldr	x21, [x21, _keymapdir@GOTPAGEOFF]
Lloh15:
	adrp	x22, _fontdir@GOTPAGE
Lloh16:
	ldr	x22, [x22, _fontdir@GOTPAGEOFF]
	cbnz	x0, LBB0_4
; %bb.3:
Lloh17:
	adrp	x8, _DEFAULT_SC_KEYMAP_DIR@GOTPAGE
Lloh18:
	ldr	x8, [x8, _DEFAULT_SC_KEYMAP_DIR@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	str	w8, [x21]
Lloh20:
	adrp	x8, _DEFAULT_SC_FONT_DIR@GOTPAGE
Lloh21:
	ldr	x8, [x8, _DEFAULT_SC_FONT_DIR@GOTPAGEOFF]
Lloh22:
	ldr	w8, [x8]
	str	w8, [x22]
Lloh23:
	adrp	x8, _DEFAULT_SC_FONT@GOTPAGE
Lloh24:
	ldr	x8, [x8, _DEFAULT_SC_FONT@GOTPAGEOFF]
Lloh25:
	ldr	x8, [x8]
Lloh26:
	adrp	x9, _font_default@GOTPAGE
Lloh27:
	ldr	x9, [x9, _font_default@GOTPAGEOFF]
Lloh28:
	str	x8, [x9]
LBB0_4:
Lloh29:
	adrp	x0, _head@GOTPAGE
Lloh30:
	ldr	x0, [x0, _head@GOTPAGEOFF]
	bl	_SLIST_INIT
	bl	_get_locale
Lloh31:
	adrp	x8, _lang@GOTPAGE
Lloh32:
	ldr	x8, [x8, _lang@GOTPAGEOFF]
Lloh33:
	str	w0, [x8]
	ldr	x0, [x19]
	bl	_extract_name
Lloh34:
	adrp	x23, _program@GOTPAGE
Lloh35:
	ldr	x23, [x23, _program@GOTPAGEOFF]
	str	w0, [x23]
	bl	_get_font
Lloh36:
	adrp	x8, _font_current@GOTPAGE
Lloh37:
	ldr	x8, [x8, _font_current@GOTPAGEOFF]
	str	x0, [x8]
	cbnz	x0, LBB0_6
; %bb.5:
Lloh38:
	adrp	x9, _font_default@GOTPAGE
Lloh39:
	ldr	x9, [x9, _font_default@GOTPAGEOFF]
Lloh40:
	ldr	x9, [x9]
	str	x9, [x8]
LBB0_6:
	ldr	w0, [x23]
Lloh41:
	adrp	x1, l_.str.2@PAGE
Lloh42:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_strcmp
	cmp	x0, #0
	csel	x8, x21, x22, eq
	ldr	w8, [x8]
Lloh43:
	adrp	x9, _dir@GOTPAGE
Lloh44:
	ldr	x9, [x9, _dir@GOTPAGEOFF]
Lloh45:
	str	w8, [x9]
	mov	x0, x20
	mov	x1, x19
	bl	_parse_args
	bl	_menu_read
	mov	w0, #0
	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 AdrpLdrGotStr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotStr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotStr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh36, Lloh37
	.loh AdrpLdrGot	Lloh34, Lloh35
	.loh AdrpLdrGotStr	Lloh31, Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotStr	Lloh43, Lloh44, Lloh45
	.loh AdrpAdd	Lloh41, Lloh42
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"kbdcontrol -d >/dev/null"

	.comm	_x11,8,3                        ; @x11
	.comm	_stderr,4,2                     ; @stderr
l_.str.1:                               ; @.str.1
	.asciz	"You are not on a virtual console - expect certain strange side-effects\n"

	.comm	_using_vt,8,3                   ; @using_vt
	.comm	_DEFAULT_SC_KEYMAP_DIR,4,2      ; @DEFAULT_SC_KEYMAP_DIR
	.comm	_keymapdir,4,2                  ; @keymapdir
	.comm	_DEFAULT_SC_FONT_DIR,4,2        ; @DEFAULT_SC_FONT_DIR
	.comm	_fontdir,4,2                    ; @fontdir
	.comm	_DEFAULT_SC_FONT,8,3            ; @DEFAULT_SC_FONT
	.comm	_font_default,8,3               ; @font_default
	.comm	_head,4,2                       ; @head
	.comm	_lang,4,2                       ; @lang
	.comm	_program,4,2                    ; @program
	.comm	_font_current,8,3               ; @font_current
l_.str.2:                               ; @.str.2
	.asciz	"kbdmap"

	.comm	_dir,4,2                        ; @dir
.subsections_via_symbols
