Files
gentoo/sci-physics/geant4_vmc/files/geant4_vmc-6.6-fix-preinstall-tests.patch
Oliver Freyermuth f615ddfb50 sci-physics/geant4_vmc: add 6.6_p1
Closes: https://github.com/gentoo/gentoo/pull/35759

Signed-off-by: Oliver Freyermuth <o.freyermuth@googlemail.com>
Signed-off-by: Guilherme Amadio <amadio@gentoo.org>
2024-03-21 14:39:32 +01:00

21 lines
881 B
Diff

test-suite: set ROOT_INCLUDE_PATH if builddir is passed
Bug: https://github.com/vmc-project/geant4_vmc/pull/60
--- a/examples/test_suite.sh
+++ b/examples/test_suite.sh
@@ -193,8 +193,12 @@ fi
# Set path to shared libraries if --builddir is provided via the option
if [ "x${BUILDDIR}" != "x" ]; then
- LIBS_FROM_BUILDDIR=$(find ${BUILDDIR} -iname "*.so" -exec dirname {} \; | tr '\r\n' ':')
+ LIBS_FROM_BUILDDIR=$(find ${BUILDDIR} -iname "*.so" -exec dirname {} \; | uniq | tr '\r\n' ':')
export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}:${LIBS_FROM_BUILDDIR}
+ # In that case, also use headers from matching source dirs.
+ SOURCEDIR=$(readlink -f ../source/)
+ HEADERS_FROM_SOURCEDIR=$(find ${SOURCEDIR} -iname "*.h" -exec dirname {} \; | uniq | tr '\r\n' ':')
+ export ROOT_INCLUDE_PATH=${ROOT_INCLUDE_PATH}:${HEADERS_FROM_SOURCEDIR}
fi
# Create tmp dir from scratch