Package Details: geant4 11.3.0-1

Git Clone URL: https://aur.archlinux.org/geant4.git (read-only, click to copy)
Package Base: geant4
Description: A simulation toolkit for particle physics interactions.
Upstream URL: http://geant4.cern.ch/
Keywords: matter montecarlo radiation transport
Licenses: custom: http://geant4.cern.ch/license/
Conflicts: geant4_devel
Submitter: Eothred
Maintainer: donpicoro
Last Packager: donpicoro
Votes: 19
Popularity: 0.000099
First Submitted: 2010-04-08 08:54 (UTC)
Last Updated: 2024-12-08 19:13 (UTC)

Dependencies (29)

Sources (2)

Latest Comments

« First ‹ Previous 1 2 3 4 5 6 7 8 9 10 11 .. 15 Next › Last »

donpicoro commented on 2014-10-27 09:53 (UTC)

The only reason to have the "internal" clhep as opposed the "external" one was to save the user from compiling something extra. Most of my applications work perfectly with the internal one but I guess in order to be more inclusive we can have it as a dependency until the point something breaks. And as for the Qt, I do not justify a new release bump for it. As I said let's wait and see the actual support for Qt in the next release.

JP-Ellis commented on 2014-10-27 09:48 (UTC)

Regarding the cmake >= 3, I did that because cmake 3 introduces a new way of importing libraries and remember getting some issues at one stage... but I can't replicate them now so it probably isn't strictly necessary. Also, regarding the CLHEP, I thought it better to include the full CLHEP (and I in fact created a clhep-git version on AUR); however, I was doing a long run just then and it appears that the latest CLHEP isn't as compatible as I had hoped as it (very rarely) generates an invalid floating point operation. Having said that, the floating point error may be restricted to my computer, since on my computer I get "WARNING - FPE detection is activated" at the start of every Geant4 run, but on another computer I regularly use I do not. I guess it is up to you whether to make CLHEP a dependency or not. PS: I also made a mistake with one of the building options. `-DQT_QMAKE_EXECUTABLE=ON` can be ignored (in fact, it is invalid as it stands and shows that Geant4 completely ignores your environment and manually looks for the files).

donpicoro commented on 2014-10-26 22:52 (UTC)

I see, just commenting those lines out, eh? I reverted to the stable version. People can use the version they prefer but I plan to 'maintain' only the stable one. I kept the external clhep as you had it and the cmake>=3 dependency although not sure why. The important one is definitively NOT to have 2.6 ;-) Thanks for the patch and I hope it works for everybody =P. We'll see how it turns out on Dec. 05 when the new release comes out. /Pico

JP-Ellis commented on 2014-10-26 11:37 (UTC)

