aboutsummaryrefslogtreecommitdiff
path: root/emcc
diff options
context:
space:
mode:
authormanuels <manuel.schoelling@gmx.de>2013-03-05 21:58:55 +0100
committermanuels <manuel.schoelling@gmx.de>2013-03-05 22:05:11 +0100
commit6efef45cbfad95034f2ccd450bbca08235dc8936 (patch)
tree9cbc0a7debc1a06b4212c5577aa138b75dd058b8 /emcc
parent939740e739df9ac24b31b68f11ac477a17c73353 (diff)
Add support for getopt/getopt_long
Diffstat (limited to 'emcc')
-rwxr-xr-xemcc16
1 files changed, 15 insertions, 1 deletions
diff --git a/emcc b/emcc
index f644b924..e095ced4 100755
--- a/emcc
+++ b/emcc
@@ -1068,7 +1068,21 @@ try:
def create_libc():
if DEBUG: print >> sys.stderr, 'emcc: building libc for cache'
o_s = []
- for src in ['dlmalloc.c', os.path.join('libcxx', 'new.cpp')]:
+ libc_files = [
+ 'dlmalloc.c',
+ os.path.join('libcxx', 'new.cpp'),
+ os.path.join('libc', 'stdlib', 'getopt_long.c'),
+ os.path.join('libc', 'gen', 'err.c'),
+ os.path.join('libc', 'gen', 'errx.c'),
+ os.path.join('libc', 'gen', 'warn.c'),
+ os.path.join('libc', 'gen', 'warnx.c'),
+ os.path.join('libc', 'gen', 'verr.c'),
+ os.path.join('libc', 'gen', 'verrx.c'),
+ os.path.join('libc', 'gen', 'vwarn.c'),
+ os.path.join('libc', 'gen', 'vwarnx.c'),
+ ];
+
+ for src in libc_files:
o = in_temp(os.path.basename(src) + '.o')
execute([shared.PYTHON, shared.EMCC, shared.path_from_root('system', 'lib', src), '-o', o], stdout=stdout, stderr=stderr)
o_s.append(o)