php-install Digest 27 Nov 2001 19:08:47 -0000 Issue 574
Topics (messages 5094 through 5099):
how can i use/install pear??
5094 by: tony
Re: when i try to run a php script it doesnt do anything
5095 by: tony
local configuration of PHP in CGI mode
5096 by: Fabien Salvi
Re: php with apxs and mysql on Darwin
5097 by: Erik Price
Relative path not parsing correctly in include()
5098 by: Sean Redmond
PHP install w/MySQL difference question
5099 by: Erik Price
Administrivia:
To subscribe to the digest, e-mail:
[EMAIL PROTECTED]
To unsubscribe from the digest, e-mail:
[EMAIL PROTECTED]
To post to the list, e-mail:
[EMAIL PROTECTED]
----------------------------------------------------------------------
--- Begin Message ---
thanks!
--
__________________
| ³Ô·¹²»³Ô²Ë |
| ʡǮ̸Áµ°® |
------------------
--- End Message ---
--- Begin Message ---
try..r u sure ur php script is right??u can use <?php phpinfo(); ?>to test
that!!
--
__________________
| ????? |
| ????? |
------------------
"Francis Medina" <[EMAIL PROTECTED]>
??????:001001c17546$2fe54680$[EMAIL PROTECTED]
i am running Apache 1.3.22, Win98 , i install php406-installer..
but when i run a php script it give a blank page
i put :
ScriptAlias /php/ "c:/php/"
AddType application/x-httpd-php .php
Action application/x-httpd-php "/php/php.exe"
in the Apache httpd.con , but the manual help dont tell where to put the
instruction
i am stuck, i need help, this is the 3 mail iam sending you,
i dont undestand why something so simply it doesnt work, and why it doesnt
configuere the Apache conf . file
its not part of the same project.????
--- End Message ---
--- Begin Message ---
Hello,
I would like to have a local configuration in PHP when it is in CGI
mode.
When in apache module, it's not difficult, we just have to php_value for
example. See here :
http://www.php.net/manual/en/configuration.php
But, in CGI mode, I can't find the way to do it.
I try with Setenv, to set an environment variable with php
configuration, but without success :(
The only method I find, but it's very ugly, is to change php
configuration file name in the executable with hexedit, so I have
another configuration file with local configuration I want...
Does some have a better idea ?
Thanks in advance.
-------------
Fabien SALVI Centre de Ressources Informatiques
Archamps, France -- http://www.cri74.org
PingOO GNU/linux distribution : http://www.pingoo.org
--- End Message ---
--- Begin Message ---
On Tuesday, November 27, 2001, at 12:01 AM, Chris wrote:
> I had a similar *mis*understanding when I attempted to install
> *other* modules with the PHP /configure/install.
>
> Your line (where mysql is concerned) should read:
> --with-mysql=/usr/local *not*
> --with-mysql=/usr/local/mysql as you used.
>
> That *should* get it for you. :-)
>
>
> Best wishes,
> Chris
>
Chris,
I tried it. For some reason, it error'd during the ./configure command.
localhost:~/tmp/apache_mod_php-6-2/php$ ./configure --with-xml
--with-zlib --with-apxs=/usr/sbin/apxs --with-mysql=/usr/local
creating cache ./config.cache
... ( ./configure output omitted ) ...
checking for MySQL support... yes
configure: error: Cannot find header files under /usr/local
localhost:~/tmp/apache_mod_php-6-2/php$
This is strange, because here is what I get when I choose '--with-
mysql=/usr/local/mysql':
localhost:~/tmp/apache_mod_php-6-2/php$ rm config.cache
localhost:~/tmp/apache_mod_php-6-2/php$ make clean
make: *** No rule to make target `clean'. Stop.
localhost:~/tmp/apache_mod_php-6-2/php$ ./configure --with-xml
--with-zlib --with-apxs=/usr/sbin/apxs --with-mysql=/usr/local/mysql
creating cache ./config.cache
... ( ./configure output omitted ) ...
checking for MySQL support... yes
checking for MySQL UNIX socket... /tmp/mysql.sock
... ( more ./configure output omitted ) ...
updating cache ./config.cache
loading cache ./config.cache
Generating files
checking for working mkdir -p... yes
creating config_vars.mk
updating cache ./config.cache
creating ./config.status
creating php4.spec
creating Zend/Makefile
creating main/build-defs.h
creating pear/scripts/pear
creating pear/scripts/phpize
creating pear/scripts/php-config
creating TSRM/Makefile
creating main/php_config.h
creating sapi/Makefile
creating ext/Makefile
creating Makefile
creating pear/Makefile
creating main/Makefile
creating ext/zlib/Makefile
creating ext/mysql/Makefile
creating ext/pcre/Makefile
creating ext/pcre/pcrelib/Makefile
creating ext/posix/Makefile
creating ext/session/Makefile
creating ext/standard/Makefile
creating ext/xml/Makefile
creating ext/xml/expat/Makefile
creating ext/xml/expat/xmlparse/Makefile
creating ext/xml/expat/xmltok/Makefile
creating sapi/apache/Makefile
creating regex/Makefile
creating number.c
creating number.h
creating main/internal_functions.c
+--------------------------------------------------------------------+
| License: |
| This software is subject to the PHP License, available in this |
| distribution in the file LICENSE. By continuing this installation |
| process, you are bound by the terms of this license agreement. |
| If you do not agree with the terms of this license, you must abort |
| the installation process at this point. |
+--------------------------------------------------------------------+
Thank you for using PHP.
localhost:~/tmp/apache_mod_php-6-2/php$
See that? It recognized the MySQL headers, and successfully completed
the ./configure operation, which is great. But my problem, which is
that the 'make' operation does not create the libphp4.so file (or
whatever), still exists.
Does anyone have any advice?
Thanks,
Erik
--- End Message ---
--- Begin Message ---
I'm trying to install Aolserver 3.4.2 and PHP 4.0.6, but on the statement
include "../src/load_prefs.php";
The server segfaults. Perhaps the server shouldn't crash but the problem is
that ".." is being interpreted as:
/usr/local/aolserver-3.4.2/servers/webmail/pages/squirrelmail-1.2.0-rc2/src/../src/load_prefs.php
rather than:
/usr/local/aolserver-3.4.2/servers/webmail/pages/squirrelmail-1.2.0-rc2/src/load_prefs.php
I never had a problem with Aolserver 3.0 + PHP 4.0.6 on a machine running
RedHat 6.2. This is cropping up with RedHat 7.2 + PHP 4.0.6 using either
Aolserver 3.4.2 or Aolserver 3.0. Is there some problem between RedHat 7.2
and PHP 4.0.6 (glibc maybe? I'm using glib-2.2.4-19).
Here is the backtrace with Aolserver 3.4.2:
[New Thread 5126 (LWP 12186)]
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 5126 (LWP 12186)]
0x4013fa38 in ___lxstat64 (vers=3, name=0x403cd01c "/usr", buf=0x403ce04c)
at ../sysdeps/unix/sysv/linux/lxstat64.c:52
52 ../sysdeps/unix/sysv/linux/lxstat64.c: No such file or directory.
in ../sysdeps/unix/sysv/linux/lxstat64.c
(gdb) bt
#0 0x4013fa38 in ___lxstat64 (vers=3, name=0x403cd01c "/usr", buf=0x403ce04c)
at ../sysdeps/unix/sysv/linux/lxstat64.c:52
#1 0x400afb7c in canonicalize (
name=0x8280b90
"/usr/local/aolserver-3.4.2/servers/webmail/pages/squirrelmail-1.2.0-rc2/src/../src/load_prefs.php",
resolved=0x403ce10c "")
at canonicalize.c:150
#2 0x402cd659 in virtual_file_ex (state=0x403cf13c,
path=0x83d3704 "../src/load_prefs.php", verify_path=0)
at tsrm_virtual_cwd.c:299
#3 0x402cdc1f in virtual_fopen (path=0x83d3704 "../src/load_prefs.php",
mode=0x402e1c47 "rb") at tsrm_virtual_cwd.c:497
#4 0x40246224 in php_fopen_and_set_opened_path (
path=0x83d3704 "../src/load_prefs.php", mode=0x402e1c47 "rb",
opened_path=0x403d03b4) at fopen_wrappers.c:235
#5 0x40246859 in php_fopen_with_path (
filename=0x83d3704 "../src/load_prefs.php", mode=0x402e1c47 "rb",
path=0x402e307b ".:/usr/local/lib/php", opened_path=0x403d03b4)
at fopen_wrappers.c:391
#6 0x40246a88 in php_fopen_url_wrapper (
path=0x83d3704 "../src/load_prefs.php", mode=0x402e1c47 "rb", options=1,
issock=0x403d0280, socketd=0x403d0284, opened_path=0x403d03b4)
at fopen_wrappers.c:470
#7 0x40244481 in php_fopen_wrapper_for_zend (
filename=0x83d3704 "../src/load_prefs.php", opened_path=0x403d03b4)
at main.c:477
#8 0x4023bd7e in open_file_for_scanning ()
from /usr/local/aolserver/bin/libphp4.so
#9 0x4023c124 in compile_file () from /usr/local/aolserver/bin/libphp4.so
#10 0x4023c2c4 in compile_filename () from /usr/local/aolserver/bin/libphp4.so
#11 0x40226c66 in execute (op_array=0x8393538, executor_globals=0x821b490)
at ./zend_execute.c:2028
#12 0x402249f3 in execute (op_array=0x8223780, executor_globals=0x821b490)
at ./zend_execute.c:1544
#13 0x402249f3 in execute (op_array=0x827dfa0, executor_globals=0x821b490)
at ./zend_execute.c:1544
#14 0x402249f3 in execute (op_array=0x8364b08, executor_globals=0x821b490)
at ./zend_execute.c:1544
#15 0x402249f3 in execute (op_array=0x8254224, executor_globals=0x821b490)
at ./zend_execute.c:1544
#16 0x40232dbd in zend_execute_scripts (type=8, compiler_globals=0x82301e0,
executor_globals=0x821b490, file_count=3) at zend.c:752
#17 0x40245967 in php_execute_script (primary_file=0x403dc6cc,
compiler_globals=0x82301e0, executor_globals=0x821b490,
core_globals=0x828dac0) at main.c:1206
#18 0x40243732 in php_ns_module_main (ns_context=0x828e950,
sapi_globals=0x826fc50) at aolserver.c:434
#19 0x4024397f in php_ns_request_handler (context=0x817a638, conn=0x8192118)
at aolserver.c:519
#20 0x08077bb7 in Ns_ConnRunRequest (conn=0x8192118) at op.c:196
#21 0x0807e2c2 in ConnRun (connPtr=0x8192118) at serv.c:882
#22 0x0807dc10 in NsConnThread (arg=0x8261fb8) at serv.c:671
#23 0x0811833b in NsThreadMain (arg=0x8261fc8) at thread.c:228
#24 0x4002ec6f in pthread_start_thread (arg=0x403dcbe0) at manager.c:284
#25 0x4002ed5f in pthread_start_thread_event (arg=0x403dcbe0) at manager.c:308
Thanks
Sean Redmond
Brooklyn Museum of Art
--- End Message ---
--- Begin Message ---
> Hello,
>
> [The contents of this email contain quite an annoying amount of output
> from the command line, but please note that I have deleted most of the
> unnecessary output and tried to comment the parts that I felt were
> necessary.]
>
> I am curious as to what the difference will be if I choose to install
> PHP4 with MySQL functionality, using only the built-in MySQL support.
> If I specify the /path/to/mysql in my ./configure option --with-mysql,
> then I get the following output:
>
> localhost:~/tmp/apache_mod_php-6-2/php$ ./configure --with-xml
> --with-zlib --with-apxs=/usr/sbin/apxs --with-mysql=/usr/local/mysql
> creating cache ./config.cache
> ... ( for sake of space, most ./configure output omitted ) ...
>
> Generating files
> checking for working mkdir -p... yes
> creating config_vars.mk
> updating cache ./config.cache
> creating ./config.status
> creating php4.spec
> creating Zend/Makefile
> creating main/build-defs.h
> creating pear/scripts/pear
> creating pear/scripts/phpize
> creating pear/scripts/php-config
> creating TSRM/Makefile
> creating main/php_config.h
> creating sapi/Makefile
> creating ext/Makefile
> creating Makefile
> creating pear/Makefile
> creating main/Makefile
> creating ext/zlib/Makefile
> creating ext/mysql/Makefile
> creating ext/pcre/Makefile
> creating ext/pcre/pcrelib/Makefile
> creating ext/posix/Makefile
> creating ext/session/Makefile
> creating ext/standard/Makefile
> creating ext/xml/Makefile
> creating ext/xml/expat/Makefile
> creating ext/xml/expat/xmlparse/Makefile
> creating ext/xml/expat/xmltok/Makefile
> creating sapi/apache/Makefile
> creating regex/Makefile
> creating number.c
> creating number.h
> creating main/internal_functions.c
> +--------------------------------------------------------------------+
> | License: |
> | This software is subject to the PHP License, available in this |
> | distribution in the file LICENSE. By continuing this installation |
> | process, you are bound by the terms of this license agreement. |
> | If you do not agree with the terms of this license, you must abort |
> | the installation process at this point. |
> +--------------------------------------------------------------------+
>
> Thank you for using PHP.
>
> localhost:~/tmp/apache_mod_php-6-2/php$
>
>
>
> But when I 'make' PHP, I get the following warnings (after it is done
> compiling):
>
>
>
> *** Warning: This library needs some functionality provided by
> -lmysqlclient.
> *** I have the capability to make that library automatically link in
> when
> *** you link to this library. But I can only do this if you have a
> *** shared version of the library, which you do not appear to have.
>
> *** Warning: This library needs some functionality provided by
> -lmysqlclient.
> *** I have the capability to make that library automatically link in
> when
> *** you link to this library. But I can only do this if you have a
> *** shared version of the library, which you do not appear to have.
>
> *** Warning: libtool could not satisfy all declared inter-library
> *** dependencies of module libphp4. Therefore, libtool will create
> *** a static module, that should work as long as the dlopening
> *** application is linked with the -dlopen flag.
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libZend.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libsapi.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libmain.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libregex.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libzlib.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libmysql.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libpcre.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libposix.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libsession.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libstandard.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libxml.al
> ~/tmp/apache_mod_php-6-2/php/.libs/libphp4.lax/libtsrm.al
> ~/tmp/apache_mod_php-6-2/php/.libs
> Making all in pear
> localhost:~/tmp/apache_mod_php-6-2/php$
>
>
>
> So now it seems like I'm in the green -- it says that 'libtool will
> create a static module' for me. But when I try to 'make install', I
> get an error.
>
>
>
> localhost:~/tmp/apache_mod_php-6-2/php$ sudo make install
> password:
> ... ( for sake of space, most 'make install' output omitted ) ...
> Making install in .
> /Users/eprice/tmp/apache_mod_php-6-2/php/build/shtool mkdir -p
> "/usr/libexec/httpd" && /usr/sbin/apxs -S
> LIBEXECDIR="/usr/libexec/httpd" -i -a -n php4 libs/libphp4.so
> [activating module `php4' in /etc/httpd/httpd.conf]
> cp libs/libphp4.so /usr/libexec/httpd/libphp4.so
> cp: libs/libphp4.so: No such file or directory
> apxs:Break: Command failed with rc=1
> make[1]: *** [install-sapi] Error 1
> make: *** [install-recursive] Error 1
> localhost:~/tmp/apache_mod_php-6-2/php$
>
>
>
> There seems not to have been a 'libphp4.so' to copy into
> '/usr/libexec/httpd/libphp4.so'. I posted to this list earlier, asking
> for advice on making this 'libphp4.so' file, but it seems no one knew
> the answer. So, now I am wondering what the net effect would be of not
> specifying any directory argument to the '--with-mysql' configure
> option. In other words, I would do (note the change in the ./configure
> options):
>
>
>
> localhost:~/tmp/apache_mod_php-6-2/php$ ./configure --with-xml
> --with-zlib --with-apxs=/usr/sbin/apxs --with-mysql
> creating cache ./config.cache
> ... ( for sake of space, most ./configure output omitted ) ...
> +--------------------------------------------------------------------+
> | *** WARNING *** |
> | |
> | You chose to compile PHP with the built-in MySQL support. If you |
> | are compiling a server module, and intend to use other server |
> | modules that also use MySQL (e.g, mod_auth_mysql, PHP 3.0, |
> | mod_perl) you must NOT rely on PHP's built-in MySQL support, and |
> | instead build it with your local MySQL support files, by adding |
> | --with-mysql=/path/to/mysql to your configure line. |
> +--------------------------------------------------------------------+
> | License: |
> | This software is subject to the PHP License, available in this |
> | distribution in the file LICENSE. By continuing this installation |
> | process, you are bound by the terms of this license agreement. |
> | If you do not agree with the terms of this license, you must abort |
> | the installation process at this point. |
> +--------------------------------------------------------------------+
>
> Thank you for using PHP.
>
> localhost:~/tmp/apache_mod_php-6-2/php$
>
>
>
> I need to get PHP and MySQL running by the end of the day or my boss is
> going to kill me. If I just use this form of PHP (using built-in MySQL
> support), will I be able to re-compile the version with the appropriate
> /path/to/mysql at a later date? Will the PHP code that I write for
> this (built-in MySQL) version of PHP4 work in a later version of PHP4
> where I have indeed specified a directory?
>
> Thanks to any who can help me -- and I apologize to those who are
> becoming annoyed with these questions! Once I get this up and running
> I will do my best to never bother anyone again!
>
>
> -- Erik
--- End Message ---