We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 0218418 + 9975ad0 commit d5d7b3bCopy full SHA for d5d7b3b
src/rustc/back/link.rs
@@ -637,6 +637,11 @@ fn link_binary(sess: session,
637
// and binutils 2.22+ won't add them automatically
638
if sess.targ_cfg.os == session::os_linux {
639
cc_args += ["-lrt", "-ldl"];
640
+
641
+ // LLVM implements the `frem` instruction as a call to `fmod`,
642
+ // which lives in libm. Similar to above, on some linuxes we
643
+ // have to be explicit about linking to it. See #2510
644
+ cc_args += ["-lm"];
645
}
646
647
if sess.targ_cfg.os == session::os_freebsd {
0 commit comments