History

Add -Wl,-install_name macOS clang compatible flag as clang refuses -Wl,-soname. This helps configure scripts using both clang and tcc.

Christian Jullien committed 3 years ago

Commit 95e39511 parent 3fd6a052 files · +5 −0Browse files

Unified · Split

2 files
  1. libtcc.c +2 −0
  2. tcc.c +3 −0
libtcc.c+2−0
@@ -1450,6 +1450,8 @@ static int tcc_set_linker(TCCState *s, const char *option) · 1449 unmodified lines
1450 s->section_align = strtoul(p, &end, 16);1450 s->section_align = strtoul(p, &end, 16);
1451 } else if (link_option(option, "soname=", &p)) {1451 } else if (link_option(option, "soname=", &p)) {
1452 copy_linker_arg(&s->soname, p, 0);1452 copy_linker_arg(&s->soname, p, 0);
1453 } else if (link_option(option, "install_name=", &p)) {
1454 copy_linker_arg(&s->soname, p, 0);
1453#ifdef TCC_TARGET_PE1455#ifdef TCC_TARGET_PE
1454 } else if (link_option(option, "large-address-aware", &p)) {1456 } else if (link_option(option, "large-address-aware", &p)) {
1455 s->pe_characteristics |= 0x20;1457 s->pe_characteristics |= 0x20;
tcc.c+3−0
@@ -142,6 +142,9 @@ static const char help2[] = · 141 unmodified lines
142 " -rpath= set dynamic library search path\n"142 " -rpath= set dynamic library search path\n"
143 " -enable-new-dtags set DT_RUNPATH instead of DT_RPATH\n"143 " -enable-new-dtags set DT_RUNPATH instead of DT_RPATH\n"
144 " -soname= set DT_SONAME elf tag\n"144 " -soname= set DT_SONAME elf tag\n"
145#if defined(TCC_TARGET_MACHO)
146 " -install_name= set DT_SONAME elf tag (soname macOS alias)\n"
147#endif
145 " -Bsymbolic set DT_SYMBOLIC elf tag\n"148 " -Bsymbolic set DT_SYMBOLIC elf tag\n"
146 " -oformat=[elf32/64-* binary] set executable output format\n"149 " -oformat=[elf32/64-* binary] set executable output format\n"
147 " -init= -fini= -Map= -as-needed -O (ignored)\n"150 " -init= -fini= -Map= -as-needed -O (ignored)\n"

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