php / php/php-src

Building `--with-fpm` without `--prefix` adds `NONE` to include path in `php-fpm.conf.default`

オープン
#20,845 コメント 4 件 リアクション 0 件 担当者 1 名 GitHub で見る

@bukka がすでに取り組んでいます。

2026年1月6日 から。

Bug Category: Build System SAPI: fpm Status: Needs Triage
主要言語
C
スター
40.4k
フォーク
8.1k
平均マージ
2日 13時間
マージ済み PR(30日)
96

説明

Description

There's a small bug while building php-fpm, but with no prefix definition. After build process you get an /usr/local/etc/php-fpm.conf.default, but the include path is wrong;

# current
include=NONE/etc/php-fpm.d/*.conf

# should
include=/usr/local/etc/php-fpm.d/*.conf

To solve this, you can simply run ./configure with --prefix=/usr/local flag.

I searched a bit in the code & think there's a missing default setting in C, but I'm too stupid for that language :-) Found out following lines of code, may this will help a bit for faster debugging :-)
https://github.com/php/php-src/blob/master/sapi/fpm/php-fpm.conf.in#L142
https://github.com/php/php-src/blob/master/sapi/fpm/config.m4#L502
https://github.com/php/php-src/blob/master/main/build-defs.h.in#L28

PS: There's an old workaround in current official docker images for that, seems they were too frustrated a) trying a rebuild with prefix flag & b) opening an issue :D
https://github.com/docker-library/php/blob/master/8.5/alpine3.23/fpm/Dockerfile#L211
PS²: Is it possible to generate the config-files without ´.default` suffix? :)

PHP Version
even before php8 era
Operating System

No response

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

評価

この issue はまだ評価されていません。

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。