From 0056feaa21489910fa4ef18668602e1f0967ea6c Mon Sep 17 00:00:00 2001 From: Niklas Hambüchen Date: Sat, 13 May 2017 18:54:36 +0200 Subject: python: Remove all uses of find_library. Fixes #1450593 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `find_library()` doesn't consider LD_LIBRARY_PATH on Python < 3.6. Change-Id: Iee26085cb5d14061001f19f032c2664d69a378a8 BUG: 1450593 Signed-off-by: Niklas Hambüchen --- tests/features/ipctest.py | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) (limited to 'tests/features') diff --git a/tests/features/ipctest.py b/tests/features/ipctest.py index 5aff319b8d0..93392486140 100755 --- a/tests/features/ipctest.py +++ b/tests/features/ipctest.py @@ -1,14 +1,8 @@ #!/usr/bin/python import ctypes -import ctypes.util - -# find_library does not lookup LD_LIBRARY_PATH and may miss the -# function. In that case, retry with less portable but explicit name. -libgfapi = ctypes.util.find_library("gfapi") -if libgfapi == None: - libgfapi = "libgfapi.so" -api = ctypes.CDLL(libgfapi,mode=ctypes.RTLD_GLOBAL) + +api = ctypes.CDLL("libgfapi.so",mode=ctypes.RTLD_GLOBAL) api.glfs_ipc.argtypes = [ ctypes.c_void_p, ctypes.c_int, ctypes.c_void_p, ctypes.c_void_p ] api.glfs_ipc.restype = ctypes.c_int -- cgit