Re: preg_* function errors

[email protected] (Trix Farrar)
Newsgroups php.qa.reports
Message-ID <[email protected]>
On Fri, Nov 06, 2009 at 10:49:03AM -0600, Trix Farrar wrote:
> Background:
> Attempting to install ipplan 4.92a under FreeBSD 7.2p4 w/ 
> 
> Server: Apache/2.0.63 (FreeBSD) DAV/2 PHP/5.2.11 with Suhosin-Patch
>         SVN/1.6.6 mod_apreq2-20090110/2.7.1 mod_perl/2.0.4
>         Perl/v5.10.1
> 
> Running the /ipplan/admin/schemacreate.php page outputs the following
> (in part):
> 
[snip]
>    PHP 5.2.11 (FreeBSD)
>    Unknown error type: [2] preg_match() [function.preg-match]:
>    Internal pcre_fullinfo()
>    error -3 Line: 353 File:
>    /usr/local/share/ipplan/adodb/adodb.inc.php
> 
>    Unknown error type: [2] preg_replace() [function.preg-replace]:
>    Internal pcre_fullinfo()
>    error -3 Line: 535 File:
>    /usr/local/share/ipplan/adodb/adodb-datadict.inc.php
> 

I now know why this fails.  If FreeBSD is compiled without NLS
support, the preg_* functions will fail with unknown errors.

I had 'WITHOUT_NLS="YES"' defined in /etc/make.conf when the system
was built.  I removed the variable, re-compiled and re-installed world
and kernel, then rebooted.  Subsequent runs of ipplan did not give PHP
errors or failures.  No ports were re-compiled; just kernel and world
(the OS).

In Google searches, I have seen similar error messages reported, but
no resolutions.  This may also explain bug #29914 and #33367.  They my
both actually be related to kernel-based NLS (or lack thereof).

Hopefully, this can give somebody a heads-up on where to look.  If a
workaround cannot be found, at least NLS in the kernel could be added
as a stated requirement with an appropriate test for its presence.

-- 
John D. "Trix" Farrar, CCNA         __\\|//__               Basement.NET
[email protected]                   (` o-o ')   http://www.basement.net/
-----------------------------------ooO-(_)-Ooo--------------------------
   GPG Key Fprint: 525F DBA7 1A62 E4C4 E642  DF95 384B B851 3CEF C10A
signature.asc (application/pgp-signature, 196 B)
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.13 (FreeBSD)

iEYEARECAAYFAkr0kr0ACgkQOEu4UTzvwQocdgCfel9iNo9PV3iooyhTaGJjjz37
yTUAn0DhnI0Upwc8AJM03ezxe/WJDX29
=D85o
-----END PGP SIGNATURE-----
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.