Resources on how to write your own PHP extension

A few days ago I started to write my first PHP extension, and I have to admit it was a pain in the beginning. Actually it still is, but I’m the one to blame for lacking some C skills. Anyway, my advice is: if you want to write your own extension you’d better have a good reason to do so. Here are some of the most common ones:

  • increase performance
  • change PHP behavior (take a look at these PECL extensions)
  • wrap a C library
  • you are very curious and want to know how to do it anyway

If you still want to give it a try, here are some of the things that helped me along the way:

Maybe I’ll write some posts about this. Maybe.

Leave a Reply