'update'
[cgds.git] / Makefile
1 #http://stackoverflow.com/questions/6273608/how-to-pass-argument-to-makefile-from-command-line
2 #to reconstruct dependency rules or not
3
4 LIBRARY = libcgds.so
5 INSTALL_PREFIX = /usr/local
6
7 src:
8 cd src && $(MAKE) && cd ..
9
10 test:
11 cd test && $(MAKE) && cd ..
12
13 doc:
14 cd doc && $(MAKE) && cd ..
15
16 clean:
17 cd src && $(MAKE) clean && cd ..
18 cd test && $(MAKE) clean && cd ..
19 cd doc && $(MAKE) clean && cd ..
20
21 install:
22 # if [ ! -e src/obj/libcds.so ]; then make src; fi
23 cp src/obj/$(LIBRARY) $(INSTALL_PREFIX)/lib/
24 mkdir -p $(INSTALL_PREFIX)/include/cgds
25 cp src/*.h $(INSTALL_PREFIX)/include/cgds/
26
27 uninstall:
28 rm -f ${INSTALL_PREFIX}/lib/${LIBRARY}
29 [[ -d ${INSTALL_PREFIX}/include/cgds ]] && rm -rf ${INSTALL_PREFIX}/include/cgds
30
31 .PHONY: src test doc clean install uninstall