-
Notifications
You must be signed in to change notification settings - Fork 1
/
Makefile
55 lines (36 loc) · 1.68 KB
/
Makefile
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
#
# Rechnernutzung in der Physik, WS 2011/12, Blatt 04, Aufg. 9
#
# Zur Verfuegung gestelltes Makefile
#
#----------------------------------------------------------------------------
#
# Variablendefinitionen:
#
# Compile settings
CXX := g++
CXXFLAGS := -O3 -std=c++11 -fPIC
SHCXXFLAGS := -fPIC -shared -std=c++11 -DBOOST_IT
SHLDLIBS := -lpython2.7 -lboost_python
# Link settings
LD := g++ # Use g++ for linking
LDFLAGS := -O
LDLIBS := -lpthread -lm -ldl -lpython2.7 -lboost_python
#-lGui -lCore -lRIO -lNet -lHist -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lMathCore -lThread
#LIB := -L/$(ROOTSYS)/lib/
#INC :=-I/$(ROOTSYS)/include/ -I/usr/include/python2.6
INC := -I/usr/include/python2.7
sources := src/measurement.cc src/electron.cc src/Bcalc.c
objects := $(sources:.cc=.o) # Objektdateien sind die
shsources := src/electron.cc src/Bcalc.c
shobjects := $(shsources:.cc=.o) # Objektdateien sind die
#----------------------------------------------------------------------------
findMomentum: $(objects)
$(LD) $(LDFLAGS) -o findMomentum $(objects) src/findMomentum.cc $(CXXFLAGS) $(LIB) $(INC) $(LDLIBS) && rm src/*.o
getDeflection: $(objects)
$(LD) $(LDFLAGS) -o getDeflection $(objects) src/getDeflection.cc $(CXXFLAGS) $(LIB) $(INC) $(LDLIBS) && rm src/*.o
cc: $(objects)
$(LD) $(LDFLAGS) -o findMomentum $(objects) src/findMomentum.cc $(CXXFLAGS) $(LIB) $(INC) $(LDLIBS)
$(LD) $(LDFLAGS) -o getDeflection $(objects) src/getDeflection.cc $(CXXFLAGS) $(LIB) $(INC) $(LDLIBS) && rm src/*.o
shared: $(shobjects)
$(LD) $(LDFLAGS) -o measurement.so $(shobjects) src/measurement.cc $(SHCXXFLAGS) $(LIB) $(INC) $(SHLDLIBS) && rm src/*.o