#1002451 lintian: False positive file-references-package-build-path

Package:
lintian
Source:
lintian
Submitter:
Jose Luis Blanco Claraco
Date:
2021-12-27 13:51:03 UTC
Severity:
normal
#1002451#5
Date:
2021-12-22 09:58:01 UTC
From:
To:
Dear Maintainer,

I found a false positive report of file-references-package-build-path for a C++ header file
included in a package, which does not contain any path at all.
The string detected by data/files/build-path-regex in our case is inside this C++ comment:

    /* Defined only if MRPT is being build/was built with precompiled
       headers enabled */

I know it would be pretty complicated to discard C++ comments with a simple regex, but
a possible solution is to change the most generic regex:

    ^build/

to something more specific capturing names like real build paths, for example:
`build/mrpt-mtM7nO/` => `build/[:alpha:]*-[:alpha:]{6}` or alike?

Thanks,

#1002451#8
Date:
2021-12-27 13:46:28 UTC
From:
To:
FWIW, that would be a sbuild-specific solution, and even in sbuild it's
a configurable parameter, so it wouldn't be an appropriate solution.