Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 36 lines (25 sloc) 1.179 kb
67fee7f @bbc-frameworks initial implementation
authored
1
2 LIBEV_VERSION=3.9
3 LIBEV_PATH=build/libev-$(LIBEV_VERSION)
85c49c7 @bbc-frameworks pull together for initial push
authored
4 INCPATH=-Iinclude -I$(LIBEV_PATH) -Iext/http-parser -I/opt/local/include
5 LIBPATH=-L$(LIBEV_PATH) -Lext/http-parser
67fee7f @bbc-frameworks initial implementation
authored
6 CC_NO_WARN=gcc -pthread ${INCPATH} ${LIBPATH}
7 CC=gcc -Wall -pedantic -pthread ${INCPATH} ${LIBPATH}
85c49c7 @bbc-frameworks pull together for initial push
authored
8 OBJECT_FILES=build/monaco.o build/monaco_ev.o build/http_parser.o
67fee7f @bbc-frameworks initial implementation
authored
9
10 monaco: ${OBJECT_FILES}
11 ${CC} -lm ${LIBRARIES} ${OBJECT_FILES} -o $@
12
85c49c7 @bbc-frameworks pull together for initial push
authored
13 ext/libev-$(LIBEV_VERSION).tar.gz:
14 cd ext && curl http://dist.schmorp.de/libev/libev-$(LIBEV_VERSION).tar.gz > libev-$(LIBEV_VERSION).tar.gz
15
67fee7f @bbc-frameworks initial implementation
authored
16 build:
17 mkdir build
18
85c49c7 @bbc-frameworks pull together for initial push
authored
19 build/http_parser.o: ext/http-parser/http_parser.c ext/http-parser/http_parser.h
20 ${CC_NO_WARN} -c ext/http-parser/http_parser.c -o build/http_parser.o
21
67fee7f @bbc-frameworks initial implementation
authored
22 build/monaco.o: build src/monaco.c $(LIBEV_PATH)/ev.h
23 ${CC} -c src/monaco.c -o build/monaco.o
24
25 build/monaco_ev.o: src/monaco_ev.c $(LIBEV_PATH)/ev.h $(LIBEV_PATH)/ev.c
26 ${CC_NO_WARN} -c src/monaco_ev.c -o build/monaco_ev.o
27
28 $(LIBEV_PATH)/ev.h: $(LIBEV_PATH)
29 $(LIBEV_PATH)/ev.c: $(LIBEV_PATH)
30
31 $(LIBEV_PATH): ext/libev-$(LIBEV_VERSION).tar.gz
32 cd build && tar xozf ../ext/libev-$(LIBEV_VERSION).tar.gz
33
34 clean:
85c49c7 @bbc-frameworks pull together for initial push
authored
35 rm -rf build monaco ext/libev-*.tar.gz
Something went wrong with that request. Please try again.