is there a macro symbol for strlen($LINUX_SOURCE_PATH)

jim.cromie at gmail.com jim.cromie at gmail.com
Wed Sep 4 17:42:01 EDT 2019


in the kernel, there are a lot of usages of __FILE__

this means that there are a lot of copies of fully rooted paths,
including all the varying ~/src/linux prefixes used by individual builders.

Id hazard a guess that something like __RELPATH_FILE__
would work in many cases and perhaps even be more readable
(by reducing long strings) in the generated output

Do the macros exist to cobble this together for compile-time ?
Does it warrant a short name ? either to wrap __FILE__ uses or replace them ?



More information about the Kernelnewbies mailing list