Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/littlefs-project/littlefs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristopher Haster <chaster@utexas.edu>2018-08-05 04:33:09 +0300
committerChristopher Haster <chaster@utexas.edu>2018-10-16 19:33:00 +0300
commit6d0a6fc4622d0a48ab790d2b430048c8b32c606c (patch)
tree41fe9e997a7e186253041de68e18ff5092b8b227 /Makefile
parent3186e89b14acdbd162911bc6af89ab94489a2a0a (diff)
parent510cd13df99843174899aa3ddabcbc889c7872e8 (diff)
Merge remote-tracking branch 'origin/master' into v2-alpha
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile11
1 files changed, 8 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index 21cc1c9..a8b8852 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,7 @@
-TARGET = lfs
+TARGET = lfs.a
+ifneq ($(wildcard test.c main.c),)
+override TARGET = lfs
+endif
CC ?= gcc
AR ?= ar
@@ -22,7 +25,7 @@ ifdef WORD
override CFLAGS += -m$(WORD)
endif
override CFLAGS += -I.
-override CFLAGS += -std=c99 -Wall -pedantic
+override CFLAGS += -std=c99 -Wall -pedantic -Wshadow -Wunused-parameter
all: $(TARGET)
@@ -36,7 +39,9 @@ size: $(OBJ)
test: test_format test_dirs test_files test_seek test_truncate \
test_entries test_interspersed test_alloc test_paths test_attrs \
test_move test_orphan test_corrupt
+ @rm test.c
test_%: tests/test_%.sh
+
ifdef QUIET
@./$< | sed -n '/^[-=]/p'
else
@@ -45,7 +50,7 @@ endif
-include $(DEP)
-$(TARGET): $(OBJ)
+lfs: $(OBJ)
$(CC) $(CFLAGS) $^ $(LFLAGS) -o $@
%.a: $(OBJ)