-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
LibGit2: Update to 1.9.1 #58731
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
LibGit2: Update to 1.9.1 #58731
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, right, zlib and pcre2 must be specified as dependencies here, and loaded in jll package
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about JLLWrappers
? Should that also be listed as dependency?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And what about CompilerSupportLibraries_jll
? Can that dependency be removed?
https://github.com/JuliaBinaryWrappers/LibGit2_jll.jl/blob/main/Project.toml
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about JLLWrappers? Should that also be listed as dependency?
That's not an stdlib, so no.
And what about
CompilerSupportLibraries_jll
? Can that dependency be removed?https://github.com/JuliaBinaryWrappers/LibGit2_jll.jl/blob/main/Project.toml
It was added by @IanButterworth in #58560.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It was added because libgcc_s seems to be needed on windows.
The good thing is tests should catch what's needed or unnecessary here.
This comment was marked as resolved.
This comment was marked as resolved.
@giordano @IanButterworth Please retrigger the build, there was a spurious failure. |
I think you need to update all manifests anyway |
This fails because there is a test using |
|
The Windows build failure is spurious; can you restart that job? |
Seems like windows (both 32 and 64 bit) has dependency issues
|
This is the current problem:
The library name is I don't think there is a good way to fix that. I'll introduce a special case in the |
The regex for the Windows case in
It contains the subexpression Also, the |
@IanButterworth There were no dependency issues, this was a problem in Julia stripping dash suffixes from library names on Windows. My recent commit added a work-around. |
Ok! I defer to @giordano or @staticfloat about whether the fix is the right one here |
# The library name is `libpcre2-8`, with a dash in | ||
# its name. That works fine on Unix. On Windows, a | ||
# suffix starting with a dash denotes the | ||
# library's soversion. So we think (on Windows) | ||
# that this is the library `libpcre2`, soversion | ||
# 8, and things don't match. | ||
if Sys.iswindows() | ||
if "libpcre2-8" in missing_deps && "libpcre2" in extraneous_deps | ||
missing_deps = setdiff(missing_deps, ["libpcre2-8"]) | ||
extraneous_deps = setdiff(extraneous_deps, ["libpcre2"]) | ||
end | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure Windows has concept of soversion at all, libraries tend to append numbers to the basename to mimic soversions like in other platforms, but that's custom, not very standard. Instead of special-casing libpcre2
here, wouldn't it be possible to list multiple values of library name when libpcre2
is used? That's what BinaryBuilderBase.LibraryProduct
does.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The library name is libpcre2-8
. It contains a dash and a number. This has nothing to do with Windows. The 8
indicates the character encoding (UTF-8). There are also libpcre2-16
and libpcre2-32
, although we don't use them.
We can't really say that PCRE2_jll
provides libpcre2
as a library – that wouldn't work on Linux and macOS, and would lead to a conflict on Windows where we'd then provide three different libraries with the same name.
All is fine on Linux, where dashes in library names do not pose problems. On Windows we (Julia) get confused, and when we extract the library name from the string libpcre2-8.DLL
, we cut off the -8
, although we really shouldn't in this case.
So we need to either fix this in base/binaryplatforms.jl
, where we cut off the dash-suffix, or here in the test. Either way we need an exception for libpcre2-8
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@giordano Please expand on your idea to list multiple library names. The library name is libpcre2-8
. Do you suggest intentionally listing wrong library names?
This is what we currently have:
LibraryProduct("libpcre2-8", :libpcre2_8),
LibraryProduct("libpcre2-16", :libpcre2_16),
LibraryProduct("libpcre2-32", :libpcre2_32)
How should we change this? Are you suggesting adding libpcre2
as alternative name for all three libraries?
No description provided.