diff --git a/sk1/Makefile b/sk1/Makefile index 2885ed8..65cf1d2 100644 --- a/sk1/Makefile +++ b/sk1/Makefile @@ -1,12 +1,9 @@ + + CC = gcc CFLAGS = -Wall -Wextra -std=c99 - TARGET = compressor - SRCS = main.c compressor.c -HEADERS = compressor.h - - OBJS = $(SRCS:.c=.o) @@ -14,20 +11,13 @@ all: $(TARGET) $(TARGET): $(OBJS) - $(CC) $(CFLAGS) -o $(TARGET) $(OBJS) + $(CC) $(CFLAGS) -o $@ $^ -%.o: %.c $(HEADERS) +%.o: %.c $(CC) $(CFLAGS) -c $< -o $@ clean: rm -f $(OBJS) $(TARGET) -help: - @echo "Usage: make [target]" - @echo "Targets:" - @echo " all - Build the project" - @echo " clean - Remove all built files" - @echo " help - Show this help message" -