compile ngx_resty to statically link some libs?

dannynoonan nginx-forum at nginx.us
Tue Nov 15 02:30:27 UTC 2011


Hey agentzh, could you provide tips on how I could cut down this list of
dynamically linked libs:

[david at dev-3 ngx_openresty-1.0.8.26]$ ldd
/usr/local/encap/nginx-resty-1.0.8.26/nginx/sbin/nginx 
	linux-vdso.so.1 =>  (0x00007fff079fd000)
	libpthread.so.0 => /lib64/libpthread.so.0 (0x0000003aac200000)
	libcrypt.so.1 => /lib64/libcrypt.so.1 (0x0000003e08a00000)
	libssl.so.10 => /usr/lib64/libssl.so.10 (0x00000033d9c00000)
	libdrizzle.so.0 => /usr/lib64/libdrizzle.so.0 (0x00007fd4bcdf1000)
	libm.so.6 => /lib64/libm.so.6 (0x0000003e12000000)
	libpcre.so.0 => /lib64/libpcre.so.0 (0x0000003710800000)
	libcrypto.so.10 => /lib64/libcrypto.so.10 (0x0000003e13400000)
	libdl.so.2 => /lib64/libdl.so.2 (0x0000003e11000000)
	libz.so.1 => /lib64/libz.so.1 (0x0000003e11c00000)
	libc.so.6 => /lib64/libc.so.6 (0x0000003e10c00000)
	/lib64/ld-linux-x86-64.so.2 (0x0000003e10800000)
	libfreebl3.so => /lib64/libfreebl3.so (0x0000003e08e00000)
	libgssapi_krb5.so.2 => /lib64/libgssapi_krb5.so.2 (0x00000033d9400000)
	libkrb5.so.3 => /lib64/libkrb5.so.3 (0x00000033d9800000)
	libcom_err.so.2 => /lib64/libcom_err.so.2 (0x00000033d9000000)
	libk5crypto.so.3 => /lib64/libk5crypto.so.3 (0x000000374a800000)
	libkrb5support.so.0 => /lib64/libkrb5support.so.0 (0x000000374a000000)
	libkeyutils.so.1 => /lib64/libkeyutils.so.1 (0x0000003e13800000)
	libresolv.so.2 => /lib64/libresolv.so.2 (0x0000003e12c00000)
	libselinux.so.1 => /lib64/libselinux.so.1 (0x0000003749c00000)


Specifically, I'd really like to remove libdrizzle as a dependency on
the target machine and just have the compile pull it in at link time.

Posted at Nginx Forum: http://forum.nginx.org/read.php?2,218343,218343#msg-218343



More information about the nginx mailing list