diff options
author | Alon Zakai <alonzakai@gmail.com> | 2011-10-03 10:14:45 +0200 |
---|---|---|
committer | Alon Zakai <alonzakai@gmail.com> | 2011-10-03 10:14:45 +0200 |
commit | c48fb0eeeeb5cff860ee8eace7b0e8cebb72c093 (patch) | |
tree | 7373cbb05bbd9bf0f38f292a854af64b4eea24b8 | |
parent | c2a8a5b364e6b888c6563af371603eb5ce86c1b5 (diff) |
fix test_stat
-rw-r--r-- | system/include/libc/sys/_types.h | 2 | ||||
-rw-r--r-- | system/include/libc/sys/stat.h | 2 | ||||
-rw-r--r-- | system/include/libc/sys/types.h | 4 | ||||
-rw-r--r-- | tests/runner.py | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/system/include/libc/sys/_types.h b/system/include/libc/sys/_types.h index 25252ed8..c9fcaaee 100644 --- a/system/include/libc/sys/_types.h +++ b/system/include/libc/sys/_types.h @@ -21,7 +21,7 @@ typedef long _off_t; typedef unsigned long long __dev_t; #else #ifndef __dev_t_defined -typedef short __dev_t; +typedef unsigned long long __dev_t; /* XXX Emscripten */ #endif #endif diff --git a/system/include/libc/sys/stat.h b/system/include/libc/sys/stat.h index f00caa66..fd955d66 100644 --- a/system/include/libc/sys/stat.h +++ b/system/include/libc/sys/stat.h @@ -150,7 +150,7 @@ int _EXFUN(mkfifo,( const char *__path, mode_t __mode )); int _EXFUN(stat,( const char *__path, struct stat *__sbuf )); mode_t _EXFUN(umask,( mode_t __mask )); -#if defined (__SPU__) || defined(__rtems__) || defined(__CYGWIN__) && !defined(__INSIDE_CYGWIN__) +#if defined(EMSCRIPTEN) || defined (__SPU__) || defined(__rtems__) || defined(__CYGWIN__) && !defined(__INSIDE_CYGWIN__) int _EXFUN(lstat,( const char *__path, struct stat *__buf )); int _EXFUN(mknod,( const char *__path, mode_t __mode, dev_t __dev )); #endif diff --git a/system/include/libc/sys/types.h b/system/include/libc/sys/types.h index 6a5c11a9..5cb126a7 100644 --- a/system/include/libc/sys/types.h +++ b/system/include/libc/sys/types.h @@ -130,7 +130,7 @@ typedef char * caddr_t; defined(__sparc__) || defined(__SPU__) typedef unsigned long ino_t; #else -typedef unsigned short ino_t; +typedef unsigned long ino_t; /* XXX Emscripten */ #endif #endif /*__CYGWIN__*/ @@ -197,7 +197,7 @@ typedef unsigned int mode_t _ST_INT32; #endif /* ! __MS_types__ */ #endif /*__CYGWIN__*/ -typedef unsigned short nlink_t; +typedef unsigned long nlink_t; /* XXX Emscripten */ /* We don't define fd_set and friends if we are compiling POSIX source, or if we have included (or may include as indicated diff --git a/tests/runner.py b/tests/runner.py index bea7fa6b..c2f6b58e 100644 --- a/tests/runner.py +++ b/tests/runner.py @@ -2500,7 +2500,7 @@ if 'benchmark' not in str(sys.argv): open(filename, 'w').write(src) src = open(path_from_root('tests', 'stat', 'src.c'), 'r').read() expected = open(path_from_root('tests', 'stat', 'output.txt'), 'r').read() - self.do_test(src, expected, post_build=add_pre_run) + self.do_test(src, expected, post_build=add_pre_run, extra_emscripten_args=['-H', 'libc/fcntl.h']) def test_fcntl(self): def add_pre_run(filename): |