3 # Copyright (c) 2013, Ben Noordhuis <info@bnoordhuis.nl>
5 # Permission to use, copy, modify, and/or distribute this software for any
6 # purpose with or without fee is hereby granted, provided that the above
7 # copyright notice and this permission notice appear in all copies.
9 # THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
10 # WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
11 # MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
12 # ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
13 # WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
14 # ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
15 # OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 SPARSE=${SPARSE:-sparse}
19 SPARSE_FLAGS=${SPARSE_FLAGS:-"
23 -Wno-transparent-union
39 src/unix/getaddrinfo.c
41 src/unix/loop-watcher.c
59 test/benchmark-async-pummel.c
60 test/benchmark-async.c
61 test/benchmark-fs-stat.c
62 test/benchmark-getaddrinfo.c
63 test/benchmark-loop-count.c
64 test/benchmark-million-async.c
65 test/benchmark-million-timers.c
66 test/benchmark-multi-accept.c
67 test/benchmark-ping-pongs.c
68 test/benchmark-pound.c
70 test/benchmark-sizes.c
71 test/benchmark-spawn.c
72 test/benchmark-tcp-write-batch.c
73 test/benchmark-thread.c
74 test/benchmark-udp-pummel.c
75 test/blackhole-server.c
88 test/test-callback-order.c
89 test/test-callback-stack.c
91 test/test-connection-fail.c
92 test/test-cwd-and-chdir.c
93 test/test-delayed-accept.c
97 test/test-fail-always.c
101 test/test-get-currentexe.c
102 test/test-get-loadavg.c
103 test/test-get-memory.c
104 test/test-getaddrinfo.c
105 test/test-getsockname.c
109 test/test-ipc-send-recv.c
111 test/test-loop-handles.c
112 test/test-multiple-listen.c
114 test/test-pass-always.c
115 test/test-ping-pong.c
116 test/test-pipe-bind-error.c
117 test/test-pipe-connect-error.c
118 test/test-pipe-server-close.c
119 test/test-platform-output.c
120 test/test-poll-close.c
122 test/test-process-title.c
124 test/test-run-nowait.c
126 test/test-semaphore.c
127 test/test-shutdown-close.c
128 test/test-shutdown-eof.c
129 test/test-signal-multiple-loops.c
132 test/test-stdio-over-pipes.c
133 test/test-tcp-bind-error.c
134 test/test-tcp-bind6-error.c
135 test/test-tcp-close-while-connecting.c
136 test/test-tcp-close-accept.c
137 test/test-tcp-close.c
138 test/test-tcp-connect-error-after-write.c
139 test/test-tcp-connect-error.c
140 test/test-tcp-connect-timeout.c
141 test/test-tcp-connect6-error.c
142 test/test-tcp-flags.c
144 test/test-tcp-read-stop.c
145 test/test-tcp-shutdown-after-write.c
146 test/test-tcp-unexpected-read.c
147 test/test-tcp-write-error.c
148 test/test-tcp-write-to-half-open-connection.c
149 test/test-tcp-writealot.c
151 test/test-threadpool-cancel.c
152 test/test-threadpool.c
153 test/test-timer-again.c
156 test/test-udp-dgram-too-big.c
158 test/test-udp-multicast-join.c
159 test/test-udp-multicast-ttl.c
161 test/test-udp-options.c
162 test/test-udp-send-and-recv.c
163 test/test-walk-handles.c
164 test/test-watcher-cross-stop.c
169 SPARSE_FLAGS="$SPARSE_FLAGS -D_AIX=1"
174 SPARSE_FLAGS="$SPARSE_FLAGS -D__APPLE__=1"
182 SPARSE_FLAGS="$SPARSE_FLAGS -D__DragonFly__=1"
189 SPARSE_FLAGS="$SPARSE_FLAGS -D__FreeBSD__=1"
196 SPARSE_FLAGS="$SPARSE_FLAGS -D__linux__=1"
199 src/unix/linux-inotify.c
200 src/unix/linux-core.c
201 src/unix/linux-syscalls.c
202 src/unix/linux-syscalls.h"
205 SPARSE_FLAGS="$SPARSE_FLAGS -D__NetBSD__=1"
212 SPARSE_FLAGS="$SPARSE_FLAGS -D__OpenBSD__=1"
219 SPARSE_FLAGS="$SPARSE_FLAGS -D__sun=1"
226 for ARCH in __i386__ __x86_64__ __arm__ __mips__; do
227 $SPARSE $SPARSE_FLAGS -D$ARCH=1 $SOURCES
230 # Tests are architecture independent.
231 $SPARSE $SPARSE_FLAGS -Itest $TESTS