Recompile php

Recompile php

Postby sgripon » Thu May 10, 2012 1:54 pm

Hi,

I would like to add some modules to php in nwsp1 in order to be able to run owncloud. Zip and mb multibyte modules are missing.

Could you tell me what compilation toolchain is used to build the image and if I really need to recompile php.

Thanks.
sgripon
 
Posts: 15
Joined: Sun Jul 17, 2011 5:09 pm

Re: Recompile php

Postby Jocko » Thu May 10, 2012 6:42 pm

Hi sgripon,

Yes, recompile php is required to add modules... :crazy

:idea: About the mbstring module, which is large (2 MB), you can easily find on several web sites some alternative php codes without having this module if your purpose is only to handle UTF-8 string with non ASCII chars.
Jocko
Site Admin - expert
 
Posts: 11529
Joined: Tue Apr 12, 2011 4:48 pm
Location: Orleans, France

Re: Recompile php

Postby fvdw » Thu May 10, 2012 7:16 pm

well it is possible build modules for php without recompile of php by using phpize, but you will need the php build files as well. Those are generated during building php. Furthermore php and apache are closely connected, probably you need to recompile both of them including the dependencies. Its a tricky excercise. We can give you the mbstring module and I can look if the zip module is easy to compile and post it here as well
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Recompile php

Postby fvdw » Thu May 10, 2012 8:11 pm

compiling zip as php module was smooth, the module is attached

you need to put it in /usr/lib/php/extensions and be sure that is set executable (chmod 755)
Of course to load it it will need to be added in php.ini
But I guess you know how to do this

success

php526-extension-module-zip.zip
You do not have the required permissions to view the files attached to this post.
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Recompile php

Postby sgripon » Tue May 22, 2012 11:37 am

Thank you very much ! I'll try this one as soon as possible. If I try to use owncloud on the NAS, I will post the news here. Maybe it could be a nice thing to integrate in the firmware? However, I have to check performance issues first.
sgripon
 
Posts: 15
Joined: Sun Jul 17, 2011 5:09 pm

Re: Recompile php

Postby sgripon » Tue May 22, 2012 8:42 pm

It is ok for zip module now but I still need mbstring. Would it be possible for you to compile it ?
sgripon
 
Posts: 15
Joined: Sun Jul 17, 2011 5:09 pm

Re: Recompile php

Postby fvdw » Tue May 22, 2012 8:46 pm

here you go ;)

mbstring.zip
You do not have the required permissions to view the files attached to this post.
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Recompile php

Postby sgripon » Tue May 22, 2012 8:53 pm

It seems that this one was already on my firmware (or maybe i copied it from somewhere, don't remember). Anyway, it has been created in 2011 and it seems that it doesn't work (not recognized). Any idea ?
sgripon
 
Posts: 15
Joined: Sun Jul 17, 2011 5:09 pm

Re: Recompile php

Postby sgripon » Tue May 22, 2012 8:54 pm

Forget this last post. I have an error in my php.ini. I am doing the test now...
sgripon
 
Posts: 15
Joined: Sun Jul 17, 2011 5:09 pm

Re: Recompile php

Postby fvdw » Tue May 22, 2012 8:59 pm

indeed it is in the firmware already and I am sure it works as it has been tested successfully by Jocko
fvdw
Site Admin - expert
 
Posts: 13471
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Next

Return to Development

Who is online

Users browsing this forum: Bing Bot and 13 guests