hc
2024-11-01 2f529f9b558ca1c1bd74be7437a84e4711743404
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
testdir = @XENO_TEST_DIR@
test_PROGRAMS = smokey
 
CCLD = $(top_srcdir)/scripts/wrap-link.sh $(CC)
 
smokey_SOURCES = main.c
 
# Make sure to list modules from the most dependent to the
# least. e.g. net_common should appear after all net_* modules,
# memcheck should appear after all heapmem-* modules.
 
COBALT_SUBDIRS =     \
   arith         \
   bufp        \
   cpu-affinity    \
   fpu-stress    \
   gdb        \
   iddp        \
   leaks        \
   memory-coreheap    \
   memory-heapmem    \
   memory-tlsf    \
   memcheck    \
   net_packet_dgram\
   net_packet_raw    \
   net_udp        \
   net_common    \
   posix-clock    \
   posix-cond     \
   posix-fork    \
   posix-mutex     \
   posix-select     \
   rtdm         \
   sched-quota     \
   sched-tp     \
   setsched    \
   sigdebug    \
   timerfd        \
   tsc        \
   vdso-access     \
   xddp        \
   y2038
 
MERCURY_SUBDIRS =    \
   memory-heapmem    \
   memory-tlsf    \
   memcheck
 
DIST_SUBDIRS =         \
   arith         \
   bufp        \
   cpu-affinity    \
   dlopen        \
   fpu-stress    \
   gdb        \
   iddp        \
   leaks        \
   memory-coreheap    \
   memory-heapmem    \
   memory-pshared    \
   memory-tlsf    \
   memcheck    \
   net_packet_dgram\
   net_packet_raw    \
   net_udp        \
   net_common    \
   posix-clock    \
   posix-cond     \
   posix-fork    \
   posix-mutex     \
   posix-select     \
   rtdm         \
   sched-quota     \
   sched-tp     \
   setsched    \
   sigdebug    \
   timerfd        \
   tsc        \
   vdso-access     \
   xddp        \
   y2038
 
if XENO_COBALT
if CONFIG_XENO_LIBS_DLOPEN
COBALT_SUBDIRS += dlopen
endif
if XENO_PSHARED
COBALT_SUBDIRS += memory-pshared
endif
wrappers = $(XENO_POSIX_WRAPPERS)
SUBDIRS = $(COBALT_SUBDIRS)
else
if XENO_PSHARED
MERCURY_SUBDIRS += memory-pshared
endif
SUBDIRS = $(MERCURY_SUBDIRS)
wrappers =
endif
 
plugin_list = $(foreach plugin,$(SUBDIRS),$(plugin)/lib$(plugin).a)
# wrap-link.sh is confused by -whole-archive, so work around
# this by forcing undefined references to symbols we expect the
# plugins to export.
sym_prefix=@XENO_SYMBOL_PREFIX@
undef_list = $(foreach plugin,$(SUBDIRS),-u $(sym_prefix)smokey_plugin_$(subst -,_,$(plugin)))
 
smokey_CPPFLAGS =             \
   $(XENO_USER_CFLAGS)        \
   -I$(top_srcdir)/include
 
smokey_LDFLAGS=$(wrappers) @XENO_AUTOINIT_LDFLAGS@ $(undef_list)
 
smokey_LDADD =                     \
   $(plugin_list)                \
   ../../lib/smokey/libsmokey@CORE@.la        \
   ../../lib/copperplate/libcopperplate@CORE@.la    \
   @XENO_CORE_LDADD@            \
    @XENO_USER_LDADD@            \
   -lpthread -lrt