Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / native_client / src / untrusted / nacl / BUILD.gn
1 # Copyright (c) 2014 The Native ClientAuthors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
4
5
6 import("//native_client/build/toolchain/nacl/nacl_sdk.gni")
7
8 #  Autogenerated from src/untrusted/nacl/nacl.scons.
9
10
11 static_library("nacl_dyncode_private") {
12   cflags_c = []
13   sources = [
14     "dyncode_private.c",
15   ]
16
17   if (cpu_arch == "pnacl") {
18     cflags_c += [
19       "-Wno-self-assign",
20       "-allow-asm",
21     ]
22   }
23 }
24 static_library("nacl_random_private") {
25   cflags_c = []
26   sources = [
27     "irt_nameservice",
28     "irt_random",
29   ]
30
31   if (cpu_arch == "pnacl") {
32     cflags_c += [
33       "-Wno-self-assign",
34       "-allow-asm",
35     ]
36   }
37 }
38 static_library("nacl_sys_private") {
39   cflags_c = []
40   sources = [
41     "null.c",
42     "sysbrk.c",
43   ]
44
45   if (os != "glibc") {
46     sources += [
47       "None",
48       "private_blockhook",
49     ]
50   }
51
52   if (cpu_arch == "pnacl") {
53     cflags_c += [
54       "-Wno-self-assign",
55       "-allow-asm",
56     ]
57   }
58 }
59 static_library("imc_syscalls") {
60   cflags_c = []
61   sources = [
62     "imc_accept.c",
63     "imc_connect.c",
64     "imc_makeboundsock.c",
65     "imc_mem_obj_create.c",
66     "imc_recvmsg.c",
67     "imc_sendmsg.c",
68     "imc_socketpair.c",
69     "nameservice.c",
70   ]
71
72   if (cpu_arch == "pnacl") {
73     cflags_c += [
74       "-Wno-self-assign",
75       "-allow-asm",
76     ]
77   }
78 }
79 static_library("nacl_exception_private") {
80   cflags_c = []
81   sources = [
82     "nacl_exception_private.c",
83   ]
84
85   if (cpu_arch == "pnacl") {
86     cflags_c += [
87       "-Wno-self-assign",
88       "-allow-asm",
89     ]
90   }
91 }
92 static_library("nacl_list_mappings_private") {
93   cflags_c = []
94   sources = [
95     "list_mappings_private.c",
96   ]
97
98   if (cpu_arch == "pnacl") {
99     cflags_c += [
100       "-Wno-self-assign",
101       "-allow-asm",
102     ]
103   }
104 }
105 static_library("nacl_dyncode") {
106   cflags_c = []
107   sources = [
108     "dyncode.c",
109   ]
110
111   if (cpu_arch == "pnacl") {
112     cflags_c += [
113       "-Wno-self-assign",
114       "-allow-asm",
115     ]
116   }
117 }
118 static_library("nacl") {
119   cflags_c = ["-std=c99"]
120   sources = [
121     "gc_hooks.c",
122     "nacl_irt.c",
123     "nacl_irt_init.c",
124     "nacl_tls_get.c",
125     "nacl_tls_init.c",
126     "random.c",
127   ]
128
129   if (os != "glibc") {
130     sources += [
131       "_exit.c",
132       "abort.c",
133       "access.c",
134       "chdir.c",
135       "chmod.c",
136       "clock.c",
137       "clock_getres.c",
138       "clock_gettime.c",
139       "close.c",
140       "dup.c",
141       "fchdir.c",
142       "fchmod.c",
143       "fdatasync.c",
144       "fstat.c",
145       "fsync.c",
146       "ftruncate.c",
147       "getcwd.c",
148       "getdents.c",
149       "gethostname.c",
150       "getpagesize.c",
151       "getpid.c",
152       "gettimeofday.c",
153       "isatty.c",
154       "link.c",
155       "lock.c",
156       "lseek.c",
157       "lstat.c",
158       "malloc.c",
159       "mkdir.c",
160       "mmap.c",
161       "mprotect.c",
162       "munmap.c",
163       "nacl_add_tp.c",
164       "nacl_interface_query.c",
165       "nacl_irt_fdio.c",
166       "nacl_irt_filename.c",
167       "nacl_read_tp.c",
168       "nanosleep.c",
169       "open.c",
170       "pthread_initialize_minimal.c",
171       "pthread_stubs.c",
172       "read.c",
173       "readlink.c",
174       "rename.c",
175       "rmdir.c",
176       "sbrk.c",
177       "sched_yield.c",
178       "stacktrace.c",
179       "start.c",
180       "stat.c",
181       "stubs/_execve.c",
182       "stubs/chown.c",
183       "stubs/endpwent.c",
184       "stubs/environ.c",
185       "stubs/fchown.c",
186       "stubs/fcntl.c",
187       "stubs/fork.c",
188       "stubs/get_current_dir_name.c",
189       "stubs/getegid.c",
190       "stubs/geteuid.c",
191       "stubs/getgid.c",
192       "stubs/getlogin.c",
193       "stubs/getppid.c",
194       "stubs/getpwent.c",
195       "stubs/getpwnam.c",
196       "stubs/getpwnam_r.c",
197       "stubs/getpwuid.c",
198       "stubs/getpwuid_r.c",
199       "stubs/getrusage.c",
200       "stubs/getuid.c",
201       "stubs/getwd.c",
202       "stubs/ioctl.c",
203       "stubs/issetugid.c",
204       "stubs/kill.c",
205       "stubs/lchown.c",
206       "stubs/llseek.c",
207       "stubs/pipe.c",
208       "stubs/pselect.c",
209       "stubs/select.c",
210       "stubs/setegid.c",
211       "stubs/seteuid.c",
212       "stubs/setgid.c",
213       "stubs/setpwent.c",
214       "stubs/settimeofday.c",
215       "stubs/setuid.c",
216       "stubs/signal.c",
217       "stubs/sigprocmask.c",
218       "stubs/tcdrain.c",
219       "stubs/tcflow.c",
220       "stubs/tcflush.c",
221       "stubs/tcgetattr.c",
222       "stubs/tcsendbreak.c",
223       "stubs/tcsetattr.c",
224       "stubs/times.c",
225       "stubs/ttyname.c",
226       "stubs/ttyname_r.c",
227       "stubs/umask.c",
228       "stubs/utime.c",
229       "stubs/vfork.c",
230       "stubs/wait.c",
231       "stubs/waitpid.c",
232       "symlink.c",
233       "sysconf.c",
234       "tls.c",
235       "truncate.c",
236       "unlink.c",
237       "utimes.c",
238       "write.c",
239     ]
240   }
241
242   if ((os != "glibc") && (cpu_arch == "arm")) {
243     sources += [
244       "aeabi_read_tp.S",
245     ]
246   }
247
248   if (cpu_arch == "pnacl") {
249     cflags_c += [
250       "-Wno-self-assign",
251       "-allow-asm",
252     ]
253   }
254 }
255
256 source_set("irt_random") {
257   cflags_c = []
258   sources = [
259     "../../untrusted/irt/irt_random.c",
260   ]
261
262   if (cpu_arch == "pnacl") {
263     cflags_c += [
264       "-Wno-self-assign",
265       "-allow-asm",
266     ]
267   }
268 }
269 source_set("irt_nameservice") {
270   cflags_c = []
271   sources = [
272     "../../untrusted/irt/irt_nameservice.c",
273   ]
274
275   if (cpu_arch == "pnacl") {
276     cflags_c += [
277       "-Wno-self-assign",
278       "-allow-asm",
279     ]
280   }
281 }
282 static_library("nacl_exception") {
283   cflags_c = []
284   sources = [
285     "nacl_exception.c",
286   ]
287
288   if (cpu_arch == "pnacl") {
289     cflags_c += [
290       "-Wno-self-assign",
291       "-allow-asm",
292     ]
293   }
294 }
295 static_library("nacl_list_mappings") {
296   cflags_c = []
297   sources = [
298     "list_mappings.c",
299   ]
300
301   if (cpu_arch == "pnacl") {
302     cflags_c += [
303       "-Wno-self-assign",
304       "-allow-asm",
305     ]
306   }
307 }
308
309 if (os != "glibc") {
310   source_set("sys_private") {
311     cflags_c = []
312     sources = [
313       "sys_private.c",
314     ]
315
316     if (cpu_arch == "pnacl") {
317       cflags_c += [
318         "-Wno-self-assign",
319         "-allow-asm",
320       ]
321     }
322   }
323   source_set("gc_hooks_private") {
324     cflags_c = []
325     sources = [
326       "gc_hooks_private.c",
327     ]
328
329     if (cpu_arch == "pnacl") {
330       cflags_c += [
331         "-Wno-self-assign",
332         "-allow-asm",
333       ]
334     }
335   }
336   source_set("private_blockhook") {
337     cflags_c = []
338     sources = [
339       "../../untrusted/irt/irt_blockhook.c",
340     ]
341
342     if (cpu_arch == "pnacl") {
343       cflags_c += [
344         "-Wno-self-assign",
345         "-allow-asm",
346       ]
347     }
348   }
349 }