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

Update the gen folder #200

Merged
merged 1 commit into from
Nov 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion gen/analyzer.jl
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
using HSL_jll
using JuliaFormatter

release = "2023.10.6"
release = "2023.11.7"
libhsl = "/home/alexis/Bureau/git/hsl/libhsl/libHSL-$release/"

# Symbols of the shared library libhsl
Expand Down
5 changes: 3 additions & 2 deletions gen/rewriter.jl
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,10 @@ function rewrite!(path::String, name::String, optimized::Bool)
text = read(path, String)
if name == "libhsl"
updated_text = replace(text, "# no prototype is found for this function at libhsl.h:44:6, please use with caution\n" => "")
updated_text = replace(updated_text, "major, minor, patch)\n" => ")\n major = Ref{Cint}(0)\n minor = Ref{Cint}(0)\n patch = Ref{Cint}(0)\n")
updated_text = replace(updated_text, "major, minor, patch)\n" => ")\n major = Ref{Cint}(0)\n minor = Ref{Cint}(0)\n patch = Ref{Cint}(0)\n")
updated_text = replace(updated_text, "Ptr{Cint}" => "Ref{Cint}")
updated_text = replace(updated_text, "Cvoid\n" => "Cvoid\n VersionNumber(major[], minor[], patch[])\n")
updated_text = replace(updated_text, " @ccall" => " @ccall")
updated_text = replace(updated_text, "Cvoid\n" => "Cvoid\n return VersionNumber(major[], minor[], patch[])\n")
else
solver = split(name, "_")[2]
updated_text = replace(text, "struct $solver" => "mutable struct $solver")
Expand Down
Loading