From c7efca6d9b0db7305f5352ebf15d915ae5a1fa24 Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Sun, 26 Nov 2023 09:49:12 +0100 Subject: Bug 1479: NativeLibrary: Add getNativeLibraryPath() returning queried used native library path, supported throughout DynamicLibraryBundle[Info] Motivation: It is helpful to retrieve the actually used native library pathname, since loading a library w/o absolute path but lookup through LD_LIBRARY_PATH may render it hard for the user to determine which library is used. +++ +++ Windows implementation simply can use GetModuleFileNameA() with the native library handle. POSIX implementation may utilize a symbol-name to retrieve its address within the loading native library used to retrieved the library information via dladdr(). To support this feature throughout DynamicLibraryBundle and DynamicLibraryBundleInfo, the custom DynamicLibraryBundleInfo specializations shall provide optional symbol-names per each tool-library-name for the POSIX implementation, see above. public interface DynamicLibraryBundleInfo { ... /** * Returns optional list of optional symbol names per {@link #getToolLibNames()} * in same order for an OS which requires the symbol's address to retrieve * the path of the containing library. */ public List getSymbolForToolLibPath(); ... } --- make/scripts/runtest.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'make/scripts/runtest.sh') diff --git a/make/scripts/runtest.sh b/make/scripts/runtest.sh index 7792f08..ab80674 100755 --- a/make/scripts/runtest.sh +++ b/make/scripts/runtest.sh @@ -149,7 +149,7 @@ function onetest() { #onetest com.jogamp.common.nio.TestByteBufferOutputStream 2>&1 | tee -a $LOG #onetest com.jogamp.common.nio.TestByteBufferCopyStream 2>&1 | tee -a $LOG #onetest com.jogamp.common.os.TestElfReader01 $* 2>&1 | tee -a $LOG -onetest com.jogamp.common.os.TestClock01 $* 2>&1 | tee -a $LOG +#onetest com.jogamp.common.os.TestClock01 $* 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.internals.TestType 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.TestJCPP $* 2>&1 | tee -a $LOG @@ -171,7 +171,7 @@ onetest com.jogamp.common.os.TestClock01 $* 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.Test1p1JavaEmitter 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.Test1p2ProcAddressEmitter 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.Test1p2LoadJNIAndImplLib 2>&1 | tee -a $LOG -#onetest com.jogamp.gluegen.test.junit.generation.Test1p2DynamicLibraryBundle 2>&1 | tee -a $LOG +onetest com.jogamp.gluegen.test.junit.generation.Test1p2DynamicLibraryBundle 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.Test2p1FuncPtr 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.Test2p2FuncPtr 2>&1 | tee -a $LOG #onetest com.jogamp.gluegen.test.junit.generation.Test3p1PtrStorage 2>&1 | tee -a $LOG -- cgit v1.2.3