File tree Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Expand file tree Collapse file tree 1 file changed +4
-2
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,8 @@ function use_system_petsc(;libpetsc_path=nothing)
2929 end
3030 end
3131 end
32+ end
33+ if libpetsc_path === nothing
3234 msg = """
3335 Unable to find a Petsc installation in the system.
3436
@@ -39,7 +41,7 @@ function use_system_petsc(;libpetsc_path=nothing)
3941
4042 Example
4143 =======
42-
44+
4345 julia> using PetscCall
4446 julia> using PetscCall.use_system_petsc(;libpetsc_path="path/to/libpetsc.so")
4547 """
@@ -49,7 +51,7 @@ function use_system_petsc(;libpetsc_path=nothing)
4951 flags = Libdl. RTLD_LAZY | Libdl. RTLD_DEEPBIND | Libdl. RTLD_GLOBAL
5052 old_libpetsc_handle = libpetsc_handle[]
5153 new_libpetsc_handle = Libdl. dlopen (libpetsc_path,flags,throw_error= true )
52- try
54+ try
5355 libpetsc_handle[] = new_libpetsc_handle
5456 scalar_type = Ref {PetscDataType} ()
5557 scalar_found = Ref {PetscBool} ()
You can’t perform that action at this time.
0 commit comments