Pcre migrate - #1
Closed
pdx-daniel wants to merge 13 commits into
Closed
Conversation
…re2; remove PCRE v1 subtree; update build.zig for Zig 0.14+; wasm uses vendored PCRE2; docs updated
…m appropriate files
Removed complex error handling - We expect src/pcre2/ to exist Removed b parameter - No longer needed for dynamic allocation Added static pcre2Sources array - Like the original approach Simplified function signature - Back to the original pattern
…y layer - Remove @Hasfield and @hasDecl checks for main executable - Simplify from 5 lines of compatibility code to 1 clean line - Use direct addExecutable API with target and optimize parameters - All tests pass: C tests (21/21), Python tests (8/8) - All build targets work: main build and WASM build Part of build.zig cleanup plan step 1
… layer - Remove @hasDecl checks for addSharedLibrary, setTarget, and setOptimize - Simplify from 3 lines of compatibility code to direct API usage - Keep essential macOS headerpad_max_install_names setting - All tests pass: C tests (21/21), Python tests (8/8) - All build targets work: main build and WASM build Part of build.zig cleanup plan step 2
…y layer - Remove @Hasfield and @hasDecl checks for test executables - Simplify from 4 lines of compatibility code to direct API usage - Use direct addExecutable API with target and optimize parameters - All tests pass: C tests (21/21), Python tests (8/8) - All build targets work: main build and WASM build Part of build.zig cleanup plan step 3
- Remove @Hasfield and @hasDecl checks for WASM executable - Simplify from 4 lines of compatibility code to direct API usage - Use direct addExecutable API with target and optimize parameters - Keep essential WASM-specific settings: entry = .disabled, import_symbols = true - All tests pass: C tests (21/21), Python tests (8/8) - All build targets work: main build and WASM build Part of build.zig cleanup plan step 4
- Add vendored-pcre build option (defaults to true for reliability) - Restore linkPcre function signature to accept vendored_pcre parameter - Support both vendored PCRE2 (src/pcre2/) and system PCRE2 (pcre2-8) - Package maintainers can use -Dvendored-pcre=false for system libraries - All tests pass: C tests (21/21), Python tests (8/8) - All build targets work: main build, WASM build, and system PCRE2 build Part of build.zig cleanup plan step 5 - restores flexibility lost in PCRE2 migration
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request: PCRE v1 → PCRE2 Migration with Zig 0.14+ Support
Overview
Migrates FastFEC from end-of-life PCRE v1 to PCRE2 while adding Zig 0.14+ support and cleaning up the build system.
Why This Change
What Changed
src/pcre2/src/regex.handsrc/regex.cto maintain API compatibilitybuild.zigfor Zig 0.14+ with flexible PCRE2 linkingKey Features
-Dvendored-pcreoption (defaults to true)Test Results
Build Options
Files Changed
Ready for merge ✅ - All tests passing, no breaking changes.