Try omitting -Ctarget-feature=crt-static. It should probably not be combined with -Cprefer-dynamic.
-Ctarget-feature=crt-static
-Cprefer-dynamic