mirror of
https://github.com/mtheall/ftpd.git
synced 2024-11-30 05:00:32 +00:00
24 lines
447 B
Makefile
24 lines
447 B
Makefile
TARGET := $(notdir $(CURDIR))
|
|
|
|
CFILES := $(wildcard source/*.c)
|
|
OFILES := $(patsubst source/%,build.linux/%,$(CFILES:.c=.o))
|
|
|
|
CFLAGS := -g -Wall -Iinclude -DSTATUS_STRING="\"ftpd v1.0\""
|
|
LDFLAGS :=
|
|
|
|
.PHONY: all clean
|
|
|
|
all: build.linux $(TARGET)
|
|
|
|
build.linux:
|
|
@mkdir build.linux/
|
|
|
|
$(TARGET): $(OFILES)
|
|
@$(CC) -o $@ $^ $(LDFLAGS)
|
|
|
|
$(OFILES): build.linux/%.o : source/%.c
|
|
@$(CC) -o $@ -c $< $(CFLAGS)
|
|
|
|
clean:
|
|
@$(RM) -r build.linux/ $(TARGET)
|