Fix for static linking

This is a small bugfix for statically linking on Windows against various platforms and plugins so they reference the proper EXPORT symbols. It slightly overloads the semantics of ${EXTRA_COMMPILE_FLAGS} but it beats adding in staticTarget/CMakeLists.txt of every target.