Bug #17516 Updated: overriding constants in config.w32.h.in
| From: | ssb@php.net | Date: | Thu, 13 Jun 2002 22:19:41 +0000 |
| Subject: | Bug #17516 Updated: overriding constants in config.w32.h.in | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-10410@lists.php.net to get a copy of this message | ||
ID: 17516
Updated by: ssb@php.net
Reported By: urs@php.net
-Status: Open
+Status: Assigned
Bug Type: Feature/Change Request
Operating System: Windows
PHP Version: 4.0CVS-2002-05-29
-Assigned To:
+Assigned To: ssb
Previous Comments:
------------------------------------------------------------------------
[2002-05-29 16:52:31] urs@php.net
While working with PEAR installer it occurred that the pear.ini setting
file got placed in a newly created directory c:\php4. This dir is
hardcoded in:
http://cvs.php.net/co.php/php4/main/config.w32.h.in
To respect other php installations like in c:\php or c:\programme\php
one need a feature to override the constants given by the php core:
http://www.php.net/manual/en/reserved.constants.core.php
Since scripts in PEAR are designed using these constants, and constants
are not variable, there is probably only one way to override these
values in config.w32.h.in e.g. like:
#define PHP_SYSCONFDIR ( (getenv("PHP_SYSCONFDIR") != "c:\\php4" ) ?
getenv("PHP_SYSCONFDIR" ) : "c:\\php4" )
This allows the user to configure its paths by hand through setting the
environment variables like:
c:\>set PHP_SYSCONFDIR=c:\php
I propose to do this switch for all path related constants in
config.w32.h.in [DIRECTORY_SEPARATOR, PHP_SYSCONFDIR,
DEFAULT_INCLUDE_PATH, PEAR_INSTALL_DIR, PEAR_EXTENSION_DIR,
PHP_EXTENSION_DIR, PHP_BINDIR, PHP_LIBDIR, PHP_DATADIR, PHP_SYSCONFDIR,
PHP_LOCALSTATEDIR, PHP_CONFIG_FILE_PATH].
-urs
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=17516&edit=1