Skip to content

Commit 64282a7

Browse files
XrXrtgross35
authored andcommitted
Build with -Werror=implicit-function-declaration
To prevent fail-fast in situations like rust-lang/rust#125619, where an upstream source compiles but creates a link error way downstream.
1 parent 4e1ec89 commit 64282a7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Diff for: build.rs

+2
Original file line numberDiff line numberDiff line change
@@ -327,6 +327,8 @@ mod c {
327327
// in https://github.com/rust-lang/compiler-rt/blob/c8fbcb3/cmake/config-ix.cmake#L19.
328328
cfg.flag_if_supported("-fomit-frame-pointer");
329329
cfg.define("VISIBILITY_HIDDEN", None);
330+
// Avoid implicitly creating references to undefined functions
331+
cfg.flag("-Werror=implicit-function-declaration");
330332
}
331333

332334
// int_util.c tries to include stdlib.h if `_WIN32` is defined,

0 commit comments

Comments
 (0)