Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-05-15 07:41:25

0001 #===============================================================================
0002 #   File: Makefile
0003 #
0004 #   Example Makefile for Pythia8 written for HF in STAR
0005 #   Author: Thomas Ullrich
0006 #   Last modified: September 9, 2008
0007 #
0008 #   This needs 3 packages installed: Pythia8, LHAPDF, and ROOT
0009 #
0010 #   This is setup for Mac OS X 10.5.4 but should be easy to 
0011 #   adapt for other (Unix) platforms. In principle changing the
0012 #   program name (PROGRAM), the location of PYTHIA (PYTHIAPATH),
0013 #   and the LHAPDF libraries (LHAPDFPATH) should do the job.
0014 #   Note that the environment variable ROOTSYS needs to be set.
0015 #   Otherwise define it here in the makefile.
0016 #===============================================================================
0017 
0018 PROGRAM  =  pythiaDiMuon
0019 PYTHIAPATH   = /opt/local
0020 LHAPDFPATH = $(shell lhapdf-config --prefix)
0021 ROOTSYS = $(shell root-config --prefix)
0022 
0023 FASTJETCXX = `fastjet-config --cxxflags`
0024 FASTJETLIB = `fastjet-config --libs --plugins`
0025 
0026 DICTHEADERS = PythiaEvent.h LinkDef.h
0027 
0028 ROOTLIB = `root-config --libdir`
0029 
0030 CXX      =  g++
0031 CXXFLAGS = -O -W -Wall -m64 -std=c++20 $(FASTJETCXX)
0032 CPPFLAGS = -I$(PYTHIAPATH)/include -I$(ROOTSYS)/include/root -I$(LHAPDFPATH)/include 
0033 
0034 LDFLAGS  = -L$(PYTHIAPATH)/lib -L$(ROOTLIB) -L$(LHAPDFPATH)/lib -lpythia8 -lHepMC3 -lstdc++ -lCore -lThread -lRIO -lNet -lHist -lMathCore -lGraf -lGraf3d -lGpad -lTree -lRint -lPostscript -lMatrix -lPhysics -lfreetype -lpthread -lm -ldl
0035 
0036 $(PROGRAM):     $(PROGRAM).cpp DictOutput.cxx libPythiaEvent.so
0037                 $(CXX) $(CXXFLAGS) $(CPPFLAGS) $(PROGRAM).cpp DictOutput.cxx $(LDFLAGS) $(FASTJETLIB) libPythiaEvent.so -o $(PROGRAM)
0038                 
0039 DictOutput.cxx : PythiaEvent.h
0040         rootcint -f $@ -c $(DICTHEADERS)
0041 
0042 libPythiaEvent.so :
0043         $(CXX) -shared -o $@ $(CXXFLAGS) $(CPPFLAGS) $^ $(LDFLAGS)
0044 
0045 clean:
0046         rm -f $(PROGRAM) core *.o *.so DictOutput.cxx