This has issues with Qt5, and unfortunately, Geant4 by default searches for the Qt5 libraries first (despite Qt5 support being experimental at the moment). It also searches for the Qt5 libraries in such a way that using QT_SELECT=4 is ignored. I have managed to fix this issue by patching the cmake file so that it ignores Qt5 entirely. Note that the pkgbuild has been update to the beta version (feel free to revert it). ### START OF PKGBUILD ### # Maintainer: Luis Sarmiento < Luis.Sarmiento-ala-nuclear.lu.se > pkgname='geant4' pkgver=10.1beta1 _pkgver=10.01.b01 #pkgver=10.0.2 #_pkgver=10.00.p02 pkgrel=1 pkgdesc="A simulation toolkit for particle physics interactions." depends=('cmake>=3' 'xerces-c' 'qt4' 'glu' 'soxt' 'mesa' 'clhep') replaces=('geant4-deb') optdepends=('java-environment: for histogram visualizations and analysis' 'tcsh: for C Shell support' 'python: for G4Python support' 'geant4-abladata: Data files for nuclear shell effects in INCL/ABLA hadronic mode' 'geant4-ledata: Data files for low energy electromagnetic processes' 'geant4-levelgammadata: Data files for photon evaporation' 'geant4-neutronhpdata: Neutron data files with thermal cross sections' 'geant4-neutronxsdata: Data files for evaluated neutron cross sections on natural composition of elements' 'geant4-piidata: Data files for shell ionisation cross sections' 'geant4-radioactivedata: Data files for radioactive decay hadronic processes' 'geant4-realsurfacedata: Data files for measured optical surface reflectance' 'geant4-saiddata: Data files from evaluated cross-sections in SAID data-base') url="http://geant4.cern.ch/" arch=('x86_64' 'i686') license=('custom: http://geant4.cern.ch/license/') options=('!emptydirs') install="${pkgname}.install" source=("http://geant4.cern.ch/support/source/${pkgname}.${_pkgver}.tar.gz" "Geant4InterfaceOptions.patch" "${pkgname}.install") md5sums=('6e2276cf017a60f042f1edc271e0c172' '1d282b540d671bad495b3d86c32e4324' 'c3652d79011cd3fab2e1081e22f9f513') prepare() { cd ${srcdir}/${pkgname}.${_pkgver} patch -Np1 -i ../Geant4InterfaceOptions.patch } build() { [ -d ${srcdir}/build ] || mkdir ${srcdir}/build cd ${srcdir}/build env -i \ QT_SELECT=4 \ PATH=/usr/bin \ cmake -Wno-dev \ -DCMAKE_BUILD_TYPE=Debug \ -DCMAKE_INSTALL_PREFIX=/usr \ -DCMAKE_INSTALL_LIBDIR=lib \ -DGEANT4_USE_GDML=ON \ -DGEANT4_USE_G3TOG4=ON \ -DGEANT4_USE_QT=ON \ -DQT_QMAKE_EXECUTABLE=ON \ -DGEANT4_USE_XM=ON \ -DGEANT4_BUILD_MULTITHREADED=ON \ -DGEANT4_USE_SYSTEM_CLHEP=ON \ -DGEANT4_USE_OPENGL_X11=ON \ -DGEANT4_USE_INVENTOR=ON \ -DGEANT4_USE_RAYTRACER_X11=ON \ -DGEANT4_USE_SYSTEM_EXPAT=ON \ -DGEANT4_USE_SYSTEM_ZLIB=ON \ -DGEANT4_BUILD_CXXSTD=c++11 \ ../${pkgname}.${_pkgver} make } package() { #Since the basic package does not include the data files, their #configuration should be removed from the configuration file. Data #files are also available on the AUR and the environment variables are #set automatically for you from the packages. msg "Removing wrongly set environment variables" variables=("G4LEDATA" \ "G4LEVELGAMMADATA" \ "G4NEUTRONHPDATA" \ "G4NEUTRONXSDATA" \ "G4PIIDATA" \ "G4RADIOACTIVEDATA" \ "G4REALSURFACEDATA" \ "G4SAIDXSDATA" \ "G4ABLADATA" ) for _varname in ${variables[*]} do sed -i "/${_varname}/d" ${srcdir}/build/InstallTreeFiles/geant4.sh sed -i "/${_varname}/d" ${srcdir}/build/InstallTreeFiles/geant4.csh done cd ${srcdir}/build make DESTDIR="${pkgdir}" install echo 'pushd /usr/bin &> /dev/null && source geant4.sh && popd &>/dev/null' > ${srcdir}/geant4.profile.sh echo 'pushd /usr/bin &> /dev/null && source geant4.csh && popd &>/dev/null' > ${srcdir}/geant4.profile.csh install -d ${pkgdir}/etc/profile.d install -m755 ${srcdir}/geant4.profile.sh ${pkgdir}/etc/profile.d/geant4.sh install -m755 ${srcdir}/geant4.profile.csh ${pkgdir}/etc/profile.d/geant4.csh } ### END OF PKGBUILD ### ### START OF Geant4InterfaceOptions.patch ### diff --git a/cmake/Modules/Geant4InterfaceOptions.cmake b/cmake/Modules/Geant4InterfaceOptions.cmake.new index 256bc91..94c2de6 100644 --- a/cmake/Modules/Geant4InterfaceOptions.cmake +++ b/cmake/Modules/Geant4InterfaceOptions.cmake @@ -88,29 +88,29 @@ if(GEANT4_USE_QT) find_package(Qt5OpenGL QUIET) find_package(Qt5PrintSupport QUIET) - if(Qt5Core_FOUND - AND Qt5Gui_FOUND - AND Qt5Widgets_FOUND - AND Qt5OpenGL_FOUND - AND Qt5PrintSupport_FOUND) - # Compatibility - macro(qt4_wrap_cpp) - qt5_wrap_cpp(${ARGN}) - endmacro() - set(Qt5_USE_FILE_IN "${PROJECT_SOURCE_DIR}/cmake/Templates/Geant4UseQt5.cmake.in") - set(QT_USE_FILE "${PROJECT_BINARY_DIR}/Geant4UseQt5.cmake") - configure_file("${Qt5_USE_FILE_IN}" "${QT_USE_FILE}" @ONLY) - get_target_property(QT_QMAKE_EXECUTABLE ${Qt5Core_QMAKE_EXECUTABLE} IMPORTED_LOCATION) - set(G4QTLIBLIST "-lQt5PrintSupport -lQt5Widgets -lQt5Gui -lQt5Core") - set(G4GLQTLIBLIST "-lQt5OpenGL ${G4QTLIBLIST}") - else() + # if(Qt5Core_FOUND + # AND Qt5Gui_FOUND + # AND Qt5Widgets_FOUND + # AND Qt5OpenGL_FOUND + # AND Qt5PrintSupport_FOUND) + # # Compatibility + # macro(qt4_wrap_cpp) + # qt5_wrap_cpp(${ARGN}) + # endmacro() + # set(Qt5_USE_FILE_IN "${PROJECT_SOURCE_DIR}/cmake/Templates/Geant4UseQt5.cmake.in") + # set(QT_USE_FILE "${PROJECT_BINARY_DIR}/Geant4UseQt5.cmake") + # configure_file("${Qt5_USE_FILE_IN}" "${QT_USE_FILE}" @ONLY) + # get_target_property(QT_QMAKE_EXECUTABLE ${Qt5Core_QMAKE_EXECUTABLE} IMPORTED_LOCATION) + # set(G4QTLIBLIST "-lQt5PrintSupport -lQt5Widgets -lQt5Gui -lQt5Core") + # set(G4GLQTLIBLIST "-lQt5OpenGL ${G4QTLIBLIST}") + # else() unset(Qt5Core_DIR CACHE) unset(Qt5Gui_DIR CACHE) unset(Qt5Widgets_DIR CACHE) unset(Qt5OpenGL_DIR CACHE) unset(Qt5PrintSupport_DIR CACHE) find_package(Qt4 REQUIRED COMPONENTS QtCore QtGui QtOpenGL) - endif() + # endif() find_package(OpenGL REQUIRED) ### END OF Geant4InterfaceOptions.patch ###

