Hacktoberfest 2026: die Issues, die Maintainer für den Oktober markiert haben – offen und einsteigerfreundlich. Hacktoberfest-Issues durchsuchen

pcre2.h missing on Brew PHP setups

Geschlossen
#760 0 Kommentare 0 Reaktionen 1 zugewiesene Person Auf GitHub ansehen

Maintainer antworten meist innerhalb von 1 Tag

@asgrim arbeitet bereits daran.

Seit 06.10.2026.

Bewertung

Dieses Issue wurde noch nicht bewertet.

Beschreibung

bug bug-confirmed maintainer investigating

What are you trying to do?

pie install apcu/apcu (or other packages that need pcre2.h)

What platform, and PIE version are you using?

on an OSX Apple Silicon, with PHP from Homebrew

Steps to reproduce the issue

pie install apcu/apcu

What do you expect to happen?

it should install

What is actually happening

In file included from /Users/james/.pie/php8.5_458f49e988810d5486f8103219b4e19c/vendor/apcu/apcu/apc_iterator.h:26:
/opt/homebrew/Cellar/php/8.5.11/include/php/ext/pcre/php_pcre.h:23:10: fatal error: 'pcre2.h' file not found
   23 | #include "pcre2.h"
      |          ^~~~~~~~~
1 error generated.

Anything else?

Brew uses the system PCRE2 library rather than PHP's, so compiler can't find the header.

Workaround:

CPATH=/opt/homebrew/include pie install apcu/apcu

Options:

  • Detect if external PCRE is used, and pass the appropriate build flags using pkg-config --cflags libpcre2-8 or similar.
  • Detect Homebrew (buildProvider()) and add the include directory
Vorherrschende Sprache
PHP
Sterne
2.1k
Forks
76
Ø Merge
16 Std. 58 Min.
Gemergte PRs (30 T.)
19

Entwicklungsumgebung

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus php/pie

Alle Issues in php/pie

Ähnliche Issues

Weitere Issues zu PHP

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.