I have an application that uses the Mysql C-API and another library. The application is on a remote host and I must compile it using the -shared flag to use the Mysql C-API. My problem is I need to use the static version of the second library. Is it possible to compile an application with gcc that uses both shared and static libraries?