History

Revert 337dc84b (other -static fix)

this should work now with 05f6aa1a.

Michael Matz committed 7 years ago

Commit 45b8b0e1 parent 05f6aa11 file · +5 −1Browse files

Unified · Split

x86_64-gen.c+5−1
@@ -625,7 +625,11 @@ static void gcall_or_jmp(int is_jmp) · 624 unmodified lines
625625 if ((vtop->r & (VT_VALMASK | VT_LVAL)) == VT_CONST &&
626626 ((vtop->r & VT_SYM) && (vtop->c.i-4) == (int)(vtop->c.i-4))) {
627627 /* constant symbolic case -> simple relocation */
628− greloca(cur_text_section, vtop->sym, ind + 1, R_X86_64_PLT32, (int)(vtop->c.i-4));
628+#ifdef TCC_TARGET_PE
629+ greloca(cur_text_section, vtop->sym, ind + 1, R_X86_64_PC32, (int)(vtop->c.i-4));
630+#else
631+ greloca(cur_text_section, vtop->sym, ind + 1, R_X86_64_PLT32, (int)(vtop->c.i-4));
632+#endif
629633 oad(0xe8 + is_jmp, 0); /* call/jmp im */
630634 } else {
631635 /* otherwise, indirect call */

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t