Re: [sword-devel] PHP bindings
I attempted to compile the bindings for PHP as well a while ago, but, if I remember correctly, these bindings were made for PHP 4 and are not compatible with modern PHP. So I started messing around and built a mostly working PHP extension for PHP 8.x. I am not very knowledgeable about C, C++, or PHP internals, but the extension works for my use case. If you’d like, I’d be happy to send you the code and you can do whatever you want with it. - Patrick On Jan 30, 2024 at 2:41 PM -0600, Matěj Cepl , wrote: > On Tue Jan 30, 2024 at 10:33 AM CET, Aim for NaN wrote: > > This errors out, saying that std_list.i cannot be found for templates.i > > Yes, it seems to be missing in swig templates for > PHP (if that’s the problem … I am one of few happy > programmers who know absolutely nothing about PHP), but > how difficult it would be to port those 23 LOC from Python > https://github.com/swig/swig/blob/master/Lib/python/std_list.i to > PHP? > > If you do so, please, do not forget to send it upstream. > > Best, > > Matěj > -- > http://matej.ceplovi.cz/blog/, @mcepl@floss.social > GPG Finger: 3C76 A027 CA45 AD70 98B5 BC1D 7920 5802 880B C9D8 > > Experience is what you get when you don’t get what you want. > -- Dan Stanford > > > ___ > sword-devel mailing list: sword-devel@crosswire.org > http://crosswire.org/mailman/listinfo/sword-devel > Instructions to unsubscribe/change your settings at above page ___ sword-devel mailing list: sword-devel@crosswire.org http://crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page
Re: [sword-devel] PHP bindings
On Tue Jan 30, 2024 at 10:33 AM CET, Aim for NaN wrote: > This errors out, saying that std_list.i cannot be found for templates.i Yes, it seems to be missing in swig templates for PHP (if that’s the problem … I am one of few happy programmers who know absolutely nothing about PHP), but how difficult it would be to port those 23 LOC from Python https://github.com/swig/swig/blob/master/Lib/python/std_list.i to PHP? If you do so, please, do not forget to send it upstream. Best, Matěj -- http://matej.ceplovi.cz/blog/, @mcepl@floss.social GPG Finger: 3C76 A027 CA45 AD70 98B5 BC1D 7920 5802 880B C9D8 Experience is what you get when you don’t get what you want. -- Dan Stanford signature.asc Description: PGP signature ___ sword-devel mailing list: sword-devel@crosswire.org http://crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page
[sword-devel] PHP bindings
Looking to build for Swig 4.1. I run these commands: cd bindings/swig/package libtoolize --force ./autogen.sh ./configure make phpswig It errors out, talking about unknown options. So, I modify the command. swig -php -c++ -o php/Sword.cxx -I. -I/usr/include/sword ./sword.i This errors out, saying that std_list.i cannot be found for templates.i Arguably, std::vector would be a good replacement for std::list. At least, Swig provides std_vector.i for PHP. I only care about building PHP bindings for now. I don't suppose a quick solution would be to replace all instances of std::list with std::vector, would it? ___ sword-devel mailing list: sword-devel@crosswire.org http://crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page
Re: [sword-devel] php bindings
I'm interested in participating in a php version of the sword software. According to the Osis docs the bible texts aren't too var removed from regular xml docs so parsing them out shouldn't be that bad. Also, I was thinking.. instead of trying to incorporate all of these C libs into the php build stack.. why not recreate them as php module/libs or even objects. Granted the effort is duplicated but at least the build is completely separate from the build tree. Anyway, very interested in getting the crosswire bibles online ... where can I help. /bk Brian Smith-15 wrote: Hello, Is anyone using a PHP binding or interface to the sword project? I would like to set up a web application without using the java/tomcat system available from the gnome folks, if at all possible. I have a custom PHP app already built, and I would like to add to it an interface to use sword modules as part of my app. Any help and/or guidance is appreciated. Brian ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page -- View this message in context: http://www.nabble.com/php-bindings-tf3175267.html#a9132102 Sent from the SWORD Dev mailing list archive at Nabble.com. ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page
Re: [sword-devel] php bindings
Technically it is possible to build a PHP library with the SWIG bindings which are already part of the source tree. However, I have only attempted it once or twice without much luck. If you are savvy with the PHP module build system you might be able to get it to work. Otherwise, I don't think I would personally have the time to invest in it for a couple of weeks, but I would be able to answer questions about SWIG and the interfaces themselves. God Bless Jason On 2/5/07, Brian Smith [EMAIL PROTECTED] wrote: Hello, Is anyone using a PHP binding or interface to the sword project? I would like to set up a web application without using the java/tomcat system available from the gnome folks, if at all possible. I have a custom PHP app already built, and I would like to add to it an interface to use sword modules as part of my app. Any help and/or guidance is appreciated. Brian ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page -- http://emptycrate.com Games, Programming, Travel other stuff ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page
Re: [sword-devel] php bindings
Thanks Jason, I think I am going to try to find someone to help me parse data into a MySQL database, so I can just use it that way, rather than trying to interface with the core software libs. If I can just get some core data searchable, then that's all I really need. Brian On 2/7/07, Jason Turner [EMAIL PROTECTED] wrote: Technically it is possible to build a PHP library with the SWIG bindings which are already part of the source tree. However, I have only attempted it once or twice without much luck. If you are savvy with the PHP module build system you might be able to get it to work. Otherwise, I don't think I would personally have the time to invest in it for a couple of weeks, but I would be able to answer questions about SWIG and the interfaces themselves. God Bless Jason On 2/5/07, Brian Smith [EMAIL PROTECTED] wrote: Hello, Is anyone using a PHP binding or interface to the sword project? I would like to set up a web application without using the java/tomcat system available from the gnome folks, if at all possible. I have a custom PHP app already built, and I would like to add to it an interface to use sword modules as part of my app. Any help and/or guidance is appreciated. Brian ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page -- http://emptycrate.com Games, Programming, Travel other stuff ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page
[sword-devel] php bindings
Hello, Is anyone using a PHP binding or interface to the sword project? I would like to set up a web application without using the java/tomcat system available from the gnome folks, if at all possible. I have a custom PHP app already built, and I would like to add to it an interface to use sword modules as part of my app. Any help and/or guidance is appreciated. Brian ___ sword-devel mailing list: sword-devel@crosswire.org http://www.crosswire.org/mailman/listinfo/sword-devel Instructions to unsubscribe/change your settings at above page
[sword-devel] PHP Bindings
Did the php bindings make it into 1.5.5? and if so how do I go about installing/compiling them? -- Davids Mailing List And Spam Receiver Keeping me (relatively) spam free since 2002