libversionedlikeglibc.c 432 Bytes
Newer Older
1 2 3 4 5
__attribute__((__visibility__("default"))) int symbol1(int);
int symbol1(int x) { return x; }
__asm__(".symver _original_symbol2,symbol2@LIBVERSIONED1");
__attribute__((__visibility__("default"))) int _original_symbol2(int);
int _original_symbol2(int x) { return x; }
6 7 8
__asm__(".symver _new_symbol2,symbol2@@LIBVERSIONED2");
__attribute__((__visibility__("default"))) int _new_symbol2(int);
int _new_symbol2(int x) { return x + 1; }