From 2de2426a8835a63d1a4259de1286e7daebf0f68b Mon Sep 17 00:00:00 2001 From: Joe George Date: Mon, 12 Feb 2024 12:03:24 -0500 Subject: [PATCH] Add hello --- .gitignore | 2 ++ Makefile | 12 ++++++++++++ hello.c | 7 +++++++ 3 files changed, 21 insertions(+) create mode 100644 .gitignore create mode 100644 Makefile create mode 100644 hello.c diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..2db3799 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +hello +*.o diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..579a2f8 --- /dev/null +++ b/Makefile @@ -0,0 +1,12 @@ + +TARGET = hello + +SRCS = hello.c + +OBJS = $(SRCS:.c=.o) + +.PHONY: all +all: $(TARGET) + +$(TARGET): $(OBJS) + $(CC) $(CFLAGS) -o $@ $^ $(LDFLAGS) diff --git a/hello.c b/hello.c new file mode 100644 index 0000000..7d38eaf --- /dev/null +++ b/hello.c @@ -0,0 +1,7 @@ +#include + +int main() +{ + printf("Hello, World!\n"); + return 0; +}