Confusion regarding PHP compile error
| From: | Chris Howells | Date: | Mon, 05 Mar 2001 18:43:59 +0000 |
| Subject: | Confusion regarding PHP compile error | ||
| Groups: | php.install | ||
| Request: | Send a blank email to php-install+get-2269@lists.php.net to get a copy of this message | ||
Hello,
I'm on a Mandrake 7.0 system, running kernel 2.4.2. While attempting the
compile PHP 4.0.3pl1, I'm getting this familiar message.
microtime.c: In function `php_if_getrusage':
microtime.c:97: storage size of `usg' isn't known
microtime.c:100: `RUSAGE_SELF' undeclared (first use in this function)
microtime.c:100: (Each undeclared identifier is reported only once
microtime.c:100: for each function it appears in.)
microtime.c:106: `RUSAGE_CHILDREN' undeclared (first use in this
function)
make[3]: *** [microtime.lo] Error 1
make[3]: Leaving directory
`/home/source/web_and_database/php-4.0.3pl1/ext/standard'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory
`/home/source/web_and_database/php-4.0.3pl1/ext/standard'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory
`/home/source/web_and_database/php-4.0.3pl1/ext'
make: *** [all-recursive] Error 1
I thought I knew the cause of this, since I saw it before while
attempting to compile PHP under a 2.2 kernel.
However, I have checked my /usr/include/linux symlink, and this appears
to be correct, so I do not understand why I am getting the error. I hope
that this illustrates this:
[chris@localhost chris]$ uname -sr
Linux 2.4.2
[chris@localhost chris]$ ls -l /usr/include/linux
lrwxrwxrwx 1 root root 26 Jan 7 16:13 /usr/include/linux ->
../src/linux/include/linux/
[chris@localhost chris]$ ls -l /usr/src/linux
lrwxrwxrwx 1 root root 11 Feb 24 20:00 /usr/src/linux ->
linux-2.4.2/
Anybody any ideas what's causing this? Could it be that I'm running a
2.4 rather than 2.2 kernel? I do have the glibc-devel packages
installed.
I notice that the README for 2.4 says:
Do NOT use the /usr/src/linux area! This area has a (usually
incomplete) set of kernel headers that are used by the library header
files. They should match the library, and not get messed up by
whatever the kernel-du-jour happens to be.
Whilst the README for 2.2 says:
- If you install the full sources, do a
cd /usr/src
gzip -cd linux-2.2.XX.tar.gz | tar xfv -
to get it all put in place. Replace "XX" with the version number of the
latest kernel.
Cheers,
--
Chris Howells
E-Mail: chrish@gmx.co.uk
ICQ: 93699029
Web: http://www.chowells.uklinux.net