<table><tr><td style="">rjvbb updated this revision to Diff 45567.<br />rjvbb added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D16894">View Revision</a></tr></table><br /><div><div><p>A simpler version, setting CMAKE_<LANG>_FLAGS directly (also fixes a persistence error in my previous implementation).</p>

<p>I've thought some more about "why not just use check_<lang>_compiler_flag everywhere". I think that the risk with using a built-in function is that future developers or maintainers may think to be smart and replace them with built-in ID+version checking. Because we know since what version which compiler supports a given flag, right? Providing a dedicated function should reduce that risk, if not only because of the comments it comes with.</p>

<p>Ideally there should probably also be a version that accepts multiple flags; would that be possible with cmake's language?</p></div></div><br /><div><strong>CHANGES SINCE LAST UPDATE</strong><div><a href="https://phabricator.kde.org/D16894?vs=45513&id=45567">https://phabricator.kde.org/D16894?vs=45513&id=45567</a></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D16894">https://phabricator.kde.org/D16894</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>kde-modules/KDECompilerSettings.cmake<br />
kde-modules/KDEFrameworkCompilerSettings.cmake</div></div></div><br /><div><strong>To: </strong>rjvbb, Build System<br /><strong>Cc: </strong>apol, kde-frameworks-devel, kde-buildsystem, Build System, michaelh, ngraham, bruns<br /></div>