Skip to content
Snippets Groups Projects
Commit 426416ea authored by Byron Lathi's avatar Byron Lathi
Browse files

add program to test executing

parent 17ff503a
No related branches found
No related tags found
No related merge requests found
CFLAGS += -Wall -nostdlib -ffreestanding -m32
CFLAGS += -Wall -nostdlib -ffreestanding -m32 -g
LDFLAGS += -nostdlib -ffreestanding -m32
CC=i686-elf-gcc
SRC = hello
SRC = hello exectest
.SUFFIXES:
......@@ -19,4 +19,4 @@ ALL: $(SRC)
mv $@ ../bin
clean:
rm -f ../bin/$(SRC)
rm -f ../bin/*
#include "syscall.h"
int main()
{
sys_exec((uint8_t*)"/Programs/bin/hello");
sys_write(1, "Done executing!\n", sizeof("Done executin!\n"));
return 0;
}
\ No newline at end of file
......@@ -3,6 +3,6 @@
int main()
{
sys_write(1, "Hello, World!\n", 14);
sys_write(1, "Hello, World!\n", sizeof("Hello, World!\n"));
return 0;
}
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment