Skip to content

Commit

Permalink
Ipopt_jll with LBT (#327)
Browse files Browse the repository at this point in the history
  • Loading branch information
amontoison authored Oct 19, 2022
1 parent 23e91d1 commit 5fb1c6e
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,9 @@ jobs:
- version: '1.6'
os: ubuntu-latest
arch: x86
- version: '1'
os: windows-latest
arch: x86
steps:
- uses: actions/checkout@v2
- uses: julia-actions/setup-julia@v1
Expand Down
5 changes: 4 additions & 1 deletion Project.toml
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,14 @@ version = "1.1.0"

[deps]
Ipopt_jll = "9cc047cb-c261-5740-88fc-0cf96f7bdcc7"
LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e"
MathOptInterface = "b8f27783-ece8-5eb3-8dc8-9495eed66fee"
OpenBLAS32_jll = "656ef2d0-ae68-5445-9ca0-591084a874a2"

[compat]
Ipopt_jll = "=3.13.2, =3.13.4, =300.1400.400"
Ipopt_jll = "=3.13.2, =3.13.4, =300.1400.400, =300.1400.403"
MathOptInterface = "1"
OpenBLAS32_jll = "0.3.10"
julia = "1.6"

[extras]
Expand Down
12 changes: 12 additions & 0 deletions src/Ipopt.jl
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,23 @@
module Ipopt

import Ipopt_jll
import LinearAlgebra
import MathOptInterface
import OpenBLAS32_jll

const MOI = MathOptInterface

function __init__()
if VERSION >= v"1.8"
config = LinearAlgebra.BLAS.lbt_get_config()
if !any(lib -> lib.interface == :lp64, config.loaded_libs)
LinearAlgebra.BLAS.lbt_forward(
OpenBLAS32_jll.libopenblas_path;
verbose = true,
clear = false,
)
end
end
global libipopt = Ipopt_jll.libipopt
return
end
Expand Down

0 comments on commit 5fb1c6e

Please sign in to comment.