|
|
DESCRIPTION="CERN's detector description and simulation Tool" | DESCRIPTION="CERN's detector description and simulation Tool" |
HOMEPAGE="http://www.geant4.org/" | HOMEPAGE="http://www.geant4.org/" |
| |
SRC_COM="http://geant4.web.cern.ch/geant4/support/source/" |
SRC_COM="http://geant4.web.cern.ch/geant4/support/source" |
SRC_URI="${SRC_COM}/${MY_P}.tar.gz" | SRC_URI="${SRC_COM}/${MY_P}.tar.gz" |
GEANT4_DATA="G4NDL.3.12 | GEANT4_DATA="G4NDL.3.12 |
G4EMLOW.5.1 | G4EMLOW.5.1 |
|
|
sed -i \ | sed -i \ |
-e '/$(G4LIB)\/$(G4SYSTEM)/d' \ | -e '/$(G4LIB)\/$(G4SYSTEM)/d' \ |
config/architecture.gmk || die "sed architecture.gmk failed" | config/architecture.gmk || die "sed architecture.gmk failed" |
|
sed -i \ |
|
-e 's:$(G4LIB)/$(G4SYSTEM):$(G4TMP):g' \ |
|
config/common.gmk || die "sed common.gmk failed" |
|
sed -i \ |
|
-e 's:$(G4LIB)/$(G4SYSTEM):$(G4TMP):g' \ |
|
-e 's:$(G4BIN)/$(G4SYSTEM):$(G4TMP):g' \ |
|
-e 's:$(G4TMP)/$(G4SYSTEM):$(G4TMP):g' \ |
|
source/GNUmakefile || die "sed GNUmakefile failed" |
} | } |
| |
src_compile() { | src_compile() { |
|
|
LDPATH=${G4LIB} | LDPATH=${G4LIB} |
CLHEP_BASE_DIR=${CLHEP_BASE_DIR} | CLHEP_BASE_DIR=${CLHEP_BASE_DIR} |
EOF | EOF |
|
|
|
# detailed data file locations |
|
if $(use data); then |
|
export G4LEVELGAMMADATA="${G4DATA}/PhotonEvaporation2.0" |
|
export G4RADIOACTIVEDATA="${G4DATA}/RadioactiveDecay3.2" |
|
export G4LEDATA="${G4DATA}/G4EMLOW5.1" |
|
export G4NEUTRONHPCROSSSECTIONS="${G4DATA}/G4NDL3.12" |
|
fi |
|
|
# read env variables defined upto now | # read env variables defined upto now |
printenv | grep ^G4 | uniq >> ${g4env} | printenv | grep ^G4 | uniq >> ${g4env} |
| |
|
|
| |
# but install libraries and Geant library tool manually | # but install libraries and Geant library tool manually |
insinto ${GEANT4_LIBDIR} | insinto ${GEANT4_LIBDIR} |
doins -r lib/${G4SYSTEM}/* || die |
doins -r ${HOME}/geant4/tmp/*.so || die |
|
doins -r ${HOME}/geant4/tmp/libname.map || die |
|
if use static; then |
|
doins -r ${HOME}/geant4/tmp/*.a || die |
|
fi |
exeinto ${GEANT4_LIBDIR} | exeinto ${GEANT4_LIBDIR} |
doexe lib/${G4SYSTEM}/liblist || die |
doexe ${HOME}/geant4/tmp/liblist || die |
| |
g4_create_env_script | g4_create_env_script |
| |
|
|
} | } |
| |
pkg_postinst() { | pkg_postinst() { |
elog "Geant4 projects are by default expected in each user's " |
elog "Geant4 projects are by default build in $G4WORKDIR." |
elog "If you want to change, set \$G4WORKDIR to another directory" |
elog "If you want to change, set \$G4WORKDIR to another directory." |
elog | elog |
elog "Help us to improve the ebuild and dependencies in" | elog "Help us to improve the ebuild and dependencies in" |
elog "http://bugs.gentoo.org/show_bug.cgi?id=212221" | elog "http://bugs.gentoo.org/show_bug.cgi?id=212221" |