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

Swap installation order of Trixi.jl and LibTrixi.jl #192

Merged
merged 9 commits into from
Jun 25, 2024
Merged
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -37,13 +37,13 @@ jobs:
julia_version:
- '1.10'
t8code_version:
- '1.4.1'
- '2.0.0'
include:
- os: ubuntu-latest
test_type: package-compiler
arch: x64
julia_version: '1.9.3' # 1.9.4: missing nghttp2 symbols in libcurl
t8code_version: '1.4.1'
t8code_version: '2.0.0'
env:
# Necessary for HDF5 to play nice with Julia
LD_PRELOAD: /lib/x86_64-linux-gnu/libcurl.so.4
Expand Down
2 changes: 1 addition & 1 deletion LibTrixi.jl/Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Trixi = "a7f1ee26-1774-49b1-8366-f1abc58fbfcb"
MPI = "0.20.13"
OrdinaryDiffEq = "6.53.2"
Pkg = "1.8"
Trixi = "0.5.29, 0.6, 0.7"
Trixi = "0.7.16"
julia = "1.8"

[preferences.OrdinaryDiffEq]
Expand Down
4 changes: 2 additions & 2 deletions LibTrixi.jl/src/api_jl.jl
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,8 @@ end


function trixi_nelements_global_jl(simstate)
_, _, solver, cache = mesh_equations_solver_cache(simstate.semi)
return nelementsglobal(solver, cache)
mesh, _, solver, cache = mesh_equations_solver_cache(simstate.semi)
return nelementsglobal(mesh, solver, cache)
benegee marked this conversation as resolved.
Show resolved Hide resolved
end


Expand Down
21 changes: 12 additions & 9 deletions utils/libtrixi-init-julia
Original file line number Diff line number Diff line change
Expand Up @@ -335,15 +335,10 @@ fi
[ $? -eq 0 ] || die "could not configure system HDF5 library for Julia"
echo

# Develop LibTrixi.jl
echo "Install LibTrixi.jl..."
JULIA_DEPOT_PATH="$julia_depot" JULIA_PKG_PRECOMPILE_AUTO=0 \
$julia_exec --project=. \
-e "using Pkg; Pkg.develop(path=\"$libtrixi_jl_path\")"
[ $? -eq 0 ] || die "could not install LibTrixi.jl"
echo
sloede marked this conversation as resolved.
Show resolved Hide resolved

# Install remaining dependencies
# Install Trixi.jl and OrdinaryDiffEq.jl first
# Rationale: By first installing Trixi.jl, we ensure that we use its latest version,
# even if it does not play nicely with the latest version of OrdinaryDiffEq.jl.
# xref: https://github.com/trixi-framework/libtrixi/issues/190
echo "Install Trixi.jl and OrdinaryDiffEq.jl..."
JULIA_DEPOT_PATH="$julia_depot" JULIA_PKG_PRECOMPILE_AUTO=0 \
$julia_exec --project=. \
Expand All @@ -354,6 +349,14 @@ Pkg.add([\"Trixi\", \"OrdinaryDiffEq\"])
[ $? -eq 0 ] || die "could not install dependencies"
echo

# Develop LibTrixi.jl
echo "Install LibTrixi.jl..."
JULIA_DEPOT_PATH="$julia_depot" JULIA_PKG_PRECOMPILE_AUTO=0 \
$julia_exec --project=. \
-e "using Pkg; Pkg.develop(path=\"$libtrixi_jl_path\")"
[ $? -eq 0 ] || die "could not install LibTrixi.jl"
echo

# Install and precompile everything
if [ $SKIP_PRECOMPILE -ne 1 ]; then
echo "Precompile all packages ..."
Expand Down
Loading