Hell-G commented on 2014-05-21 20:26 (UTC)

No worries! Thank you very much for your help! I don't think it has anything to do with you preparing the package. I guess it is Geant4 and Qt5 related. I will see, if I can get help from the Geant4 community.

donpicoro commented on 2014-05-21 08:05 (UTC)

Sorry for not being more helpful here but without proper reproducibility of the problem it becomes almost impossible for me (also non Qt expert) to diagnose anything. Since this doesn't look like a packaging issue I suggest you to post a question at the Geant4 forums: http://hypernews.slac.stanford.edu/HyperNews/geant4/cindex possibly under the category "(Graphical) User Interfaces" or wherever you see fit. keep me posted should you find some insight about this.

Hell-G commented on 2014-05-21 00:35 (UTC)

Thank you very much for the additional suggestions! Unfortunately, it didn't work either. I'm out of ideas at the moment. Maybe an update will help at some point.

donpicoro commented on 2014-05-16 08:54 (UTC)

Or... this may or may not be the answer... but have you had a look at qtchooser? from extra/qtchooser ? and then at the PKGBUILD try to run (in the same line) QT_SELECT=qt4 cmake ... Another option is for example, to set Qt4 symlink /etc/xdg/qtchooser/4.conf to ~/.config/qtchooser/default.conf. let me know how it goes

Hell-G commented on 2014-05-15 22:09 (UTC)

Unfortunately, it doesn't work for me. Even with cmake -DGEANT4_USE_QT=ON -DQT_QMAKE_EXECUTABLE=/usr/bin/qmake-qt4 cmake still chooses Qt5 over Qt4. After this configure step, ccmake shows me: Qt5Core_DIR /usr/lib64/cmake/Qt5Core Qt5Gui_DIR /usr/lib64/cmake/Qt5Gui Qt5OpenGL_DIR /usr/lib64/cmake/Qt5OpenGL Qt5PrintSupport_DIR /usr/lib64/cmake/Qt5PrintSuppor Qt5Widgets_DIR /usr/lib64/cmake/Qt5Widgets This is confusing me, as most of the similar problems I found online were solved by this. I also tried "export QT_SELECT=4" before cmake with the same result. This is surprising as this changes the output of "qmake --version" from QMake version 3.0 Using Qt version 5.2.1 in /usr/lib to QMake version 2.01a Using Qt version 4.8.6 in /usr/lib but cmake still uses Qt5. My next try was using find_package( Qt4 REQUIRED ) set(QT_QMAKE_EXECUTABLE /usr/bin/qmake-qt4) in the CMakeLists.txt of Geant4, but with no luck as well. Any other ideas? Thanks!