| Bug #25704 | Configuration issue with regex | ||||
|---|---|---|---|---|---|
| Submitted: | 30 Sep 2003 11:15am UTC | Modified: | 2 Oct 2003 12:01pm UTC | ||
| From: | stephen dot irven at britishwaterways dot co dot uk | Assigned to: | |||
| Status: | Bogus | Category: | Regexps related | ||
| Version: | 4.3.3 | OS: | Redhat 8 (kernel 2.4.18-27.8.0) | ||
[30 Sep 2003 11:15am UTC] stephen dot irven at britishwaterways dot co dot uk
[2 Oct 2003 12:01pm UTC] sniper@php.net
That phpmapscript module should be rewritten. (seems like it's written for PHP 3?!) When you build PHP with Apache1/2, it will ALWAYS default to php provided regex otherwise it won't compile.
[3 Oct 2003 11:05am UTC] morissette at dmsolutions dot ca
Sniper, I'm the developer of PHP MapScript and we need to find a solution to this issue and not just blame the problem on the extension which is not a solution at all. Why is it that when you compile PHP as an Apache module it *MUST* use the builtin regex? Can you please give me pointers to docs or to a developer who could give me more details on the reasons why PHP can't work with the system regex when compiled as an Apache module? The problem here is that PHP MapScript is based on other packages that use the system regex. If we let PHP use its bundled regex and then let mapscript use the system regex we end up with 2 different copies of regex in the same process. If both were 100% identical this would be no problem, but they are not: they use the same function names, the same regex_t struct name but with different sizes. This situation often leads to instability or crashes. The only solution then would be to compile PHP MapScript using the system regex, but doing this can be a real pain since PHP's regex is not setup to be shared by external programs outside of PHP. Before we try to do that I need to understand why PHP can't use the system regex in the first place Note that this issue may affect any other module that uses regex, not just mapscript, that's why it would be better to fix it in PHP than to work around it in every other extension that uses regex. Thanks in advance for your help. P.S. For the record mapscript has its own bug about this: http://mapserver.gis.umn.edu/bugs/show_bug.cgi?id=252
