1
0
Fork 0
mirror of https://github.com/gwm17/Mask.git synced 2024-11-13 05:58:50 -05:00
Mask/makefile

44 lines
886 B
Makefile
Raw Normal View History

2020-11-16 13:38:39 -05:00
CC=g++
ROOTGEN=rootcint
CFLAGS=-std=c++11 -g -Wall `root-config --cflags`
CPPFLAGS=-I ./include
LDFLAGS=`root-config --glibs`
ROOTINCLDIR=./
INCLDIR=./include
SRCDIR=./src
OBJDIR=./objs
BINDIR=./bin
SRC=$(wildcard $(SRCDIR)/*.cpp)
OBJS=$(SRC:$(SRCDIR)/%.cpp=$(OBJDIR)/%.o)
DICTOBJ=$(OBJDIR)/kinematics_dict.o
DICTSRC=$(SRCDIR)/kinematics_dict.cxx
DICT_PAGES=$(INCLDIR)/Kinematics.h $(INCLDIR)/LinkDef_Kinematics.h
2021-03-16 09:46:29 -04:00
EXE=$(BINDIR)/mask
2020-11-16 13:38:39 -05:00
CLEANUP=$(EXE) $(OBJS) $(DICTOBJ) $(DICTSRC)
2020-11-16 13:38:39 -05:00
.PHONY: all clean
all: $(EXE) $(TPEXE)
$(EXE): $(DICTOBJ) $(OBJS)
$(CC) $(CFLAGS) $^ -o $@ $(LDFLAGS)
$(DICTOBJ): $(DICTSRC)
$(CC) $(CFLAGS) $(CPPFLAGS) -I $(ROOTINCLDIR) -c $^ -o $@
mv $(SRCDIR)/*.pcm $(BINDIR)
$(DICTSRC): $(DICT_PAGES)
$(ROOTGEN) -f $@ $^
VPATH= $(SRCDIR):./testplots/
$(OBJDIR)/%.o: %.cpp
$(CC) $(CFLAGS) $(CPPFLAGS) -c $^ -o $@
clean:
$(RM) $(CLEANUP) $(BINDIR)/%.pcm