IAP GITLAB

Commit 9b67fac1 authored by Tanguy Pierog's avatar Tanguy Pierog

add DPMJETIII.2019-1

everything prepared but compilation do not finish yet
parent 8c10375d
......@@ -12,7 +12,8 @@ OPTION (__PYTHIA__ "Build with model" OFF)
OPTION (__HIJING__ "Build with model" OFF)
OPTION (__SIBYLL__ "Build with model" ON)
OPTION (__PHOJET__ "Build with model" OFF)
OPTION (__DPMJET__ "Build with model" ON)
OPTION (__DPMJET17__ "Build with model" OFF)
OPTION (__DPMJET19__ "Build with model" ON)
OPTION (__QGSJETII03__ "Build with model" OFF)
OPTION (__QGSJETII04__ "Build with model" ON)
######################################ONLY EDIT THIS######################################
......@@ -151,6 +152,10 @@ FILE(READ ${PROJECT_SOURCE_DIR}/src/dpmjet/3.2017-1/dpmjet.f-HEPMCTEMPLATE templ
STRING( REGEX REPLACE "HEPEVT_SIZE_REPLACE" "${Replace_String}" template18 "${template17}")
FILE(WRITE ${PROJECT_SOURCE_DIR}/src/dpmjet/3.2017-1/dpmjet.f "${template18}")
FILE(READ ${PROJECT_SOURCE_DIR}/src/dpmjet/3.2019-1/hepevt-HEPMCTEMPLATE template19)
STRING( REGEX REPLACE "HEPEVT_SIZE_REPLACE" "${Replace_String}" template20 "${template19}")
FILE(WRITE ${PROJECT_SOURCE_DIR}/src/dpmjet/3.2019-1/DPMJET-19.1/include/pythia/inc/hepevt "${template20}")
......@@ -220,15 +225,27 @@ get_property(HELPER SOURCE src/models.F PROPERTY COMPILE_FLAGS)
set_property(SOURCE src/models.F PROPERTY COMPILE_FLAGS "${HELPER} -D __PHOJET__")
ENDIF (__PHOJET__)
IF (__DPMJET__)
IF (__DPMJET17__)
ADD_SUBDIRECTORY ("${PROJECT_SOURCE_DIR}/src/dpmjet/3.2017-1")
LIST(APPEND TABS dpmjpar.dat)
LIST(APPEND TABS dpmCT14LL.pds)
LIST(APPEND TABS conextar.glb)
ADD_SUBDIRECTORY ("${PROJECT_SOURCE_DIR}/src/dpmjet/3.2017-1")
SET(STATIC_LIBS ${STATIC_LIBS} Dpmjet)
SET(STATIC_LIBS ${STATIC_LIBS} Dpmjet17)
get_property(HELPER SOURCE src/models.F PROPERTY COMPILE_FLAGS)
set_property(SOURCE src/models.F PROPERTY COMPILE_FLAGS "${HELPER} -D __DPMJET__ -D __DPMJET17__")
ENDIF (__DPMJET17__)
IF (__DPMJET19__)
ADD_SUBDIRECTORY ("${PROJECT_SOURCE_DIR}/src/dpmjet/3.2019-1")
LIST(APPEND TABS DPMJET-19.1/dpmdata/dpmjpar.dat_higher_diff)
LIST(APPEND TABS DPMJET-19.1/dpmdata/dpmjpar.dat)
LIST(APPEND TABS DPMJET-19.1/dpmdata/dpmCT14LL.pds)
LIST(APPEND TABS DPMJET-19.1/dpmdata/dpmjet.dat)
LIST(APPEND TABS conextar.glb)
SET(STATIC_LIBS ${STATIC_LIBS} Dpmjet19)
get_property(HELPER SOURCE src/models.F PROPERTY COMPILE_FLAGS)
set_property(SOURCE src/models.F PROPERTY COMPILE_FLAGS "${HELPER} -D __DPMJET__")
ENDIF (__DPMJET__)
set_property(SOURCE src/models.F PROPERTY COMPILE_FLAGS "${HELPER} -D __DPMJET__ -D __DPMJET19__")
ENDIF (__DPMJET19__)
#put definition outside "if" because it is always is crmc.param file
SET (QGSJETII_TABS "03")
......
......@@ -16,4 +16,6 @@
#cmakedefine __QGSJETII03__
#cmakedefine __QGSJETII04__
#cmakedefine __DPMJET__
#cmakedefine __DPMJET17__
#cmakedefine __DPMJET19__
......@@ -56,7 +56,12 @@ bool CRMCinterface::init(int HEmodel)
#ifdef __QGSJETII03__
case 11: libname << "QgsjetII03"; break;
#endif
case 12: libname << "Dpmjet"; break;
#ifdef __DPMJET17__
case 12: libname << "Dpmjet17"; break;
#endif
#ifdef __DPMJET19__
case 12: libname << "Dpmjet19"; break;
#endif
default: libname << "UnknownModel"; break;
}
libname << ".so";
......
......@@ -111,8 +111,11 @@ CRMCoptions::ParseOptions(int argc, char** argv)
#ifdef __QGSJETII03__
<< ", 11=QGSJETII-03"
#endif
#ifdef __DPMJET__
#ifdef __DPMJET17__
<< ", 12=DPMJet-III_2017.1"
#endif
#ifdef __DPMJET19__
<< ", 12=DPMJet-III_2019.1"
#endif
<< "]";
......@@ -389,7 +392,12 @@ CRMCoptions::DumpConfig() const
case 7: cout << " (QGSJETII-04) \n"; break;
case 8: cout << " (Phojet) \n"; break;
case 11: cout << " (QGSJETII-03) \n"; break;
#ifdef __DPMJET17__
case 12: cout << " (DPMJet-III 2017.1) \n"; break;
#endif
#ifdef __DPMJET19__
case 12: cout << " (DPMJet-III 2019.1) \n"; break;
#endif
default:
cerr << " (unknown model) \n";
exit(1);
......@@ -471,7 +479,12 @@ CRMCoptions::GetOutputFileName() const
case 7: crmcFileName << "qgsjetII04"; break;
case 8: crmcFileName << "phojet"; break;
case 11: crmcFileName << "qgsjetII03"; break;
case 12: crmcFileName << "dpmjet"; break;
#ifdef __DPMJET17__
case 12: crmcFileName << "dpmjetIII17"; break;
#endif
#ifdef __DPMJET19__
case 12: crmcFileName << "dpmjetIII19"; break;
#endif
default:
cerr << " crmcOut: error - unknown model " << fHEModel << endl;
cerr << " exit ..." << endl;
......
......@@ -3,13 +3,13 @@ FILE(GLOB files *.f)
set_source_files_properties( dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F PROPERTIES COMPILE_FLAGS "-D __DPMJET__")
IF (__CRMCSTATIC__)
add_library(Dpmjet STATIC dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F)
add_library(Dpmjet17 STATIC dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F)
ELSE (__CRMCSTATIC__)
add_library(Dpmjet SHARED dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F)
target_link_libraries(Dpmjet CrmcBasic)
add_library(Dpmjet17 SHARED dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F)
target_link_libraries(Dpmjet17 CrmcBasic)
ENDIF (__CRMCSTATIC__)
INSTALL (TARGETS Dpmjet
INSTALL (TARGETS Dpmjet17
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib/static
......
*.o
*.so
*.a
\ No newline at end of file
INCLUDE_DIRECTORIES ("${PROJECT_SOURCE_DIR}/src/dpmjet/3.2019-1")
FILE(GLOB files dpmjet_epos.f ../../crmc-aaa.f ../../models.F)
FILE(GLOB filesDum DPMJET-19.1/common/*.f)
FILE(GLOB filesDpm DPMJET-19.1/src/dpmjet/*.f)
FILE(GLOB filesPho DPMJET-19.1/src/phojet/*.f)
FILE(GLOB filesPyt DPMJET-19.1/src/pythia/*.f)
include_directories(DPMJET-19.1/include/dpmjet DPMJET-19.1/include/phojet DPMJET-19.1/include/pythia DPMJET-19.1/include/flinclude)
set_source_files_properties( ${filesPho} ${filesPyt} ${filesDpm} ${filesDum} ${files} PROPERTIES COMPILE_FLAGS "-xf77-cpp-input -D __DPMJET__")
IF (__CRMCSTATIC__)
add_library(Dpmjet19 STATIC ${filesPho} ${filesPyt} ${filesDpm} ${filesDum} ${files})
ELSE (__CRMCSTATIC__)
add_library(Dpmjet19 SHARED ${filesPho} ${filesPyt} ${filesDpm} ${filesDum} ${files})
target_link_libraries(Dpmjet19 CrmcBasic)
ENDIF (__CRMCSTATIC__)
INSTALL (TARGETS Dpmjet19
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib/static
)
INCLUDE_DIRECTORIES ("${PROJECT_SOURCE_DIR}/src/dpmjet/3.2017-1")
FILE(GLOB files *.f)
set_source_files_properties( dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F PROPERTIES COMPILE_FLAGS "-D __DPMJET__")
IF (__CRMCSTATIC__)
add_library(Dpmjet STATIC dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F)
ELSE (__CRMCSTATIC__)
add_library(Dpmjet SHARED dpmjet.f dpmjet_epos.f phojet.f pythia-6427_cors.f build.f ../../crmc-aaa.f ../../models.F)
target_link_libraries(Dpmjet CrmcBasic)
ENDIF (__CRMCSTATIC__)
INSTALL (TARGETS Dpmjet
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib/static
)
*.o
*.so
*.a
\ No newline at end of file