# the static library c # # c.cpp looks like this: # int __declspec(dllexport) test() # { # return 9; # } lib c : c.cpp : static ; # the shared library lib a : c : shared ; # test executable # main.cpp looks like this: # # int __declspec(dllimport) test(); # # int main() # { # test(); # return 0; # } exe test : main.cpp a ;