Of course. It is called dynamic linking.
See the
dlopen man page for details. It even has an example program. In your case, you won't load
libm.so, but your own module. The modules you compile of course as dynamically loadable libraries.
Hope this helps,
Nominal Animal