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

Makefile.in « pam « src - github.com/processone/ejabberd.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: bde289402b9342769f795cb765a1e8114a0b8d32 (plain)
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
42
43
44
45
46
47
# $Id: Makefile.in 775 2007-05-29 14:31:12Z mremond $

CC = @CC@
CFLAGS = @CFLAGS@ @PAM_CFLAGS@
CPPFLAGS = @CPPFLAGS@
LDFLAGS = @LDFLAGS@
LIBS = @LIBS@ @PAM_LIBS@

ERLANG_CFLAGS = @ERLANG_CFLAGS@
ERLANG_LIBS = @ERLANG_LIBS@

EFLAGS += -I ..
EFLAGS += -pz ..

# make debug=true to compile Erlang module with debug informations.
ifdef debug
	EFLAGS+=+debug_info
endif

ERLSHLIBS = ../epam
OUTDIR = ..
SOURCES = $(wildcard *.erl)
BEAMS = $(addprefix $(OUTDIR)/,$(SOURCES:.erl=.beam))


all:    $(BEAMS) $(ERLSHLIBS)

$(OUTDIR)/%.beam:       %.erl
	@ERLC@ -W $(EFLAGS) -o $(OUTDIR) $<

#all:	$(ERLSHLIBS)
#	erl -s make all report "{outdir, \"..\"}" -noinput -s erlang halt

$(ERLSHLIBS):	../%:	%.c
			$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) \
			$(subst ../,,$(subst ,.c,$@)) $(LIBS) \
			$(ERLANG_LIBS) $(ERLANG_CFLAGS) \
			-o $@ -lpthread

clean:
	rm -f $(BEAMS) $(ERLSHLIBS)

distclean: clean
	rm -f Makefile

TAGS:
	etags *.erl