[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#510957: lintian: CMake build error detection



Joerg Jaspert <joerg@ganneff.de> writes:

> would be nice if Lintian could have an E: level for an easy to detect
> FTBFS.  If there is a CMakeCache.txt file in the .diff.gz and as such in
> the build tree, cmake will simply refuse to build the package and
> outright fail:
>
> CMake Error: The current CMakeCache.txt directory
> /tmp/buildd/mysql-connector-cpp-1.0.2~20081215/CMakeCache.txt is
> different than the directory
> /home/rene/mysql-connector-cpp-1.0.2~20081215 where CMackeCache.txt was
> created. This may result in binaries being created in the wrong
> place. If you are not sure, reedit the CMakeCache.txt
> make: *** [configure-stamp] Error 1
>
> To not have a chance of too many false positives, I would suggest
> looking directly into the diff, so avoid upstream source. And do not
> count the error as soon as you find that filename anywhere in the rules
> file (that assumes the Maintainer takes care of it somehow).

This is fairly trivial to do if we don't look in debian/rules and a bit
harder to do if we do.  Before I write the code to scan debian/rules,
though, I wanted to check if you think there's some legitimate case where
someone would create or modify this file in the diff and then remove it in
debian/rules.  I can't think of one, and hence am leaning towards just
always flagging it as an error if that file is present in the diff.

-- 
Russ Allbery (rra@debian.org)               <http://www.eyrie.org/~eagle/>



Reply to: