我使用Yocto創建包括apache2的構建,但是我很難添加php支持。我曾經運行過它(去年),但從那以後,meta-openembedded中的meta-webserver層發生了變化。從元網絡服務器的README文件:Apache2在Yocto中支持PHP
"This layer used to provide a modphp recipe that built mod_php, but this is now built as part of the php recipe in meta-oe. However, since apache2 is required to build mod_php, and apache2 recipe is in this layer and recipes in meta-oe can't depend on it, mod_php is not built by default. If you do wish to use mod_php, you need to add "apache2" to the PACKAGECONFIG value for the php recipe in order to enable it."
我加入以下行,我自己的層到PHP:
PACKAGECONFIG_append = " apache2"
,但我得到的編譯錯誤,當它不能找到什麼似乎被阿帕奇包括文件時,編譯mod_php的(包括我下面只有一個錯誤,我得到一個類似的錯誤ap_config.h以及):
In file included from /home/martin/Yocto/poky/rpi/tmp/work/x86_64-linux/php-native/5.6.12-r0/php-5.6.12/sapi/apache2handler/mod_php5.c:26:0: | /home/martin/Yocto/poky/rpi/tmp/work/x86_64-linux/php-native/5.6.12-r0/php-5.6.12/sapi/apache2handler/php_apache.h:24:19: fatal error: httpd.h: No such file or directory | compilation terminated.
有沒有人成功地編譯PHP支持最近的Apache2和如何做到這一點可以提供一些幫助?謝謝!