Update examples
.lo requires -c
Fix for coverity
Fix for coverity (warn if mkdir fails)
Don't warn if the dir already exists
Fix for coverity (may pass NULL char pointer to strstr)
Fix for coverity (don't leak memory in add_rpath_noinstall)
Fix for coverity (don't leak memory if we can't find the library
Fix for coverity (don't leak memory if the object doesn't exist)
Fix for coverity (fix cleanup_tmp_dir so it doesn't leak directory handles)
Fix for coverity (fix load_install_path so it doesn't leak memory if passed a non absolute path)
Fix for coverity (fix run command so it doesn't leak memory allocated for the command)
Don't leak memory on run_mode
Fix const warning in jlibtool
Fix for coverity (fix potential buffer overflow in cleanup_tmp_dir)
Fix for coverity (potential segv for argument names over 49 bytes in jlibtool)
Fix for coverity (potential segv for very long libpaths in run_mode)
Remove dead code

Closes Coverity #982076
d_namlen is BSD, not posix
Use sizeof instead of strlen