I am trying to compile Linux kernel on Windows using Cygwin. When I try make distclean it gives me the following error:
make distclean
make[1]: *** Documentation/Kbuild: Is a directory. Stop.
Makefile:1188: recipe for target '_clean_Documentation' failed
make: *** [_clean_Documentation] Error 2
Had the similar problem.
As was mentioned by @Daniel Griscom and @Sniffleh, it really looks like the problem due to a case-insensitive filesystem, and fsutil really can resolve this problem.
Let me share some useful commands:
If fsutil.exe file SetCaseSensitiveInfo YourDestinationFolder enable don't work, try to
use Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Windows-Subsystem-Linux in PowerShell.
fsutil can't enable case sensitive recursively, so you can use (Get-ChildItem -Recurse -Directory).FullName | ForEach-Object {fsutil.exe file setCaseSensitiveInfo $_ enable} in PowerShell.
According to unrouted.io/2016/08/09/docker-osx-linux-kernel-building it's due to a case-insensitive filesystem (which Windows is, as is macOS).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With