While static link is possible solution it has it's own problems:
1) Not always static libraries exist/available
2) Link command for static linking can be significantly different, than link command for dynamic linking:
- when using dynamic link linker will track dependencies libraries by itself. for static link it's up to programmer to specify all needed libraries.
- for dynamic link libraries can be specified in any order, for static link order is important, and find right one can take time and efforts.
3) Many programs used plugins, i.e them use dlopen to load shared objects in the run time. Examples are any Qt, Gnome progra m and many others.
Even ls (at least when invoked with -l flag) use dlopen
As far as I know there is no way around dlopen (short of redesigning program)
If all mentioned above is not a problem for you, then go to the static link.
If not - there are alternatives.
Executable linked dynamically (as usual) and then used
to convert dynamically linked executable to the self-contained one.
Statifier is licensed under GPL, Ermine - commercial.
On the other hand Ermine works better than statifier on systems with