Thread: cross compile php

  1. #16
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    i got the solution!!! change php-5.3.1 for previus version:

    PHP-5.2.10

    NOW i can start to test on mini!!!

    i have a doubt at the end it throws me this:

    Build complete.
    Don't forget to run 'make test'.


    how can i make this make test??

    i almost finish

  2. #17
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    grr i put make test and it throws me this:



    felipe@felipe-desktop:~/Escritorio/php-5.2.10$ make test

    Build complete.
    Don't forget to run 'make test'.

    /home/felipe/Escritorio/php-5.2.10/sapi/cli/php: 1: Syntax error: word
    unexpected (expecting ")")
    make: [test] Error 2 (no tiene efecto)


    did i made a bad compilation? =(

  3. #18
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    hi i configured my web server on my target device but when i test a .php file appears me this:

    503 service unavailable

    i have a doubt do i have to put to run the php.exe file on my target device? i tried to do it but it throws me this mistake:

    eroor while loading shared librares_ libxml2.so2

    i m tring to copy that file on my usb but i cant i think that the reason is why this libxml2 is a symbolic link, but then... how can i solve this problem?



    HELPPPPPPP! I M VERY CLOSE TO FINISH, PLEASE !!

  4. #19
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    hi i solve that problem copying that file on /opt/libxml/lib on mini 2440
    but now throwme this mistake:

    error while loading shared libraries: libz.so.1, at this point i dont
    really know if i am get advance

    and i dont know if making this, the program will run

    =( help please

  5. #20
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    hi i modified the code:

    Code:
    export CROSS_COMPILE=arm-none-linux-gnueabi-
    export CC=${CROSS_COMPILE}"gcc"
    export CXX=${CROSS_COMPILE}"g++"
    ./configure --host=arm-linux --target=arm --prefix=/opt/php1 \
    --disable-short-tags --disable-shared \
    --without-mysql --without-pear --disable-all --disable-short-tags \
    --enable-libxml \
    --with-libxml-dir=/opt/libxml \
    --with-zlib-dir=/opt/zlib
    and send libz.so.1 to /opt/zlib of my mini2440

    but when i put ./php appearsme illegal instrution, i dont what do now, how do i fix 503 service unavailable??

    PLEASE HELP!!!

  6. #21
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    HI im not sure if maybe the libraries of libz and libxml are well compile because i checked the files of lib folder and it created some files of type " Link to shared library" could be this the problem??


    HElP!!!

  7. #22
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    hi i could put to work php on cherokee webserver on my embedd system it seems that i have a bad cross compile of php this was my last use code:


    Code:
    export CROSS_COMPILE=arm-linux-
    export CC=${CROSS_COMPILE}"gcc"
    export CXX=${CROSS_COMPILE}"g++"
    ./configure --host=arm-linux --target=arm --prefix=/opt/php \
    --disable-shared --disable-xml disable-libxml --disable-dom  --disable-simplexml --disable-short-tags \
    --disable-xmlreader --disable-xmlwriter \
    --without-mysql --without-pear --without-iconv --disable-all \
    --enable-fastcgi
    the lines that i had to added to my cherokee.conf file was:

    Code:
    vserver!1!rule!6!disabled = 0
    vserver!1!rule!6!encoder!deflate = 0
    vserver!1!rule!6!encoder!gzip = 1
    vserver!1!rule!6!handler = fcgi
    vserver!1!rule!6!handler!balancer = round_robin
    vserver!1!rule!6!handler!balancer!source!1 = 1
    vserver!1!rule!6!handler!change_user = 0
    vserver!1!rule!6!handler!check_file = 1
    vserver!1!rule!6!handler!error_handler = 1
    vserver!1!rule!6!handler!pass_req_headers = 1
    vserver!1!rule!6!handler!xsendfile = 0
    vserver!1!rule!6!match = extensions
    vserver!1!rule!6!match!extensions = php
    vserver!1!rule!6!only_secure = 0
    vserver!1!rule!6!match!final = 1
    vserver!1!rule!6!timeout = 30
    
    source!1!env!PHP_FCGI_CHILDREN = 5
    source!1!env!PHP_FCGI_MAX_REQUESTS = 490
    source!1!env_inherited = 0
    source!1!host = 127.0.0.1:47990
    source!1!interpreter = /home/php/bin/php-cgi -b 127.0.0.1:47990
    source!1!nick = PHP Interpreter
    source!1!type = interpreter
    i hope that this experiences can be useful for some else.... thanks for all the help

    but my final doubt its

    i had to disable libxml and libz how can this affect the php's work?? i have that doubt according to that i should try to fix my cross compile

    thanks!!

  8. #23
    Registered User
    Join Date
    Jun 2010
    Posts
    18
    Hi again i tested my php on my mini2440 first i made a simple test

    echo"hola mundo";

    and it goes well

    after that i made a formulary and test it on my host machine, there it
    worked well, but when i tested on my mini2440 it didnt, soo i think i have
    to compile this php again grr, i think that the problem should be the
    libraries but .. could be the problem what i said above?

    thanks for the help!!

  9. #24
    Registered User
    Join Date
    Oct 2010
    Posts
    1
    Hola Felipe, queria saber si el web server cherokee es el que viene en el mini2440 con el fs qtopia o es uno que vos instalaste. Gracias.-

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Cross compiling with inline assembly
    By TheEngineer in forum C Programming
    Replies: 10
    Last Post: 04-02-2010, 02:21 PM
  2. Help with PHP extension compilation
    By SkinneyEd in forum C++ Programming
    Replies: 1
    Last Post: 01-10-2006, 04:08 PM
  3. header file compile error
    By Unregistered in forum C Programming
    Replies: 5
    Last Post: 02-23-2002, 06:28 AM
  4. Replies: 4
    Last Post: 11-14-2001, 10:28 AM
  5. how do i compile a program that deals w/classes?
    By Shy_girl_311 in forum C++ Programming
    Replies: 5
    Last Post: 11-11-2001, 02:32 AM