-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathMakefile.in
41 lines (31 loc) · 936 Bytes
/
Makefile.in
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
38
39
40
41
PACKAGE_NAME = @PACKAGE_NAME@
PACKAGE_VERSION = @PACKAGE_VERSION@
RELDIR = releases/$(PACKAGE_NAME)-$(PACKAGE_VERSION)
EBIN_DIRS = ebin
ERL= @ERL@
ifeq ($(shell uname),Linux)
ARCH = linux
else
ARCH = macosx
endif
all: driver erl ebin/$(PACKAGE_NAME).app docs
.PHONY: driver erl docs clean distclean
driver:
(cd c_src;$(MAKE))
erl: ebin
@$(ERL) -pa $(EBIN_DIRS) -noinput +B \
-eval 'case make:all() of up_to_date -> halt(0); error -> halt(1) end.'
ebin/$(PACKAGE_NAME).app: ebin src/$(PACKAGE_NAME).app
@cp src/$(PACKAGE_NAME).app $@
clean:
(cd c_src;$(MAKE) clean)
@echo "removing:"
@rm -fv ebin/*.beam ebin/*.app
distclean: clean
rm -rf autom4te.cache config.log config.status
rm -f Makefile c/Makefile erl/Makefile
rm -f c/*flymake*
install: all
(cd c; $(MAKE) install)
docs: $(wildcard src/*.erl)
@$(ERL) -noshell -run edoc_run application '$(PACKAGE_NAME)' '"."' "[{def, [{vsn, \"$(PACKAGE_VERSION)\"}]}]"