Initial commit
This commit is contained in:
20
Makefile
Normal file
20
Makefile
Normal file
@@ -0,0 +1,20 @@
|
||||
CC = gcc
|
||||
CFLAGS = -Wall
|
||||
BUILDDIR = .build/
|
||||
TARGET = $(BUILDDIR)program
|
||||
SRCS = src/
|
||||
OBJS=$(patsubst $(SRCS)%.c, $(BUILDDIR)%.o, $(wildcard $(SRCS)*.c))
|
||||
|
||||
all: checkbuild $(TARGET)
|
||||
|
||||
$(TARGET): $(OBJS)
|
||||
$(CC) $(CFLAGS) -o $(TARGET) $(OBJS)
|
||||
|
||||
$(BUILDDIR)%.o: $(SRCS)%.c
|
||||
$(CC) $(CFLAGS) -c $< -o $@
|
||||
|
||||
checkbuild:
|
||||
./checkbuild.sh
|
||||
|
||||
clean:
|
||||
rm -rf $(BUILDDIR)*
|
||||
Reference in New Issue
Block a user