Description:
The mysql_config tool currently outputs the library path required for building, but the options output are build-time paths only.
It would be useful if mysql_config could output a suitable option for runtime path linking for executables (the -R option) in addition to, or as an alternative to the current build time linking.
Although the request is specifically for Solaris, other platforms may also find this useful.
How to repeat:
Run mysql_config:
Usage: /bin/mysql_config [OPTIONS]
Options:
--cflags [-I/opt/mysql/mysql/include -m64 -mtune=k8 -DMY_ATOMIC_MODE_RWLOCKS -DHAVE_RWLOCK_T -DUNIV_SOLARIS]
--include [-I/opt/mysql/mysql/include]
--libs [-m64 -O2 -mtune=k8 -static-libgcc -L/opt/mysql/mysql/lib -lmysqlclient -lz -lrt -lgen -lsocket -lnsl -lm]
--libs_r [-m64 -O2 -mtune=k8 -static-libgcc -L/opt/mysql/mysql/lib -lmysqlclient_r -lz -lpthread -lthread -lrt -lgen -lsocket -lnsl -lm -lpthread -lthread]
--socket [/tmp/mysql.sock]
--port [0]
--version [6.0.4-alpha]
--libmysqld-libs [-m64 -O2 -mtune=k8 -static-libgcc -L/opt/mysql/mysql/lib -lmysqld -lz -lpthread -lthread -lrt -lgen -lsocket -lnsl -lm -lpthread -lthread -lrt]
Suggested fix:
A -R /opt/mysql/mysql/lib option would need to be output for the --libs option, perhaps optionally with a specific rpath setting.