// File: /workspace/github_cpp_makefile_star2_O2/ncbi[P]amr/common.cpp
// Function: Common_sp::setSymlink(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>> const&, bool)
void setSymlink (string fromFName,
                 const string &toFName,
                 bool fromPathIsAbsolute)
{ 
  ASSERT (! fromFName. empty ());
  ASSERT (! toFName. empty ());
  const string err (string ("Cannot make ") + (fromPathIsAbsolute ? "an absolute" : "a relative") + " symlink for " + strQuote (fromFName) + " as " + strQuote (toFName));
  if (fromPathIsAbsolute)
    fromFName = path2canonical (fromFName);
  else
  { 
    if (fromFName [0] == '/')
      throw runtime_error (err + " because " + strQuote (fromFName) + " is absolute");
    const Dir dir (toFName);
    const string absPath (dir. getParent () + "/" + fromFName);
    if (getFiletype (absPath, false) == Filetype::none)
      throw runtime_error (err + " because " + strQuote (absPath) + " does not exist");
  }
  if (symlink (fromFName. c_str (), toFName. c_str ()))
    throw runtime_error (err);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
subq $0x108, %rsp            # imm = 0x108
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
callq 0xb060
andl $0x0, (%rax)
cmpq $0x0, 0x8(%rbx)
je 0x26d25
cmpq $0x0, 0x8(%r14)
je 0x26df9
leaq 0x35477(%rip), %rsi     # 0x5bf9f
leaq 0xa8(%rsp), %rdi
leaq 0x6(%rsp), %rdx
callq 0x1b7b6
leaq 0x3546b(%rip), %rax     # 0x5bfac
leaq 0x35470(%rip), %rdx     # 0x5bfb8
testb %bpl, %bpl
cmovneq %rax, %rdx
leaq 0x68(%rsp), %rdi
leaq 0xa8(%rsp), %rsi
callq 0x1b92d
leaq 0x3545b(%rip), %rdx     # 0x5bfc3
leaq 0x8(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0x1b92d
leaq 0x88(%rsp), %rdi
pushq $0x22
popq %rdx
movq %rbx, %rsi
callq 0x243b1
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
leaq 0x88(%rsp), %rdx
callq 0x1ca3c
leaq 0x3706f(%rip), %rdx     # 0x5dc17
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0x1b92d
leaq 0xe8(%rsp), %rdi
pushq $0x22
popq %rdx
movq %r14, %rsi
callq 0x243b1
leaq 0xc8(%rsp), %rdi
leaq 0x48(%rsp), %rsi
leaq 0xe8(%rsp), %rdx
callq 0x1ca3c
leaq 0xe8(%rsp), %rdi
callq 0xbb68
leaq 0x48(%rsp), %rdi
callq 0xbb68
leaq 0x28(%rsp), %rdi
callq 0xbb68
leaq 0x88(%rsp), %rdi
callq 0xbb68
leaq 0x8(%rsp), %rdi
callq 0xbb68
leaq 0x68(%rsp), %rdi
callq 0xbb68
leaq 0xa8(%rsp), %rdi
callq 0xbb68
testb %bpl, %bpl
je 0x26c62
leaq 0x48(%rsp), %rdi
movq %rbx, %rsi
callq 0x1cfeb
leaq 0x48(%rsp), %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0xb6f0
movq %r15, %rdi
callq 0xbb68
jmp 0x26cf7
movq (%rbx), %rax
cmpb $0x2f, (%rax)
je 0x26f0b
leaq 0x88(%rsp), %rdi
movq %r14, %rsi
callq 0x2632c
leaq 0x8(%rsp), %rdi
leaq 0x88(%rsp), %rsi
callq 0x1cbce
leaq 0x35644(%rip), %rdx     # 0x5c2db
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1b92d
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
movq %rbx, %rdx
callq 0x1cbaf
leaq 0x28(%rsp), %rdi
callq 0xbb68
leaq 0x8(%rsp), %rdi
callq 0xbb68
leaq 0x48(%rsp), %rdi
xorl %esi, %esi
callq 0x24f38
testl %eax, %eax
je 0x26f96
leaq 0x48(%rsp), %rdi
callq 0xbb68
leaq 0x88(%rsp), %rdi
callq 0x1e654
movq (%rbx), %rdi
movq (%r14), %rsi
callq 0xb070
testl %eax, %eax
jne 0x26ed5
leaq 0xc8(%rsp), %rdi
callq 0xbb68
addq $0x108, %rsp            # imm = 0x108
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
callq 0xb6c0
testl %eax, %eax
jne 0x26ecd
leaq 0x34c08(%rip), %rsi     # 0x5b941
leaq 0x68(%rsp), %rdi
leaq 0x6(%rsp), %rdx
callq 0x1b7b6
leaq 0xa8(%rsp), %rdi
movl $0x5cd, %esi            # imm = 0x5CD
callq 0x1caa3
leaq 0x8(%rsp), %rdi
leaq 0x68(%rsp), %rsi
leaq 0xa8(%rsp), %rdx
callq 0x1ca3c
leaq 0x32e6b(%rip), %rdx     # 0x59be3
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1b92d
leaq 0x351ae(%rip), %rsi     # 0x5bf3c
leaq 0xe8(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x1b7b6
leaq 0x34b97(%rip), %rdx     # 0x5b93e
leaq 0x88(%rsp), %rdi
leaq 0xe8(%rsp), %rsi
callq 0x1b92d
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
leaq 0x88(%rsp), %rdx
callq 0x1ca3c
leaq 0x3519b(%rip), %rdx     # 0x5bf75
leaq 0xc8(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x1b92d
leaq 0xc8(%rsp), %rdi
callq 0x224fc
callq 0xb6c0
testl %eax, %eax
jne 0x26ecd
leaq 0x34b34(%rip), %rsi     # 0x5b941
leaq 0x68(%rsp), %rdi
leaq 0x6(%rsp), %rdx
callq 0x1b7b6
leaq 0xa8(%rsp), %rdi
movl $0x5ce, %esi            # imm = 0x5CE
callq 0x1caa3
leaq 0x8(%rsp), %rdi
leaq 0x68(%rsp), %rsi
leaq 0xa8(%rsp), %rdx
callq 0x1ca3c
leaq 0x32d97(%rip), %rdx     # 0x59be3
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1b92d
leaq 0x350da(%rip), %rsi     # 0x5bf3c
leaq 0xe8(%rsp), %rdi
leaq 0x7(%rsp), %rdx
callq 0x1b7b6
leaq 0x34ac3(%rip), %rdx     # 0x5b93e
leaq 0x88(%rsp), %rdi
leaq 0xe8(%rsp), %rsi
callq 0x1b92d
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
leaq 0x88(%rsp), %rdx
callq 0x1ca3c
leaq 0x350dd(%rip), %rdx     # 0x5bf8b
leaq 0xc8(%rsp), %rdi
leaq 0x48(%rsp), %rsi
callq 0x1b92d
leaq 0xc8(%rsp), %rdi
callq 0x224fc
pushq $0x1
popq %rdi
callq 0xb6d0
pushq $0x10
popq %rdi
callq 0xb300
movq %rax, %r14
leaq 0xc8(%rsp), %rsi
movq %rax, %rdi
callq 0xb940
movq 0x5d0f1(%rip), %rsi     # 0x83fe8
movq 0x5d062(%rip), %rdx     # 0x83f60
movq %r14, %rdi
callq 0xb9d0
jmp 0x27024
pushq $0x10
popq %rdi
callq 0xb300
movq %rax, %r14
leaq 0x350b4(%rip), %rdx     # 0x5bfd1
leaq 0x8(%rsp), %rdi
leaq 0xc8(%rsp), %rsi
callq 0x1c88d
leaq 0x68(%rsp), %rdi
pushq $0x22
popq %rdx
movq %rbx, %rsi
callq 0x243b1
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
leaq 0x68(%rsp), %rdx
callq 0x1ca3c
leaq 0x35081(%rip), %rdx     # 0x5bfdb
leaq 0x48(%rsp), %rdi
leaq 0x28(%rsp), %rsi
callq 0x1b92d
movb $0x1, %bpl
leaq 0x48(%rsp), %rsi
movq %r14, %rdi
callq 0xb940
xorl %ebp, %ebp
movq 0x5d066(%rip), %rsi     # 0x83fe8
movq 0x5cfd7(%rip), %rdx     # 0x83f60
movq %r14, %rdi
callq 0xb9d0
jmp 0x27024
pushq $0x10
popq %rdi
callq 0xb300
movq %rax, %r14
leaq 0x35029(%rip), %rdx     # 0x5bfd1
leaq 0x68(%rsp), %rdi
leaq 0xc8(%rsp), %rsi
callq 0x1c88d
leaq 0xa8(%rsp), %rdi
leaq 0x48(%rsp), %rsi
pushq $0x22
popq %rdx
callq 0x243b1
leaq 0x8(%rsp), %rdi
leaq 0x68(%rsp), %rsi
leaq 0xa8(%rsp), %rdx
callq 0x1ca3c
leaq 0x34ffb(%rip), %rdx     # 0x5bfe8
leaq 0x28(%rsp), %rdi
leaq 0x8(%rsp), %rsi
callq 0x1b92d
movb $0x1, %bpl
leaq 0x28(%rsp), %rsi
movq %r14, %rdi
callq 0xb940
xorl %ebp, %ebp
movq 0x5cfd3(%rip), %rsi     # 0x83fe8
movq 0x5cf44(%rip), %rdx     # 0x83f60
movq %r14, %rdi
callq 0xb9d0
jmp 0x27028
jmp 0x2703a
movq %rax, %rbx
leaq 0xc8(%rsp), %rdi
callq 0xbb68
jmp 0x2703d
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0xbb68
jmp 0x2704e
jmp 0x2704b
movq %rax, %rbx
leaq 0x88(%rsp), %rdi
callq 0xbb68
jmp 0x27062
jmp 0x2705f
movq %rax, %rbx
leaq 0xe8(%rsp), %rdi
callq 0xbb68
jmp 0x27076
jmp 0x27073
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xbb68
jmp 0x270c9
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xbb68
jmp 0x27097
movq %rax, %rbx
movb $0x1, %bpl
leaq 0x8(%rsp), %rdi
callq 0xbb68
jmp 0x270db
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0xbb68
jmp 0x270b8
movq %rax, %rbx
movb $0x1, %bpl
leaq 0x28(%rsp), %rdi
callq 0xbb68
jmp 0x270f0
jmp 0x270c6
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0xbb68
jmp 0x27101
movq %rax, %rbx
movb $0x1, %bpl
leaq 0xa8(%rsp), %rdi
callq 0xbb68
jmp 0x27116
movq %rax, %rbx
movb $0x1, %bpl
leaq 0x68(%rsp), %rdi
callq 0xbb68
jmp 0x2712d
jmp 0x270fe
movq %rax, %rbx
leaq 0xa8(%rsp), %rdi
callq 0xbb68
jmp 0x27143
movq %rax, %rbx
movb $0x1, %bpl
leaq 0x68(%rsp), %rdi
callq 0xbb68
testb %bpl, %bpl
jne 0x27150
jmp 0x27169
movq %rax, %rbx
movb $0x1, %bpl
leaq 0x8(%rsp), %rdi
callq 0xbb68
testb %bpl, %bpl
jne 0x27175
jmp 0x271b4
jmp 0x27140
movq %rax, %rbx
leaq 0x68(%rsp), %rdi
jmp 0x2721f
movq %rax, %rbx
movq %r14, %rdi
callq 0xb470
jmp 0x27169
jmp 0x27172
jmp 0x27236
jmp 0x27236
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
jmp 0x27196
jmp 0x271b1
movq %rax, %rbx
movq %r14, %rdi
callq 0xb470
jmp 0x271b4
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xbb68
jmp 0x27191
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0xbb68
jmp 0x271a0
movq %rax, %rbx
leaq 0x88(%rsp), %rdi
callq 0x1e654
jmp 0x271b4
jmp 0x271b1
movq %rax, %rbx
leaq 0xc8(%rsp), %rdi
jmp 0x2721f
movq %rax, %rbx
leaq 0xe8(%rsp), %rdi
callq 0xbb68
jmp 0x271d3
movq %rax, %rbx
leaq 0x48(%rsp), %rdi
callq 0xbb68
jmp 0x271e2
movq %rax, %rbx
leaq 0x28(%rsp), %rdi
callq 0xbb68
jmp 0x271f1
movq %rax, %rbx
leaq 0x88(%rsp), %rdi
callq 0xbb68
jmp 0x27203
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0xbb68
leaq 0x68(%rsp), %rdi
callq 0xbb68
leaq 0xa8(%rsp), %rdi
callq 0xbb68
movq %rbx, %rdi
callq 0xba30
movq %rax, %rbx
jmp 0x2720d
movq %rax, %rbx
jmp 0x27217
movq %rax, %rbx
jmp 0x27224