Add Hello World

This commit is contained in:
Ziyao 2022-04-03 10:37:29 +08:00
parent a946300e6c
commit e6138735bd
2 changed files with 23 additions and 0 deletions

8
tests/Compile.sh Executable file
View File

@ -0,0 +1,8 @@
#!/bin/sh
# Compiling one C source with tcc and musl
# tcc-musl tests
# file: /tests/Compile.sh
# Date: 2022.04.03
tcc $1 -nostdlib ../lib/Scrt1.o ../lib/libc.a -o $2 -Wall -Werror -g -O0 -pedantic -Wextra -I ../include -I ../obj/include -I ../arch/x86_64/

15
tests/Hello_World.c Normal file
View File

@ -0,0 +1,15 @@
/*
musl-tcc tests
src:/tests/Hello_World.c
Date:2022.04.03
By MIT License.
Copyright(c) 2022 Ziyao.All rights reserved.
*/
#include<unistd.h>
int main(void)
{
write(0,"Hello World\n",12);
return 0;
}