// File: /workspace/github_cpp_makefile_star2_O3/parth-shel[P]xpac/client.cpp
// Function: install_package(char const*)
static bool install_package(const char * pkg_name){
	//Getting the package from the server itself:
	get_from_server("GPKG-",pkg_name);

	//Working on the dependencies:
	metadata * package = metadata::get_package(metadata_path.c_str());

	//Pushing the install path onto the stack:
	dep_list.push(install_path);

	//Initializing the bfs queue:
	marked.insert(std::string(pkg_name));
	bfs_queue.push(std::string(pkg_name));
	
	while(!bfs_queue.empty()){

		std::string next = bfs_queue.front();
		bfs_queue.pop();


		if(next.compare(std::string(pkg_name)) != 0){
			get_from_server("GPKG-",next.c_str());
			package = metadata::get_package(metadata_path.c_str());
			dep_list.push(install_path);
		}

		std::vector<std::string> * curr_dep_list = package->get_dep_list();

		for(auto itr = curr_dep_list->begin(); itr!=curr_dep_list->end(); itr++){
			auto found = marked.find(*itr);
			if(found == marked.end()){	//Not found
				marked.insert(*itr);
				bfs_queue.push(*itr);
			}
		}

	}

	//Finally installing everything in the stack:
	return install_all_packages();
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x208, %rsp            # imm = 0x208
movq %rdi, -0x80(%rbp)
callq 0x6b2f
movq 0xbade(%rip), %rsi      # 0x10418
leaq -0x230(%rbp), %rdi
leaq -0xd0(%rbp), %rdx
callq 0x3190
leaq -0x230(%rbp), %rdi
callq 0xa11c
movq %rax, -0x78(%rbp)
leaq -0x220(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x4972
callq 0x3360
leaq 0xbadf(%rip), %rdi      # 0x10458
leaq 0xbab8(%rip), %rsi      # 0x10438
callq 0x7848
leaq -0xd0(%rbp), %rdi
leaq -0x50(%rbp), %rdx
movq -0x80(%rbp), %rsi
callq 0x3190
leaq 0xbb58(%rip), %r15      # 0x104f8
leaq -0x70(%rbp), %rdx
movq %r15, (%rdx)
leaq -0xd0(%rbp), %rsi
movq %r15, %rdi
callq 0x81de
leaq -0xc0(%rbp), %r13
movq -0x10(%r13), %rdi
cmpq %r13, %rdi
je 0x49cb
callq 0x3360
leaq -0xd0(%rbp), %rdi
leaq -0x70(%rbp), %rdx
movq -0x80(%rbp), %rsi
callq 0x3190
leaq 0xbac2(%rip), %rdi      # 0x104a8
leaq -0xd0(%rbp), %rsi
callq 0x85f8
movq -0xd0(%rbp), %rdi
cmpq %r13, %rdi
je 0x4a03
callq 0x3360
movq 0xbaae(%rip), %rax      # 0x104b8
cmpq %rax, 0xbac7(%rip)      # 0x104d8
je 0x4b79
leaq 0xba8a(%rip), %r12      # 0x104a8
movq %r13, -0xd0(%rbp)
movq (%rax), %rsi
movq 0x8(%rax), %rdx
addq %rsi, %rdx
leaq -0xd0(%rbp), %rdi
callq 0x80a2
movq %r12, %rdi
callq 0x875a
leaq -0x70(%rbp), %rdi
movq -0x80(%rbp), %rsi
leaq -0x50(%rbp), %rdx
callq 0x3190
movq -0xc8(%rbp), %r14
movq -0x70(%rbp), %rbx
movq -0x68(%rbp), %r13
cmpq %r14, %r13
movq %r14, %rdx
cmovbq %r13, %rdx
testq %rdx, %rdx
je 0x4a8a
movq -0xd0(%rbp), %rdi
movq %rbx, %rsi
callq 0x33a0
testl %eax, %eax
je 0x4a8a
xorl %r14d, %r14d
jmp 0x4a91
cmpq %r13, %r14
sete %r14b
leaq -0x60(%rbp), %rax
cmpq %rax, %rbx
leaq -0xc0(%rbp), %r13
je 0x4aa9
movq %rbx, %rdi
callq 0x3360
testb %r14b, %r14b
jne 0x4b0b
movq -0xd0(%rbp), %rdi
callq 0x6b2f
movq 0xb957(%rip), %rsi      # 0x10418
leaq -0x1d0(%rbp), %rbx
movq %rbx, %rdi
leaq -0x70(%rbp), %rdx
callq 0x3190
movq %rbx, %rdi
callq 0xa11c
movq %rax, -0x78(%rbp)
movq -0x1d0(%rbp), %rdi
leaq -0x1c0(%rbp), %rax
cmpq %rax, %rdi
je 0x4af8
callq 0x3360
leaq 0xb959(%rip), %rdi      # 0x10458
leaq 0xb932(%rip), %rsi      # 0x10438
callq 0x7848
movq -0x78(%rbp), %rdi
callq 0x9dd8
movq %rax, %rbx
movq (%rax), %r14
cmpq 0x8(%rbx), %r14
je 0x4b54
movq %r15, %rdi
movq %r14, %rsi
callq 0x87f8
testq %rax, %rax
jne 0x4b4e
movq %r15, -0x70(%rbp)
movq %r15, %rdi
movq %r14, %rsi
leaq -0x70(%rbp), %rdx
callq 0x883c
movq %r12, %rdi
movq %r14, %rsi
callq 0x7848
addq $0x20, %r14
jmp 0x4b1a
movq -0xd0(%rbp), %rdi
cmpq %r13, %rdi
je 0x4b65
callq 0x3360
movq 0xb94c(%rip), %rax      # 0x104b8
cmpq %rax, 0xb965(%rip)      # 0x104d8
jne 0x4a1e
leaq 0xb8d8(%rip), %rsi      # 0x10458
leaq -0xd0(%rbp), %rdi
callq 0x7b1e
movq 0xb43d(%rip), %rbx      # 0xffd0
leaq 0x7932(%rip), %rsi      # 0xc4cc
movl $0x2a, %edx
movq %rbx, %rdi
callq 0x3400
movq (%rbx), %rax
addq -0x18(%rax), %rbx
movq %rbx, %rdi
movl $0xa, %esi
callq 0x3370
movsbl %al, %esi
movq 0xb40b(%rip), %rbx      # 0xffd0
movq %rbx, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3280
movq -0xa0(%rbp), %rax
cmpq -0xc0(%rbp), %rax
je 0x4ccc
leaq -0x60(%rbp), %r13
leaq -0x70(%rbp), %r14
leaq -0xd0(%rbp), %r15
cmpq -0x98(%rbp), %rax
jne 0x4c14
movq -0x88(%rbp), %rax
movq -0x8(%rax), %rax
movl $0x200, %ecx            # imm = 0x200
addq %rcx, %rax
movq %r13, -0x70(%rbp)
movq -0x20(%rax), %rsi
movq -0x18(%rax), %rdx
addq %rsi, %rdx
movq %r14, %rdi
callq 0x80a2
movl $0x1, %ecx
movq %r14, %rdi
leaq 0x73d0(%rip), %rsi      # 0xc00a
xorl %edx, %edx
callq 0x35b0
leaq -0x50(%rbp), %rdi
movq %r14, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0x33b0
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq 0xb36f(%rip), %rdi      # 0xffd0
callq 0x3400
movq %rax, %r12
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r12, %rdi
movl $0xa, %esi
callq 0x3370
movsbl %al, %esi
movq %r12, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3280
movq -0x50(%rbp), %rdi
leaq -0x40(%rbp), %rax
cmpq %rax, %rdi
je 0x4ca2
callq 0x3360
movq %r15, %rdi
callq 0x7faa
movq -0x70(%rbp), %rdi
cmpq %r13, %rdi
je 0x4cb8
callq 0x3360
movq -0xa0(%rbp), %rax
cmpq -0xc0(%rbp), %rax
jne 0x4bf8
leaq 0x73b9(%rip), %r14      # 0xc08c
movq 0xb306(%rip), %r15      # 0xffe0
leaq -0x29(%rbp), %r12
movabsq $0x80100000801, %r13    # imm = 0x80100000801
movl $0x14, %edx
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3400
movq (%rbx), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x3370
movsbl %al, %esi
movq %rbx, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3280
movq %r15, %rdi
movq %r12, %rsi
callq 0x3470
movzbl -0x29(%rbp), %eax
leal -0x4e(%rax), %ecx
cmpl $0x2b, %ecx
ja 0x4ce8
btq %rcx, %r13
jae 0x4ce8
andb $0x5f, %al
cmpb $0x4e, %al
je 0x51bf
movq 0xb73b(%rip), %rax      # 0x10488
cmpq 0xb714(%rip), %rax      # 0x10468
je 0x5118
leaq -0x70(%rbp), %rbx
leaq -0x110(%rbp), %r12
movq 0xb264(%rip), %r14      # 0xffd0
leaq 0xb84d(%rip), %rcx      # 0x105c0
addq $0x8, %rcx
movq %rcx, -0x78(%rbp)
cmpq 0xb70e(%rip), %rax      # 0x10490
jne 0x4d97
movq 0xb715(%rip), %rax      # 0x104a0
movq -0x8(%rax), %rax
movl $0x200, %ecx            # imm = 0x200
addq %rcx, %rax
leaq -0x60(%rbp), %rcx
movq %rcx, -0x70(%rbp)
movq -0x20(%rax), %rsi
movq -0x18(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x80a2
movl $0x1, %ecx
movq %rbx, %rdi
leaq 0x7249(%rip), %rsi      # 0xc00a
xorl %edx, %edx
callq 0x35b0
leaq -0x50(%rbp), %rdi
movq %rbx, %rsi
xorl %edx, %edx
movq %rax, %rcx
callq 0x33b0
leaq -0x100(%rbp), %rax
movq %rax, -0x110(%rbp)
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
addq %rsi, %rdx
movq %r12, %rdi
callq 0x80a2
movq %r12, %rdi
leaq 0x7672(%rip), %rsi      # 0xc476
callq 0x3650
movq %r12, %rdi
callq 0xa11c
movq %rax, 0xb5f8(%rip)      # 0x10410
movq -0x110(%rbp), %rdi
leaq -0x100(%rbp), %rcx
cmpq %rcx, %rdi
je 0x4e37
callq 0x3360
movq 0xb5d9(%rip), %rax      # 0x10410
leaq -0xe0(%rbp), %rcx
movq %rcx, -0xf0(%rbp)
movq 0x40(%rax), %rsi
movq 0x48(%rax), %rdx
addq %rsi, %rdx
leaq -0xf0(%rbp), %rdi
callq 0x80a2
leaq 0xb5f5(%rip), %rdi      # 0x10458
callq 0x7faa
movl $0x14, %edx
movq %r14, %rdi
leaq 0x7680(%rip), %rsi      # 0xc4f7
callq 0x3400
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq %r14, %rdi
callq 0x3400
movq %rax, %r13
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x3370
movsbl %al, %esi
movq %r13, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3280
leaq 0xb703(%rip), %rdi      # 0x105c0
leaq -0x50(%rbp), %rsi
callq 0x8140
cmpq -0x78(%rbp), %rax
je 0x4f95
movl $0x12, %edx
movq %r14, %rdi
leaq 0x72bb(%rip), %rsi      # 0xc19a
callq 0x3400
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq %r14, %rdi
callq 0x3400
movq %rax, %r13
movl $0x1, %edx
movq %rax, %rdi
leaq 0x7555(%rip), %rsi      # 0xc45b
callq 0x3400
movq (%r13), %rax
movq -0x18(%rax), %rdi
addq %r13, %rdi
movl $0xa, %esi
callq 0x3370
movsbl %al, %esi
movq %r13, %rdi
callq 0x3030
movq %rax, %rdi
callq 0x3280
leaq -0x160(%rbp), %rax
movq %rax, -0x170(%rbp)
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
addq %rsi, %rdx
leaq -0x170(%rbp), %rdi
callq 0x80a2
leaq -0x170(%rbp), %rdi
callq 0xad7c
movq -0x170(%rbp), %rdi
leaq -0x160(%rbp), %rax
cmpq %rax, %rdi
je 0x4f7c
callq 0x3360
movq 0xb505(%rip), %rax      # 0x10488
cmpq 0xb4de(%rip), %rax      # 0x10468
jne 0x50c8
jmp 0x51b5
movq -0x70(%rbp), %rdi
callq 0x3320
testl %eax, %eax
jne 0x5136
movq 0xb463(%rip), %r13      # 0x10410
movq 0xb3ec(%rip), %rsi      # 0x103a0
leaq -0x1f0(%rbp), %r15
movq %r15, %rdi
leaq -0x1b0(%rbp), %rdx
callq 0x3190
movq %r13, %rdi
movq %r15, %rsi
callq 0x9de2
movq -0x1f0(%rbp), %rdi
leaq -0x1e0(%rbp), %rax
cmpq %rax, %rdi
je 0x4fed
callq 0x3360
leaq -0x140(%rbp), %rax
movq %rax, -0x150(%rbp)
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
addq %rsi, %rdx
leaq -0x150(%rbp), %rdi
callq 0x80a2
leaq -0x180(%rbp), %rax
movq %rax, -0x190(%rbp)
movq -0xf0(%rbp), %rsi
movq -0xe8(%rbp), %rdx
addq %rsi, %rdx
leaq -0x190(%rbp), %r15
movq %r15, %rdi
callq 0x80a2
leaq -0x150(%rbp), %rdi
movq %r15, %rsi
callq 0xabc6
movq -0x190(%rbp), %rdi
leaq -0x180(%rbp), %rax
cmpq %rax, %rdi
je 0x5067
callq 0x3360
movq -0x150(%rbp), %rdi
leaq -0x140(%rbp), %rax
cmpq %rax, %rdi
je 0x507f
callq 0x3360
leaq -0x120(%rbp), %rax
movq %rax, -0x130(%rbp)
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
addq %rsi, %rdx
leaq -0x130(%rbp), %rdi
callq 0x80a2
leaq -0x130(%rbp), %rdi
callq 0xad7c
movq -0x130(%rbp), %rdi
leaq -0x120(%rbp), %rax
cmpq %rax, %rdi
je 0x50c8
callq 0x3360
movq -0xf0(%rbp), %rdi
leaq -0xe0(%rbp), %rax
cmpq %rax, %rdi
je 0x50e0
callq 0x3360
movq -0x50(%rbp), %rdi
leaq -0x40(%rbp), %rax
cmpq %rax, %rdi
je 0x50f2
callq 0x3360
movq -0x70(%rbp), %rdi
leaq -0x60(%rbp), %rax
cmpq %rax, %rdi
je 0x5104
callq 0x3360
movq 0xb37d(%rip), %rax      # 0x10488
cmpq 0xb356(%rip), %rax      # 0x10468
jne 0x4d7b
leaq -0xd0(%rbp), %rdi
callq 0x74e8
addq $0x208, %rsp            # imm = 0x208
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0xae93(%rip), %rdi      # 0xffd0
leaq 0x73c8(%rip), %rsi      # 0xc50c
movl $0x12, %edx
callq 0x3400
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
movq 0xae73(%rip), %rdi      # 0xffd0
callq 0x3400
movq %rax, %rbx
leaq 0x72ee(%rip), %rsi      # 0xc45a
movl $0x2, %edx
movq %rax, %rdi
callq 0x3400
movq %rbx, %rdi
callq 0x31e0
movq 0xae48(%rip), %rdi      # 0xffd0
leaq 0x7390(%rip), %rsi      # 0xc51f
movl $0x28, %edx
callq 0x3400
movq 0xae30(%rip), %rdi      # 0xffd0
callq 0x31e0
movq 0xb2dc(%rip), %rax      # 0x10488
cmpq 0xb2b5(%rip), %rax      # 0x10468
jne 0x51c6
movl $0x1, %edi
callq 0x3440
xorl %edi, %edi
callq 0x3440
leaq -0x1a0(%rbp), %r12
leaq -0x200(%rbp), %r13
leaq -0x1b0(%rbp), %rbx
leaq -0x210(%rbp), %r14
leaq 0xb26f(%rip), %r15      # 0x10458
cmpq 0xb2a0(%rip), %rax      # 0x10490
jne 0x5205
movq 0xb2a7(%rip), %rax      # 0x104a0
movq -0x8(%rax), %rax
movl $0x200, %ecx            # imm = 0x200
addq %rcx, %rax
movq %r12, -0x1b0(%rbp)
movq -0x20(%rax), %rsi
movq -0x18(%rax), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x80a2
movq %r13, -0x210(%rbp)
movq -0x50(%rbp), %rsi
movq -0x48(%rbp), %rdx
addq %rsi, %rdx
movq %r14, %rdi
callq 0x80a2
movq %r14, %rdi
callq 0xad7c
movq -0x210(%rbp), %rdi
cmpq %r13, %rdi
je 0x5252
callq 0x3360
movq %r15, %rdi
callq 0x7faa
movq -0x1b0(%rbp), %rdi
cmpq %r12, %rdi
je 0x526b
callq 0x3360
movq 0xb216(%rip), %rax      # 0x10488
cmpq 0xb1ef(%rip), %rax      # 0x10468
jne 0x51e9
jmp 0x51b5
movq %rax, %rbx
movq -0x210(%rbp), %rdi
cmpq %r13, %rdi
je 0x529d
callq 0x3360
jmp 0x529d
movq %rax, %rbx
movq -0x1b0(%rbp), %rdi
cmpq %r12, %rdi
jne 0x538a
jmp 0x53fd
jmp 0x53fa
jmp 0x5447
jmp 0x52e8
movq %rax, %rbx
leaq -0xc0(%rbp), %rax
jmp 0x52d6
jmp 0x52e8
movq %rax, %rbx
leaq -0x220(%rbp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x5456
jmp 0x545b
movq %rax, %rbx
jmp 0x545b
jmp 0x53d5
jmp 0x53fa
jmp 0x53fa
movq %rax, %rbx
movq -0x130(%rbp), %rdi
leaq -0x120(%rbp), %rax
jmp 0x5385
movq %rax, %rbx
movq -0x190(%rbp), %rdi
leaq -0x180(%rbp), %rax
cmpq %rax, %rdi
je 0x5332
callq 0x3360
jmp 0x5332
movq %rax, %rbx
movq -0x150(%rbp), %rdi
leaq -0x140(%rbp), %rax
jmp 0x5385
movq %rax, %rbx
movq -0x1f0(%rbp), %rdi
leaq -0x1e0(%rbp), %rax
jmp 0x5385
jmp 0x53b9
movq %rax, %rbx
movq -0x1d0(%rbp), %rdi
leaq -0x1c0(%rbp), %rax
cmpq %rax, %rdi
je 0x53bc
callq 0x3360
jmp 0x53bc
movq %rax, %rbx
movq -0x170(%rbp), %rdi
leaq -0x160(%rbp), %rax
cmpq %rax, %rdi
je 0x53fd
callq 0x3360
jmp 0x53fd
jmp 0x53d5
movq %rax, %rbx
jmp 0x5427
jmp 0x53b2
jmp 0x539f
movq %rax, %rbx
movq -0x110(%rbp), %rdi
leaq -0x100(%rbp), %rax
jmp 0x540b
movq %rax, %rbx
jmp 0x5415
jmp 0x53fa
movq %rax, %rbx
leaq -0xc0(%rbp), %r13
jmp 0x544a
jmp 0x5447
jmp 0x5447
jmp 0x53d5
movq %rax, %rbx
jmp 0x53ef
jmp 0x53fa
movq %rax, %rbx
jmp 0x5439
movq %rax, %rbx
movq -0x50(%rbp), %rdi
leaq -0x40(%rbp), %rax
cmpq %rax, %rdi
je 0x53ef
callq 0x3360
movq -0x70(%rbp), %rdi
cmpq %r13, %rdi
jne 0x5434
jmp 0x5439
movq %rax, %rbx
movq -0xf0(%rbp), %rdi
leaq -0xe0(%rbp), %rax
cmpq %rax, %rdi
je 0x5415
callq 0x3360
movq -0x50(%rbp), %rdi
leaq -0x40(%rbp), %rax
cmpq %rax, %rdi
je 0x5427
callq 0x3360
movq -0x70(%rbp), %rdi
leaq -0x60(%rbp), %rax
cmpq %rax, %rdi
je 0x5439
callq 0x3360
leaq -0xd0(%rbp), %rdi
callq 0x74e8
jmp 0x545b
movq %rax, %rbx
movq -0xd0(%rbp), %rdi
cmpq %r13, %rdi
je 0x545b
callq 0x3360
movq %rbx, %rdi
callq 0x35c0