|
// declare base_func; mark it as an exported symbol
|
|
__attribute__ ((visibility ("default"))) void base_func(void);
|
|
|
|
// define base_func
|
|
#include <stdio.h>
|
|
int x = 0;
|
|
__attribute__ ((visibility ("default"))) void
|
|
base_func(void){
|
|
printf("x = %d\n", x);
|
|
x += 1;
|
|
}
|