summaryrefslogtreecommitdiff
path: root/test/ldso/howdy.c
blob: e2724068e560c62ba4a793d733907192134a37b7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
#include <pthread.h>
#include <stdio.h>

extern int __pthread_return_0 (void);

int howdy(const char *s)
{
    return printf("howdy:  __pthread_return_0 = %p\n"
		  "howdy: pthread_cond_signal = %p\n",
		  __pthread_return_0, pthread_cond_signal);
}

void __attribute__((constructor)) howdy_ctor(void)
{
    printf("I am the libhowdy constructor!\n");
}

void __attribute__((destructor)) howdy_dtor(void)
{
    printf("I am the libhowdy destructor!\n");
}