-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmakefile
More file actions
58 lines (48 loc) · 1.28 KB
/
makefile
File metadata and controls
58 lines (48 loc) · 1.28 KB
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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
CXX := g++
CXXFLAGS := -Wall -Wextra -std=c++17 -Iinclude
SRCDIR := src
OBJDIR := obj
BINDIR := bin
SOURCES := $(shell find $(SRCDIR) -name '*.cpp')
OBJECTS := $(patsubst $(SRCDIR)/%.cpp, $(OBJDIR)/%.o, $(SOURCES))
TARGET := $(BINDIR)/app
DEBUG_TARGET := $(BINDIR)/app_debug
all: $(TARGET)
$(TARGET): $(OBJECTS)
@mkdir -p $(BINDIR)
$(CXX) $(OBJECTS) -o $(TARGET)
$(OBJDIR)/%.o: $(SRCDIR)/%.cpp
@mkdir -p $(dir $@)
$(CXX) $(CXXFLAGS) -c $< -o $@
clean:
rm -rf $(OBJDIR)/* $(BINDIR)/*
run-sample: $(TARGET)
@if [ -f $(TARGET) ]; then \
./$(TARGET) \
input/alignment-params.config \
input/base-sample.fasta \
; \
else \
echo "Error: Executable $(TARGET) not found. Please build it first."; \
exit 1; \
fi
run-brca2: $(TARGET)
@if [ -f $(TARGET) ]; then \
./$(TARGET) \
input/alignment-params.config \
input/Human-Mouse-BRCA2-cds.fasta \
; \
else \
echo "Error: Executable $(TARGET) not found. Please build it first."; \
exit 1; \
fi
run-blind: $(TARGET)
@if [ -f $(TARGET) ]; then \
./$(TARGET) \
input/alignment-params.config \
input/Opsin1_colorblindness_gene.fasta \
; \
else \
echo "Error: Executable $(TARGET) not found. Please build it first."; \
exit 1; \
fi