From d8a7a5d5aeabdcb1e45ef4de3714d55b6b7e7cf7 Mon Sep 17 00:00:00 2001 From: mnik01 Date: Wed, 10 Sep 2025 05:11:33 +0500 Subject: initial --- Makefile | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 Makefile (limited to 'Makefile') diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..4bd922c --- /dev/null +++ b/Makefile @@ -0,0 +1,37 @@ +CC=gcc +CFLAGS=-Wall -Wextra -std=c99 -O2 +TARGET=jelly-cms +SOURCE=main.c + +# Default target +$(TARGET): $(SOURCE) + $(CC) $(CFLAGS) -o $(TARGET) $(SOURCE) + +# Clean build artifacts +clean: + rm -f $(TARGET) + rm -rf build + +# Install (copy to /usr/local/bin) +install: $(TARGET) + sudo cp $(TARGET) /usr/local/bin/ + +# Uninstall +uninstall: + sudo rm -f /usr/local/bin/$(TARGET) + +# Test build (run build command) +test: $(TARGET) + ./$(TARGET) build + +# Help +help: + @echo "Available targets:" + @echo " $(TARGET) - Build the jelly-cms executable" + @echo " clean - Remove build artifacts and executable" + @echo " install - Install jelly-cms to /usr/local/bin" + @echo " uninstall - Remove jelly-cms from /usr/local/bin" + @echo " test - Build and run jelly-cms build command" + @echo " help - Show this help message" + +.PHONY: clean install uninstall test help \ No newline at end of file -- cgit v1.2.3