Revert "Revert "Merge branch 'master' of https://github.com/mono/mono""
[mono.git] / mono / utils / Makefile.am
1 noinst_LTLIBRARIES = libmonoutils.la
2
3 AM_CPPFLAGS = -I$(top_srcdir) -I$(top_srcdir)/mono $(LIBGC_CPPFLAGS) $(GLIB_CFLAGS)
4
5 if ENABLE_DTRACE
6
7 BUILT_SOURCES = mono-dtrace.h
8
9 mono-dtrace.h: $(top_srcdir)/data/mono.d
10         $(DTRACE) $(DTRACEFLAGS) -h -s $(top_srcdir)/data/mono.d -o $@ || > $@
11
12 endif
13
14 monoutils_sources = \
15         mono-md5.c              \
16         mono-sha1.c             \
17         mono-logger.c           \
18         mono-logger-internal.h  \
19         mono-codeman.c          \
20         dlmalloc.h              \
21         dlmalloc.c              \
22         mono-counters.c         \
23         mono-compiler.h         \
24         mono-dl.c               \
25         mono-dl.h               \
26         mono-internal-hash.c    \
27         mono-internal-hash.h    \
28         mono-io-portability.c   \
29         mono-io-portability.h   \
30         monobitset.c            \
31         mono-filemap.c          \
32         mono-math.c             \
33         mono-mmap.c             \
34         mono-mmap.h             \
35         mono-mutex.c            \
36         mono-mutex.h            \
37         mono-networkinterfaces.c                \
38         mono-networkinterfaces.h                \
39         mono-proclib.c          \
40         mono-proclib.h          \
41         mono-publib.c           \
42         mono-string.h           \
43         mono-time.c             \
44         mono-time.h             \
45         strtod.h                \
46         strtod.c                \
47         strenc.h                \
48         strenc.c                \
49         mono-uri.c              \
50         mono-poll.c             \
51         mono-path.c             \
52         mono-semaphore.c        \
53         mono-semaphore.h        \
54         mono-sigcontext.h       \
55         mono-stdlib.c           \
56         mono-property-hash.h    \
57         mono-property-hash.c    \
58         mono-value-hash.h       \
59         mono-value-hash.c       \
60         freebsd-elf_common.h    \
61         freebsd-elf32.h         \
62         freebsd-elf64.h         \
63         freebsd-dwarf.h         \
64         dtrace.h                        \
65         gc_wrapper.h            \
66         mono-error.c    \
67         mono-error-internals.h  \
68         monobitset.h    \
69         mono-codeman.h  \
70         mono-counters.h \
71         mono-digest.h   \
72         mono-error.h    \
73         mono-machine.h  \
74         mono-math.h     \
75         mono-membar.h   \
76         mono-path.h     \
77         mono-poll.h     \
78         mono-uri.h      \
79         mono-stdlib.h   \
80         valgrind.h      \
81         mach-support.c  \
82         mach-support.h  \
83         memcheck.h      \
84         mono-context.c  \
85         mono-context.h  \
86         mono-stack-unwinding.h  \
87         hazard-pointer.c        \
88         hazard-pointer.h        \
89         lock-free-queue.c       \
90         lock-free-queue.h       \
91         lock-free-alloc.c       \
92         lock-free-alloc.h       \
93         lock-free-array-queue.c \
94         lock-free-array-queue.h \
95         mono-linked-list-set.c  \
96         mono-linked-list-set.h  \
97         mono-threads.c  \
98         mono-threads-posix.c    \
99         mono-threads-mach.c     \
100         mono-threads-mach-helper.c      \
101         mono-threads-windows.c  \
102         mono-threads.h  \
103         mono-tls.h      \
104         mono-tls.c      \
105         linux_magic.h   \
106         mono-memory-model.h     \
107         atomic.h        \
108         atomic.c        \
109         mono-hwcap.h    \
110         mono-hwcap.c    \
111         bsearch.h       \
112         bsearch.c       \
113         mono-signal-handler.h
114
115 arch_sources = 
116
117 if !CROSS_COMPILE
118
119 if X86
120 arch_sources += mach-support-x86.c
121 endif
122
123 if AMD64
124 arch_sources += mach-support-amd64.c
125 endif
126
127 if ARM
128 arch_sources += mach-support-arm.c
129 endif
130
131 if ARM64
132 arch_sources += mach-support-arm.c
133 endif
134
135 else
136
137 arch_sources += mach-support-unknown.c
138
139 endif
140
141 if X86
142 arch_sources += mono-hwcap-x86.c mono-hwcap-x86.h
143 endif
144
145 if AMD64
146 arch_sources += mono-hwcap-x86.c mono-hwcap-x86.h
147 endif
148
149 if ARM
150 arch_sources += mono-hwcap-arm.c mono-hwcap-arm.h
151 endif
152
153 if ARM64
154 arch_sources += mono-hwcap-arm64.c mono-hwcap-arm64.h
155 endif
156
157 if MIPS
158 arch_sources += mono-hwcap-mips.c mono-hwcap-mips.h
159 endif
160
161 if POWERPC
162 arch_sources += mono-hwcap-ppc.c mono-hwcap-ppc.h
163 endif
164
165 if POWERPC64
166 arch_sources += mono-hwcap-ppc.c mono-hwcap-ppc.h
167 endif
168
169 if SPARC
170 arch_sources += mono-hwcap-sparc.c mono-hwcap-sparc.h
171 endif
172
173 if SPARC64
174 arch_sources += mono-hwcap-sparc.c mono-hwcap-sparc.h
175 endif
176
177 if IA64
178 arch_sources += mono-hwcap-ia64.c mono-hwcap-ia64.h
179 endif
180
181 if S390X
182 arch_sources += mono-hwcap-s390x.c mono-hwcap-s390x.h
183 endif
184
185 libmonoutils_la_SOURCES = $(monoutils_sources) $(arch_sources)
186 libmonoutilsincludedir = $(includedir)/mono-$(API_VER)/mono/utils
187
188 libmonoutilsinclude_HEADERS =   \
189         mono-logger.h           \
190         mono-error.h            \
191         mono-publib.h           \
192         mono-dl-fallback.h
193
194 EXTRA_DIST = ChangeLog mono-embed.h mono-embed.c