Skip to content
Commit bc6df812 authored by Masahiro Yamada's avatar Masahiro Yamada
Browse files

fixdep: parse Makefile more correctly to handle comments etc.



fixdep parses dependency files (*.d) emitted by the compiler.

*.d files are Makefiles describing the dependencies of the main source
file.

fixdep understands minimal Makefile syntax. It works well enough for
GCC and Clang, but not for rustc.

This commit improves the parser a little more for better processing
comments, escape sequences, etc.

My main motivation is to drop comments. rustc may output comments
(e.g. env-dep). Currentyly, rustc build rules invoke sed to remove
comments, but it is more efficient to do it in fixdep.

Signed-off-by: default avatarMasahiro Yamada <masahiroy@kernel.org>
Acked-by: default avatarMiguel Ojeda <ojeda@kernel.org>
Tested-by: default avatarMiguel Ojeda <ojeda@kernel.org>
parent 295d8398
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment