Function at 0x40b7b0
Capabilities:
Query environment variable

Disassembly:
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x50
mov rdi, rdx
mov esi, ecx
call fcn.00404d20
lea rcx, str.GCC_EXEC_PREFIX
mov rbx, qword [rdi]
call sub.msvcrt.dll_getenv
test rax, rax
je 0x40b7f1
lea rdx, str.gcc_ranlib
xor r8d, r8d
mov rcx, rax
call fcn.00401ae0
mov rbx, rax
lea rbp, str.E:_msys_mingw64_64_bin_
mov rcx, rbx
lea r8, str.E:_msys_mingw64_64_lib_gcc_
mov rdx, rbp
call fcn.004024a0
test rax, rax
mov qword [0x00411080], rax
je 0x40bc19
lea r8, str.E:_msys_mingw64_64_libexec_gcc_
mov rdx, rbp
mov rcx, rbx
call fcn.004024a0
test rax, rax
mov qword [0x00411078], rax
je 0x40bc2c
lea rbp, str.x86_64_w64_mingw32
xor r9d, r9d
lea r8, [0x0040d0f7]
mov rdx, rbp
lea rcx, str..._.._.._.._
call fcn.00401ae0
mov rcx, qword [0x00411080]
mov rdx, rbp
mov qword [rsp + 0x30], 0
lea rbx, [0x0040d0f7]
mov qword [rsp + 0x28], rax
lea r9, str.13.2.0
mov r8, rbx
mov qword [rsp + 0x20], rbx
lea r12, [0x00411060]
call fcn.00401ae0
lea rdx, [0x0040d051]
xor r8d, r8d
mov rcx, rax
call fcn.00401ae0
mov rdx, r12
mov rcx, rax
call fcn.00401820
mov r8, rbx
mov rdx, rbp
mov qword [rsp + 0x20], rbx
mov rcx, qword [0x00411078]
lea r9, str.13.2.0
mov qword [rsp + 0x28], 0
lea rbp, [0x00411040]
call fcn.00401ae0
mov rdx, r12
mov rcx, rax
mov qword [0x00411078], rax
call fcn.00401820
lea rcx, [0x0040d055]
mov rdx, rbp
call fcn.00401980
test esi, esi
jle 0x40bb61
mov rcx, rdi
movsxd rdx, esi
xor eax, eax
jmp 0x40b929
add rax, 1
add rcx, 8
cmp rax, rdx
je 0x40b9b6
mov rbx, qword [rcx]
cmp byte [rbx], 0x2d
jne 0x40b918
cmp byte [rbx + 1], 0x42
jne 0x40b918
lea r8d, [rsi + 1]
mov r13d, eax
lea r14, [rdi + rax*8 + 8]
sub r8d, eax
movsxd r8, r8d
mov rdx, r14
shl r8, 3
call sub.msvcrt.dll_memmove
cmp byte [rbx + 2], 0
mov rcx, rax
je 0x40bb30
add rbx, 2
sub esi, 1
mov rcx, rbx
call sub.msvcrt.dll_strlen
test rax, rax
je 0x40b9a0
lea rax, [rbx + rax - 1]
cmp rbx, rax
jae 0x40b9a0
movzx eax, byte [rax]
cmp al, 0x2f
je 0x40b9a0
cmp al, 0x5c
je 0x40b9a0
lea rdx, [0x0040d0f5]
mov rcx, rbx
xor r8d, r8d
call fcn.00401ae0
mov rbx, rax
mov rdx, rbx
mov rcx, rbp
call fcn.00401810
mov rdx, rbx
mov rcx, r12
call fcn.00401810
lea r13, str.ranlib
mov r8d, 1
mov rcx, r12
mov rdx, r13
call fcn.00401540
test rax, rax
mov rbx, rax
je 0x40bb0e
lea ecx, [rsi + 4]
mov edx, 8
movsxd rcx, ecx
call fcn.00403790
cmp esi, 1
mov rbp, rax
mov qword [rax], rbx
jle 0x40bba1
lea rcx, [rax + 8]
lea eax, [rsi - 1]
lea rdx, [rdi + 8]
lea r8, [rax*8]
call sub.msvcrt.dll_memcpy
movsxd rsi, esi
xor r8d, r8d
mov rdx, rbx
mov qword [rbp + rsi*8], 0
lea rcx, str.gcc_
call fcn.00401ae0
mov r8, rbp
mov rdx, rbx
mov ecx, 3
mov qword [rsp + 0x28], 0
mov r9, rax
mov qword [rsp + 0x20], 0
lea rax, [rsp + 0x4c]
mov qword [rsp + 0x38], rax
lea rax, [rsp + 0x48]
mov qword [rsp + 0x30], rax
call fcn.004024c0
test rax, rax
mov rsi, rax
je 0x40baa4
mov ecx, 2
call qword [fcn.0040af90]
mov r9, rsi
mov r8, rbx
lea rdx, str.Error_running__s:__s_n
mov rcx, rax
call fcn.0040b780
mov eax, 1
add rsp, 0x50
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
ret
mov eax, dword [rsp + 0x48]
test eax, eax
je 0x40ba95
mov edx, eax
and edx, 0xff
je 0x40bb59
cmp edx, 0x7f
je 0x40ba90
lea rdi, [0x0040d00e]
mov ebp, eax
and ebp, 0x7f
test al, 0x80
lea rax, str.__core_dumped
mov ecx, ebp
cmovne rdi, rax
call fcn.004034e0
mov ecx, 2
mov rsi, rax
call qword [fcn.0040af90]
mov qword [rsp + 0x28], rdi
mov r9d, ebp
mov r8, rbx
mov qword [rsp + 0x20], rsi
lea rdx, str._s_terminated_with_signal__d___s__s_n
mov rcx, rax
call fcn.0040b780
jmp 0x40ba90
mov r8d, 1
mov rdx, r13
mov rcx, rbp
call fcn.00401540
test rax, rax
mov rbx, rax
jne 0x40b9da
jmp 0x40bbc4
mov rbx, qword [rax]
test rbx, rbx
je 0x40bbf5
mov r8d, esi
mov rdx, r14
sub esi, 2
sub r8d, r13d
movsxd r8, r8d
shl r8, 3
call sub.msvcrt.dll_memmove
jmp 0x40b969
movzx eax, ah
jmp 0x40ba95
lea r13, str.ranlib
mov r8d, 1
mov rcx, r12
mov rdx, r13
call fcn.00401540
test rax, rax
mov rbx, rax
je 0x40bbab
lea ecx, [rsi + 4]
mov edx, 8
mov esi, 1
movsxd rcx, ecx
call fcn.00403790
mov rbp, rax
mov qword [rax], rbx
jmp 0x40ba11
mov esi, 1
jmp 0x40ba11
mov r8d, 1
mov rdx, r13
mov rcx, rbp
call fcn.00401540
test rax, rax
mov rbx, rax
jne 0x40bb81
mov rbx, qword [rdi]
mov ecx, 2
call qword [fcn.0040af90]
lea r9, str.ranlib
lea rdx, str._s:_Cannot_find_binary__s_n
mov rcx, rax
mov r8, rbx
call fcn.0040b780
mov ecx, 1
call sub.msvcrt.dll_exit
mov ecx, 2
call qword [fcn.0040af90]
lea rdx, str.Usage:_gcc_ar___B_prefix__ar_arguments_..._n
mov rcx, rax
call fcn.0040b780
mov ecx, 1
call sub.msvcrt.dll_exit
lea rax, str.E:_msys_mingw64_64_lib_gcc_
mov qword [0x00411080], rax
jmp 0x40b81a
lea rax, str.E:_msys_mingw64_64_libexec_gcc_
mov qword [0x00411078], rax
jmp 0x40b83c