Skip to content

Instantly share code, notes, and snippets.

@bcremer
Last active May 11, 2023 14:39
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bcremer/7be474bcb0a44d33d987 to your computer and use it in GitHub Desktop.
Save bcremer/7be474bcb0a44d33d987 to your computer and use it in GitHub Desktop.
Compile Minimal Version of PHP used for Lint-Check legacy code
mkdir source
cd source
wget http://museum.php.net/php5/php-5.2.17.tar.gz
tar xvf php-5.2.17.tar.gz
cd php-5.2.17
./configure --disable-all --enable-static --enable-cli
make
cp sapi/cli/php ~/bin/php5.2.17-x64-static
@bcremer
Copy link
Author

bcremer commented Mar 27, 2015

$ sapi/cli/php -v 
PHP 5.2.17 (cli) (built: Mar 27 2015 09:35:54) 
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.2.0, Copyright (c) 1998-2010 Zend Technologies
$ ./sapi/cli/php -m
[PHP Modules]
date
Reflection
standard

[Zend Modules]
$ ldd sapi/cli/php
    linux-vdso.so.1 (0x00007ffe557ae000)
    libcrypt.so.1 => /usr/lib/libcrypt.so.1 (0x00007f465251d000)
    librt.so.1 => /usr/lib/librt.so.1 (0x00007f4652315000)
    libresolv.so.2 => /usr/lib/libresolv.so.2 (0x00007f46520fe000)
    libm.so.6 => /usr/lib/libm.so.6 (0x00007f4651df9000)
    libdl.so.2 => /usr/lib/libdl.so.2 (0x00007f4651bf5000)
    libnsl.so.1 => /usr/lib/libnsl.so.1 (0x00007f46519dd000)
    libc.so.6 => /usr/lib/libc.so.6 (0x00007f465163a000)
    libpthread.so.0 => /usr/lib/libpthread.so.0 (0x00007f465141d000)
    /lib64/ld-linux-x86-64.so.2 (0x00007f4652754000)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment