-
Notifications
You must be signed in to change notification settings - Fork 11
Expand file tree
/
Copy pathMakefile
More file actions
37 lines (26 loc) · 761 Bytes
/
Copy pathMakefile
File metadata and controls
37 lines (26 loc) · 761 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
ERL = erl
QMAKE = qmake
QMAKE_SPEC = win32-g++
QTERL_LIB_EXT = dll
QTERL_LIB_TARGET = release
QTERL_LIB = qterl.$(QTERL_LIB_EXT)
all: lib ebin
werl: all
werl -pa ebin
.PHONY: check
check:
$(MAKE) -C test
.PHONY: lib
lib: priv/$(QTERL_LIB)
priv/$(QTERL_LIB): priv/build/c_src/qterl/$(QTERL_LIB_TARGET)/$(QTERL_LIB)
@echo Copy new $(QTERL_LIB) from build dir
@cp $< $@
priv/build/c_src/qterl/$(QTERL_LIB_TARGET)/$(QTERL_LIB): priv/build/Makefile $(wildcard c_src/qterl/* c_src/libqte/*)
@$(MAKE) -C $(dir $<) $(QTERL_LIB_TARGET)
priv/build/Makefile: QtErl.pro
@mkdir -p $(dir $@)
@cd $(dir $@) && $(QMAKE) -spec $(QMAKE_SPEC) -o Makefile ../../$<
.PHONY: ebin
ebin: $(wildcard src/*.erl) $(wildcard include/*.hrl)
@mkdir -p ebin
@$(ERL) -make