Starting from Beginning: WordPress PHP Extension

I got in the mood to compile the WordPress PHP Extension Friday night. I found that it would no longer compile. Gave a “unresolved external symbol _wordpress_module_entry” which is interesting because there is no variable in the code that is named that.

I remember getting that error before last year, but I don’t remember how I was able to fix it. I’m going to start with new code and keep compiling while adding the current code to see where it stops working. It is being compiled statically inside of PHP, which is probably not the best idea. However, it should help with debugging.

PHP 5.3.0 will add additional macros which are useful, but I haven’t really looked over everything. It might be possible to write code easily using PHP macros, I’m just too busy trying to get the current code to work to notice at this point. I will go over the macros at some point to see if I can learn anything on possible solutions to the code I’m attempting.

I’m basically learning from other extensions and going over the code that other people have written to write the extension. It won’t be the best, but I suppose at some point some better programmer will come along and correct the flaws. I’m attempting to learn C/C++ and at the same time try to learn the PHP API to create a PHP extension.

I’m attempting to convert the WordPress Plugin API over to C/C++ to compare the performance of the two. I attempt this back last year for the GSOC project, the code compiled back then, but doesn’t now. So it has been interesting these past two nights.

I’m going to try again today, going to create a new skeleton and attempt the extension again and testing while I develop. If it works out okay, I’m going to continue and try to pick up where I left off last year. If I can get enough done to get some results I can hopefully get some support from people who know what they are doing to help out.

Possibly Related Posts:


Comments are closed.