ifuncmod6.c 287 B

1234567891011121314151617181920212223
  1. /* Test STT_GNU_IFUNC symbol reference in a shared library. */
  2. extern int foo (void);
  3. typedef int (*foo_p) (void);
  4. extern foo_p get_foo_p (void);
  5. extern foo_p get_foo (void);
  6. foo_p foo_ptr = foo;
  7. foo_p
  8. get_foo_p (void)
  9. {
  10. return foo_ptr;
  11. }
  12. foo_p
  13. get_foo (void)
  14. {
  15. return foo;
  16. }