Apply updates of the PHP support and fixes in ulinet provided by Knut Landmark. Fix building issue on GNU/Linux by defining semun.

git-svn-id: http://svn.zoo-project.org/svn/trunk@509 4b6b6ad6-68b3-4dcc-9231-bd9b83bc5dc3