forked from ANNIEsoft/ToolAnalysis
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile.FNAL
83 lines (51 loc) · 3.6 KB
/
Makefile.FNAL
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
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
ToolDAQPath=ToolDAQ
CC=g++ -std=c++1y -g -fPIC -shared $(CPPFLAGS)
CPPFLAGS= -Wno-reorder -Wno-sign-compare -Wno-unused-variable -Wno-unused-but-set-variable -fdiagnostics-color=always
PythonLib= `python-config --libs` -L `python-config --prefix`/lib
PythonInclude=`python-config --cflags`
ZMQLib= -L ToolDAQ/zeromq-4.0.7/lib -lzmq
ZMQInclude= -I ToolDAQ/zeromq-4.0.7/include/
BoostLib= -L $(BOOST_LIB) -lboost_date_time -lboost_serialization -lboost_iostreams
BoostInclude= -I $(BOOST_INC)
RootInclude= -I $(ROOT_INC)
RootLib= -L $(ROOT_INC)/../lib `root-config --libs` -lMinuit -lGeom -lEve #-lGL -lGLU -lGLEW
DataModelInclude = $(RootInclude)
DataModelLib = $(RootLib)
WCSimLib= -L ToolDAQ/WCSimLib -lWCSimRoot
WCSimInclude= -I ToolDAQ/WCSimLib/include
MrdTrackLib= -L ToolDAQ/MrdTrackLib/src -lFindMrdTracks
MrdTrackInclude= -I ToolDAQ/MrdTrackLib/include
MyToolsInclude = -lcurl $(RootInclude) $(PythonInclude) $(MrdTrackInclude) $(WCSimInclude)
MyToolsLib = $(RootLib) $(PythonLib) $(MrdTrackLib) $(WCSimLib)
all: lib/libStore.so lib/libLogging.so lib/libDataModel.so include/Tool.h lib/libMyTools.so lib/libServiceDiscovery.so lib/libToolChain.so Analyse
Analyse: src/main.cpp
g++ $(CPPFLAGS) -std=c++1y -g src/main.cpp -o Analyse -I include -L lib -lStore -lMyTools -lToolChain -lDataModel -lLogging -lServiceDiscovery -lpthread $(DataModelInclude) $(MyToolsInclude) $(MyToolsLib) $(ZMQLib) $(ZMQInclude) $(BoostLib) $(BoostInclude)
lib/libStore.so: $(ToolDAQPath)/ToolDAQFramework/src/Store/*
cp $(ToolDAQPath)/ToolDAQFramework/src/Store/*.h include/
$(CC) -I include $(ToolDAQPath)/ToolDAQFramework/src/Store/*.cpp -o lib/libStore.so $(BoostLib) $(BoostInclude)
include/Tool.h: $(ToolDAQPath)/ToolDAQFramework/src/Tool/Tool.h
cp $(ToolDAQPath)/ToolDAQFramework/src/Tool/Tool.h include/
lib/libToolChain.so: $(ToolDAQPath)/ToolDAQFramework/src/ToolChain/*
cp $(ToolDAQPath)/ToolDAQFramework/src/ToolChain/*.h include/
$(CC) $(ToolDAQPath)/ToolDAQFramework/src/ToolChain/ToolChain.cpp -I include -lpthread -L lib -lStore -lDataModel -lMyTools -lServiceDiscovery -lLogging -o lib/libToolChain.so $(DataModelInclude) $(ZMQLib) $(ZMQInclude) $(MyToolsInclude) $(BoostLib) $(BoostInclude)
clean:
rm -f include/*.h include/*.hh
rm -f lib/*.so
rm -f Analyse
lib/libDataModel.so: DataModel/*
cp -L DataModel/*.h include/
$(CC) DataModel/*.C DataModel/*.cpp -I include -L lib -lStore -lLogging -o lib/libDataModel.so $(DataModelInclude) $(DataModelLib) $(ZMQLib) $(ZMQInclude) $(BoostLib) $(BoostInclude) $(UserLib)
lib/libMyTools.so: UserTools/* UserTools/*/* include/Tool.h lib/libDataModel.so
cp UserTools/*/*.h include/
cp UserTools/Factory/*.h include/
$(CC) UserTools/Factory/Factory.cpp -I include -L lib -lStore -lDataModel -lLogging -o lib/libMyTools.so $(MyToolsInclude) $(MyToolsLib) $(DataModelInclude) $(ZMQLib) $(ZMQInclude) $(BoostLib) $(BoostInclude) $(UserLib)
lib/libServiceDiscovery.so: $(ToolDAQPath)/ToolDAQFramework/src/ServiceDiscovery/*
cp $(ToolDAQPath)/ToolDAQFramework/src/ServiceDiscovery/ServiceDiscovery.h include/
$(CC) -I include $(ToolDAQPath)/ToolDAQFramework/src/ServiceDiscovery/ServiceDiscovery.cpp -o lib/libServiceDiscovery.so -L lib/ -lStore $(ZMQInclude) $(ZMQLib) $(BoostLib) $(BoostInclude)
lib/libLogging.so: $(ToolDAQPath)/ToolDAQFramework/src/Logging/*
cp $(ToolDAQPath)/ToolDAQFramework/src/Logging/Logging.h include/
$(CC) -I include $(ToolDAQPath)/ToolDAQFramework/src/Logging/Logging.cpp -o lib/libLogging.so -L lib/ -lStore $(ZMQInclude) $(ZMQLib) $(BoostLib) $(BoostInclude)
update:
cd $(ToolDAQPath)/ToolDAQFramework; git pull
cd ToolDAQ/zeromq-4.0.7; git pull
git pull