I try to compil from source PHP5.3.29 on Debian 9. The make command stopped in error at this step
LDFLAGS="-Wl,-rpath=/opt/OpenSSL/openssl-1.0.1u/lib,-rpath=/opt/CURL/curl-7.26.0/lib" make
.../...
(.text+0x5d7e): warning: the use of `tmpnam' is dangerous, better use `mkstemp'
/usr/bin/ld: warning: libssl.so.1.1, needed by /usr/lib/x86_64-linux-gnu/libpq.so, may conflict with libssl.so.1.0.0
/usr/bin/ld: warning: libssl.so.1.1, needed by /usr/lib/x86_64-linux-gnu/libpq.so, may conflict with libssl.so.1.0.0
/usr/bin/ld: warning: libssl.so.1.1, needed by /usr/lib/x86_64-linux-gnu/libpq.so, may conflict with libssl.so.1.0.0
/usr/bin/ld: warning: libssl.so.1.1, needed by /usr/lib/x86_64-linux-gnu/libpq.so, may conflict with libssl.so.1.0.0
/usr/bin/ld: /usr/lib/x86_64-linux-gnu/libc-client.a(osdep.o): undefined reference to symbol 'TLS_server_method@@OPENSSL_1_1_0'
//usr/lib/x86_64-linux-gnu/libssl.so.1.1: error adding symbols: DSO missing from command line
collect2: error: ld returned 1 exit status
Makefile:277: recipe for target 'sapi/fpm/php-fpm' failed
make: *** [sapi/fpm/php-fpm] Error 1
Like I compiled old version of OpenSSL and Curl. I suppect libpq.so is not old enough
# ls -l /usr/lib/x86_64-linux-gnu/libpq.so
lrwxrwxrwx 1 root root 12 Aug 9 23:22 /usr/lib/x86_64-linux-gnu/libpq.so -> libpq.so.5.9
I don't know how to find the source of libpq.so.4.x which is a PostgreSQL library.