mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-06 09:13:55 -06:00
tests/tcg: split cris tests into bare and libc directories
Bare tests are standalone assembly tests that don't require linking to any libc and hence can be built with kernel only compilers. The libc tests need a compiler capable of building properly linked userspace binaries. As we don't have such a cross compiler at the moment we won't be building those tests. Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
This commit is contained in:
parent
6b970dd62c
commit
d4f6e58fcb
102 changed files with 0 additions and 0 deletions
27
tests/tcg/cris/libc/check_stat4.c
Normal file
27
tests/tcg/cris/libc/check_stat4.c
Normal file
|
@ -0,0 +1,27 @@
|
|||
/* Simulator options:
|
||||
#notarget: cris*-*-elf
|
||||
#sim: --sysroot=@exedir@
|
||||
*/
|
||||
|
||||
#include <sys/types.h>
|
||||
#include <sys/stat.h>
|
||||
#include <unistd.h>
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <stdlib.h>
|
||||
|
||||
int main (int argc, char *argv[])
|
||||
{
|
||||
char path[1024] = "/";
|
||||
struct stat buf;
|
||||
|
||||
strncat(path, argv[0], sizeof(path) - 2);
|
||||
if (lstat (".", &buf) != 0
|
||||
|| !S_ISDIR (buf.st_mode))
|
||||
abort ();
|
||||
if (lstat (path, &buf) != 0
|
||||
|| !S_ISREG (buf.st_mode))
|
||||
abort ();
|
||||
printf ("pass\n");
|
||||
exit (0);
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue