Makefile 424 Bytes
Newer Older
Sergey Lyubka's avatar
Sergey Lyubka committed
1 2 3
# Copyright (c) 2014 Cesanta Software
# All rights reserved

4 5
SUBDIRS = $(sort $(filter-out csharp/, $(dir $(wildcard */))))
X = $(SUBDIRS)
6 7 8 9 10
ifdef WINDIR
    # appending the Winsock2 library at the end of the compiler
	# invocation
    CFLAGS_EXTRA += -lws2_32
endif
11

12
.PHONY: $(SUBDIRS)
13

14
all: $(SUBDIRS)
15

16
$(SUBDIRS):
17
	@$(MAKE) CFLAGS_EXTRA="$(CFLAGS_EXTRA)" -C $@
18

Sergey Lyubka's avatar
Sergey Lyubka committed
19
clean:
20
	for d in $(SUBDIRS) ; do $(MAKE) -C $$d clean ; done