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

Makefile « vowpalwabbit - github.com/moses-smt/vowpal_wabbit.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 24b365dd545902813caad44d386d5ded57c86882 (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
COMPILER = g++
BINARIES = vw active_interactor
MANPAGES = vw.1

all:	config.h depend $(BINARIES)

%.1:	%
	help2man --no-info --name="Vowpal Wabbit -- fast online learning tool" ./$< > $@

config.h: ../configure.ac
	echo \#define PACKAGE_VERSION \"`grep AC_INIT ../configure.ac | cut -d '[' -f 3 | cut -d ']' -f 1`\" > config.h

vw_SOURCES = $(shell grep libvw_la_SOURCES Makefile.am | cut -d '=' -f 2)

depend:	$(vw_SOURCES) config.h
	gcc -MM $(vw_SOURCES) > depend

-include depend

%.o:	 %.cc  %.h
	$(COMPILER) $(FLAGS) -c $< -o $@

%.o:	 %.cc
	$(COMPILER) $(FLAGS) -c $< -o $@

liballreduce.a:	allreduce.o
	ar rcs $@ $<

vw_OBJECTS = $(patsubst %.cc,%.o,$(vw_SOURCES))

libvw.a: $(filter-out vw.o,$(vw_OBJECTS))
	ar rcs $@ $+

vw: vw.o libvw.a liballreduce.a
	$(COMPILER) $(FLAGS) -L$(BOOST_LIBRARY) -L. -o $@ $< -l vw -l allreduce $(LIBS)

active_interactor: active_interactor.cc
	$(COMPILER) $(FLAGS) -o $@ $+

install: $(BINARIES)
	cp $(BINARIES) /usr/local/bin; cd cluster; $(MAKE) install

clean:
	rm -f  *.o $(BINARIES) *~ $(MANPAGES)