close

Just my note

Make webservice (apache + php) on iMX7 dual evk.

1. Add recipe source in /conf/bblayer.conf as below:

  ${BPDIR}/source/meta-openembedded/meta-webserver \

001.png

2. Add IMAGE_INSTALL_append in conf/local.conf as below:

  IMAGE_INSTALL_append += " apache2 php php-cli php-modphp"

002.png

3. Modify php.inc file in /sources/meta-openembedded/meta-oe/recipes-devtools/php

  3.a. Add apache2 at DEPENDS

  3.b. Add RDEPENDS_${PN} = "apache2"

003.png

  3.c. Add apache2 at PACKAGECONFIG

004.png

4. Build image by command fsl-image-gui

5. Download image...

6. Boot...

7. Modify httpd.conf file in /etc/apache2

  7.a. Add LoadModule php5_module lib/apache2/modules/libphp5.so

005.png

  7.b. Add file parse method as below:

<FilesMatch \.php$>

  SetHandler application/x-httpd-php

</FilesMatch>

8. Add php test web page to /usr/share/apache2/htdocs

  <?php phpinfo(); ?>

9. apachectl stop

10. apachectl start

Done!

 

Reference:

https://community.nxp.com/message/459819#45981

https://stackoverflow.com/questions/38239340/apache2-with-php-support-in-yocto

https://www.toradex.com/community/questions/14610/install-php-via-yocto.html

arrow
arrow
    文章標籤
    apache2 php imx7
    全站熱搜
    創作者介紹
    創作者 scarletdream 的頭像
    scarletdream

    Scarlet Just Like Me

    scarletdream 發表在 痞客邦 留言(0) 人氣()