Commit 6d0e6ec
Fix race condition during gen_compat_def on filesystems w/o microsecond resolution
This fixes a rather obscure but difficult to track race condition which
can occur when the code is compiled on a file system without
microseconds ctime/mtime resolution.
Because gen_compat_def overwrites the same test.c for every
kbuild_test_compile() run, on fast systems this can happen in the same
second as the last test, causing make to skip the compilation (and thus
the whole test), leading to errors later during module build.
I think this was the cause for
#152 as I ran into the exact
same error.
This is also Debian Bug https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=972455
This commit here fixes this by adding -B to make to force it to rebuild
every thing every time and not use timestamps to optimize the build
process.
A different solution would be to create a different temporary directory
for each kbuild_test_compile() run, but I opted for the less invasive
change.1 parent adfc631 commit 6d0e6ec
1 file changed
+1
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
26 | 26 | | |
27 | 27 | | |
28 | 28 | | |
29 | | - | |
| 29 | + | |
30 | 30 | | |
31 | 31 | | |
32 | 32 | | |
| |||
0 commit comments