2008-07-24 Badlop <badlop@process-one.net>
+ * src/Makefile.in: Support for parallel compilation with 'make -j'
+ in multi core CPUs: fix compilation dependencies; compile
+ behaviors before other source code (EJAB-697)(thanks to Jonathan
+ Schleifer)
+ * src/mod_pubsub/Makefile.in: Likewise
+ * src/eldap/Makefile.in: Likewise
+
* doc/guide.tex: Document room options allow_visitor_nickchange
and allow_visitor_status (EJAB-624)
* doc/guide.html: Likewise
SUBDIRS = @mod_irc@ @mod_pubsub@ @mod_muc@ @mod_proxy65@ @eldap@ @pam@ @web@ stringprep @tls@ @odbc@ @ejabberd_zlib@
ERLSHLIBS = expat_erl.so
ERLBEHAVS = cyrsasl.erl gen_mod.erl p1_fsm.erl
-SOURCES = $(ERLBEHAVS) $(wildcard *.erl)
+SOURCES_ALL = $(wildcard *.erl)
+SOURCES = $(filter-out $(ERLBEHAVS),$(SOURCES_ALL))
+ERLBEHAVBEAMS = $(ERLBEHAVS:.erl=.beam)
BEAMS = $(SOURCES:.erl=.beam)
DESTDIR =
all: $(ERLSHLIBS) compile-beam all-recursive
-compile-beam: XmppAddr.hrl $(BEAMS)
+compile-beam: XmppAddr.hrl $(ERLBEHAVBEAMS) $(BEAMS)
+
+$(BEAMS): $(ERLBEHAVBEAMS)
+
+all-recursive: $(ERLBEHAVBEAMS)
%.beam: %.erl
@ERLC@ -W $(ERLC_FLAGS) $<
all: $(BEAMS) ELDAPv3.beam
+ELDAPv3.beam: ELDAPv3.erl
+
ELDAPv3.erl: ELDAPv3.asn
@ERLC@ -bber_bin -W $(EFLAGS) $<
endif
OUTDIR = ..
-SOURCES = $(wildcard *.erl)
+ERLBEHAVS = gen_pubsub_node.erl gen_pubsub_nodetree.erl
+SOURCES_ALL = $(wildcard *.erl)
+SOURCES = $(filter-out $(ERLBEHAVS),$(SOURCES_ALL))
+ERLBEHAVBEAMS = $(addprefix $(OUTDIR)/,$(ERLBEHAVS:.erl=.beam))
BEAMS = $(addprefix $(OUTDIR)/,$(SOURCES:.erl=.beam))
-all: $(BEAMS)
+all: $(ERLBEHAVBEAMS) $(BEAMS)
+
+$(BEAMS): $(ERLBEHAVBEAMS)
$(OUTDIR)/%.beam: %.erl
@ERLC@ -W $(EFLAGS) -o $(OUTDIR) $<