On Tue, Oct 10, 2023 at 12:16:55PM +0100, Ian McInerney via devel wrote: > On Tue, Oct 10, 2023 at 11:59 AM Neal Gompa <ngompa13@xxxxxxxxx> wrote: > > > Hey all, > > > > Recently, one of the folks working on packaging stuff in Fedora KDE > > nearly missed an issue caused by GCC emitting a warning about missing > > include dirs: > > > > > cc1plus: warning: /usr/include/qt6/QtCore/6.5.3: No such file or > > directory [-Wmissing-include-dirs] > > > cc1plus: warning: /usr/include/qt6/QtCore/6.5.3/QtCore: No such file or > > directory [-Wmissing-include-dirs] > > > > I did manage to figure out this meant we needed an additional build > > dependency (qt6-qtbase-private-devel, FYI), but it made me think if > > there's a reason this shouldn't be an error. > > > > If it's an error, then at least we can evaluate these things and > > ensure we have the right build inputs... > > > > Missing an include directory isn't necessarily the problem though, it is > the missing headers that aren't present when they are included that would > be - and that should trigger a build error for the missing file. What > advantage does failing on this warning provide that the failure on the > include file missing doesn't? The header file may be present in another directory, but as an older version that should not be used, resulting in building the wrong featureset. Last week I uncovered a bug in opensuse 15.4 where they had patched libtirpc to move its headers directly into /usr/include, but not correctly changed the pkg-config file which still pointed to the non-existant /usr/include/libtirpc. This case was harmless, as /usr/include is on the default search path, but it was none the less a genuine bug, and was caught due our code using -Werror=missing-include-dirs in CI. The reason for missing-include-dirs to not to be a build error by default though, is that I suspect there are plenty of apps which have sloppy build system setup that results in bogus dirs being added. With regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :| _______________________________________________ devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx Fedora Code of Conduct: https://docs.fedoraproject.org/en-US/project/code-of-conduct/ List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx Do not reply to spam, report it: https://pagure.io/fedora-infrastructure/new_issue