Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make loading more robust #91

Closed
ranocha opened this issue Oct 19, 2023 · 0 comments · Fixed by #93
Closed

Make loading more robust #91

ranocha opened this issue Oct 19, 2023 · 0 comments · Fixed by #93
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@ranocha
Copy link
Member

ranocha commented Oct 19, 2023

As discussed with @JoshuaLampert and @sloede, it would be nice if we could make the loading infrastructure more user-friendly. Right now, the code

P4est.jl/src/LibP4est.jl

Lines 15 to 25 in 8202433

@static if _PREFERENCE_LIBP4EST == "P4est_jll"
const libp4est = P4est_jll.libp4est
else
const libp4est = _PREFERENCE_LIBP4EST
end
@static if _PREFERENCE_LIBSC == "P4est_jll"
const libsc = P4est_jll.libsc
else
const libsc = _PREFERENCE_LIBSC
end

will fail if we cannot load P4est_jll.libp4est while P4est.jl is configured to use the JLL (default). Thus, we must first set the P4est.jl preferences and afterwards the MPI preferences (see #90). Moreover, one must always set P4est.jl preferences when custom MPI preferences like these are set if P4est.jl is loaded - even if P4est.jl is not used at all.

It would be much nicer if we would just print a warning if we cannot load libp4est but allow using P4est. Ideally, this should also be done similarly with T8code.jl.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant