Commit 09aba448 authored by Jonathan Lambrechts's avatar Jonathan Lambrechts
Browse files

try if is not available (for ubuntu 20.04)

parent 8045619d
Pipeline #9850 passed with stages
in 51 minutes and 32 seconds
......@@ -29,7 +29,13 @@ import os
petscpath = os.environ["PETSC_DIR"]+"/"+os.environ["PETSC_ARCH"]+"/lib"
os.environ["LD_LIBRARY_PATH"] += ":"+petscpath
lib = np.ctypeslib.load_library("libpetsc",petscpath)
lib = np.ctypeslib.load_library("libpetsc",petscpath)
lib = np.ctypeslib.load_library("libpetsc_real",petscpath)
raise ValueError("petsc library not found")
lib.PetscInitialize(None, None, None)
COMM_WORLD = ctypes.c_void_p.in_dll(lib,"PETSC_COMM_WORLD")
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment