[mapserver-users] PHP7 SWIG mapscript shapeObj issues

Dan Oriani dan at reportallusa.com
Thu Jan 11 08:47:08 PST 2018


Good afternoon,

My company is working to migrate to PHP7. I've built the php-mapscript extension using swig and it seems to mostly work, with the exception of shapeObj::fromWKT(). The function returns a null value, and msErrorObj shows a message of, for example, Error reading WKT geometry "POLYGON((1 0, 1 1, 0 1, 0 0, 1 0))". I’ve noticed that if I construct a shapeObj through other methods, such as creating a lineObj and adding it to a shape also seems to not work. If I Add a lineObj to a shapeObj then run toWKT(), PHP crashes entirely with an error of:

php: geos_ts_c.cpp:400: void GEOSFree_r(GEOSContextHandle_t, void*): Assertion `0 != extHandle' failed.
Aborted

What makes this strange to me is that the python module that builds at the same time works with no such failures as I would expect it to. I haven’t kept up very much with any development of any PHP7 mapscript based work, but I figured it would be at least mostly doable through SWIG. Maybe somebody could point me in the right direction, or at least point me to how I could better debug?

Thanks for your time!

Dan Oriani
Software Engineer
Real Estate Portal USA LLC
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20180111/d281b4d1/attachment.htm>


More information about the MapServer-users mailing list