Add lib directory check in Makefile

This commit is contained in:
Grégory Soutadé 2010-12-11 09:51:44 +01:00
parent 9355c42093
commit 05a5f9a167
2 changed files with 5 additions and 1 deletions

View File

@ -14,6 +14,7 @@ php5
** Compilation of extra libraries ** ** Compilation of extra libraries **
lib is not included by default and must be downloaded http://indefero.soutade.fr/p/kisscount/downloads/ lib is not included by default and must be downloaded http://indefero.soutade.fr/p/kisscount/downloads/
It must be decompressed beside "src" directory.
cd lib/wxsqlite3-1.9.9 cd lib/wxsqlite3-1.9.9
./configure ./configure

View File

@ -20,7 +20,7 @@ HEADERS+=$(wildcard src/controller/*.h)
HEADERS+=src/main.h src/sha1.h HEADERS+=src/main.h src/sha1.h
OBJS=$(SOURCES:.cpp=.o) OBJS=$(SOURCES:.cpp=.o)
all: kc all: check kc
clean: clean:
rm -f *~ src/*~ src/*.o src/model/*.o src/model/*~ src/view/*.o src/view/grid/*.o src/view/grid/*~ src/view/*~ src/controller/*.o src/controller/*~ kc rm -f *~ src/*~ src/*.o src/model/*.o src/model/*~ src/view/*.o src/view/grid/*.o src/view/grid/*~ src/view/*~ src/controller/*.o src/controller/*~ kc
@ -28,6 +28,9 @@ clean:
%.o : src/model/%.cpp src/view/%.cpp src/view/grid/%.cpp src/controller/%.cpp src/%.cpp %.o : src/model/%.cpp src/view/%.cpp src/view/grid/%.cpp src/controller/%.cpp src/%.cpp
$(CXX) $(CXXFLAGS) $< -c $(CXX) $(CXXFLAGS) $< -c
check:
if ! test -d lib ; then echo lib directory not found, please see INSTALL ; return 1 ; fi
kc: $(OBJS) kc: $(OBJS)
$(CXX) $(CXXFLAGS) $^ -o $@ $(LDFLAGS) $(CXX) $(CXXFLAGS) $^ -o $@ $(LDFLAGS)