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

[pcre2] Fix CMake integration. #31928

Merged
merged 10 commits into from
Sep 22, 2023
Merged

Conversation

teo-tsirpanis
Copy link
Contributor

@teo-tsirpanis teo-tsirpanis commented Jun 10, 2023

This PR applies the patch in PCRE2Project/pcre2#260 to fix the previously broken CMake integration.

  • Changes comply with the maintainer guide
  • SHA512s are updated for each updated download
  • The "supports" clause reflects platforms that may be fixed by this new version
  • Any fixed CI baseline entries are removed from that file.
  • Any patches that are no longer applied are deleted from the port's directory.
  • The version database is fixed by rerunning ./vcpkg x-add-version --all and committing the result.
  • Only one version is added to each modified port's versions file.

@dg0yt
Copy link
Contributor

dg0yt commented Jun 10, 2023

Please mark this as draft.

@teo-tsirpanis teo-tsirpanis marked this pull request as draft June 10, 2023 14:54
@dg0yt
Copy link
Contributor

dg0yt commented Jun 10, 2023

I opened #31929 now to ensure that the pristine update doesn't cause any regressions.

I realize now that the CMake config may be underused (or even unused) in vcpkg (or in general) because we didn't install it due to its poor state. So this PR will probably not give the insight I was hoping for.

@teo-tsirpanis
Copy link
Contributor Author

Some ports break because they were searching for the PCRE2 library in lib. 😭 https://github.com/pocoproject/poco/blob/a00bfbe89fccabbe3606b31c0a1c7edd3da14e2e/cmake/FindPCRE2.cmake#L69-L77

@dg0yt
Copy link
Contributor

dg0yt commented Jun 11, 2023

Some ports break because they were searching for the PCRE2 library in lib. sob https://github.com/pocoproject/poco/blob/a00bfbe89fccabbe3606b31c0a1c7edd3da14e2e/cmake/FindPCRE2.cmake#L69-L77

find_library breaking in vendored Find modules is unrelated to adding official exported CMake config to pcre2.
Port poco doesn't even use this Find module, see patch ports/poco/0007-find-pcre2.patch.

ports/pcre2/portfile.cmake Outdated Show resolved Hide resolved
@LilyWangLL LilyWangLL added the category:port-update The issue is with a library, which is requesting update new revision label Jun 12, 2023
@teo-tsirpanis teo-tsirpanis force-pushed the pcre2-update branch 2 times, most recently from 5d000cd to 880347b Compare June 12, 2023 16:39
ports/pcre2/portfile.cmake Outdated Show resolved Hide resolved
@LilyWangLL
Copy link
Contributor

LilyWangLL commented Jun 13, 2023

Thanks for your PR. PR #31929 updated pcre2 to 10.42, it has been merged, please resolve the conflicts.

@teo-tsirpanis teo-tsirpanis changed the title [pcre2] Update to version 10.42 and fix CMake integration. [pcre2] Fix CMake integration. Jun 13, 2023
@SamuelMarks
Copy link
Contributor

SamuelMarks commented Jun 30, 2023

Any progress here? - Really need PCRE2 for my project (porting libbsd to Windows)

(I've merged this PR into my branch in the interim; so at least I can still work with pcre2)

@teo-tsirpanis
Copy link
Contributor Author

teo-tsirpanis commented Jun 30, 2023

I am waiting for it to get merged upstream in PCRE2Project/pcre2#260.

@LilyWangLL LilyWangLL added the depends:upstream-changes Waiting on a change to the upstream project label Aug 2, 2023
@LilyWangLL LilyWangLL removed the depends:upstream-changes Waiting on a change to the upstream project label Aug 28, 2023
Copy link
Member

@BillyONeal BillyONeal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I fixed the problem that caused every line to be edited; there was an accidental LF -> CRLF in there.

@@ -31,11 +32,11 @@ vcpkg_cmake_configure(
-DPCRE2_SUPPORT_UNICODE=ON
-DPCRE2_BUILD_TESTS=OFF
-DPCRE2_BUILD_PCRE2GREP=OFF
-DCMAKE_DISABLE_FIND_PACKAGE_BZip2=ON
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you explain what this part of the change is doing?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BZip2 and Zlib are used by the pcre2grep program which was disabled by the line just above.

ports/pcre2/usage Outdated Show resolved Hide resolved
@teo-tsirpanis teo-tsirpanis marked this pull request as ready for review September 11, 2023 21:57
@teo-tsirpanis
Copy link
Contributor Author

Can we merge it?

@LilyWangLL LilyWangLL added the info:reviewed Pull Request changes follow basic guidelines label Sep 21, 2023
@vicroms vicroms merged commit acc2fb6 into microsoft:master Sep 22, 2023
15 checks passed
@teo-tsirpanis teo-tsirpanis deleted the pcre2-update branch September 23, 2023 11:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:port-update The issue is with a library, which is requesting update new revision info:reviewed Pull Request changes follow basic guidelines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants