php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #57596 configure script looks php_session.h in %/php/include
Submitted: 2007-03-28 13:49 UTC Modified: 2007-03-29 07:32 UTC
From: samuel at debian-ce dot org Assigned:
Status: Not a bug Package: memcache (PECL)
PHP Version: 4.4.2 OS: Ubuntu
Private report: No CVE-ID:
 [2007-03-28 13:49 UTC] samuel at debian-ce dot org

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-03-28 13:57 UTC] tony2001 at phpclub dot net
>But in Ubuntu the package php4-dev install it includes 
>on /usr/include/php4/ext/session

That's not something we can fix.
If they use patched PHP, you have to patch PECL/memcache accordingly.
 [2007-03-29 07:32 UTC] samuel at debian-ce dot org
Hmm, ok!

I was thinking in something like:

10a11,13
> PHP_ARG_WITH(dev-headers, specify path of php headers files,
> [  --with-dev-headers[=PATH]       specify path of php headers files], no, no)
>
73a77,78
>     elif test -f $PHP_DEV_HEADERS/ext/session/php_session.h; then
>       session_inc_path=$PHP_DEV_HEADERS


Then a user can specify in case like debian/ubuntu or when he compile and dont install on default places!

Thanks for attention.
 [2007-07-11 10:32 UTC] admin at kupke-mg dot de
Have the same Problem with a Debian Sarge (3.1)

My workaround:
 ln -s /usr/include/php4 /usr/include/php

Fixed things for me.
 [2007-10-17 07:55 UTC] hans at parse dot nl
"That's not something we can fix.
If they use patched PHP, you have to patch PECL/memcache accordingly."

What kind of BS reply is that?!

The configure script for memcache looks in some predefined locations which are based on assumption instead of using the *properly detected* location of the include files earlier in the configure script through php-config.

See here:

checking for PHP includes... -I/usr/lib/php4/include/php -I/usr/lib/php4/include/php/main -I/usr/lib/php4/include/php/TSRM -I/usr/lib/php4/include/php/Zend
[...]
checking for session includes... configure: error: Cannot find php_session.h

If the configure script would just check the locations returned by the PHP includes check, all would be fine.
 [2007-10-17 08:36 UTC] hans at parse dot nl
After some more digging i found out that the current config9.m4 already sort-of looks in the include dirs returned by php-config, only the problem is, the current approach only works for php5.

Memcache's config9.m4 uses the $phpincludedir m4 var which, afaik, is not available in php4 phpize (compare phpize.m4 between php5 and php4 and see what i mean)

One bit hackish way to fix it would be to add a check for:

${prefix}/include/php/ext/session/php_session.h
 
PHP Copyright © 2001-2014 The PHP Group
All rights reserved.
Last updated: Mon Apr 21 02:02:11 2014 UTC