]> git.donarmstrong.com Git - bamtools.git/blob - Makefile
change printf's to fprint(stderr,
[bamtools.git] / Makefile
1 # ==========================
2 # BamTools Makefile
3 # (c) 2010 Derek Barnett
4 #
5 # top-level
6 # ==========================
7
8 # define main directories
9 export OBJ_DIR  = obj
10 export BIN_DIR  = bin
11 export SRC_DIR  = src
12
13 # define compile/link flags
14 export CXX      = g++\r
15 export CXXFLAGS = -Wall -O3 -D_FILE_OFFSET_BITS=64
16 export LIBS     = -lz
17
18 # define current BamTools version
19 export BAMTOOLS_VERSION = 0.7.0812
20
21 # define source subdirectories
22 SUBDIRS = $(SRC_DIR)/api \
23           $(SRC_DIR)/utils \
24           $(SRC_DIR)/toolkit
25
26 all:
27         @echo "Building BamTools:"
28         @echo "Version: $$BAMTOOLS_VERSION"
29         @echo "========================================================="
30         
31         mkdir -p $(BIN_DIR)
32         mkdir -p $(OBJ_DIR)
33
34         @for dir in $(SUBDIRS); do \
35                 echo "- Building in $$dir"; \
36                 $(MAKE) --no-print-directory -C $$dir; \
37                 echo ""; \
38         done
39
40 .PHONY: all
41
42 clean:
43         @echo "Cleaning up."
44         @rm -f $(OBJ_DIR)/* $(BIN_DIR)/*
45
46 .PHONY: clean