| Summary: | [WPE] Fix for non-unified builds with ACCESSIBILITY=OFF | ||||||||
|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Pablo Saavedra <psaavedra> | ||||||
| Component: | WebCore Misc. | Assignee: | Pablo Saavedra <psaavedra> | ||||||
| Status: | RESOLVED FIXED | ||||||||
| Severity: | Normal | CC: | aboxhall, andresg_22, annulen, aperez, apinheiro, cdumez, cfleizach, cgarcia, changseok, darin, dmazzoni, esprehn+autocc, ews-watchlist, gyuyoung.kim, jcraig, jdiggs, mifenton, ryuan.choi, samuel_white, sergio, webkit-bug-importer, wenson_hsieh, youennf | ||||||
| Priority: | P2 | Keywords: | InRadar | ||||||
| Version: | WebKit Nightly Build | ||||||||
| Hardware: | Unspecified | ||||||||
| OS: | Unspecified | ||||||||
| Attachments: |
|
||||||||
|
Description
Pablo Saavedra
2022-02-02 09:31:07 PST
Created attachment 450660 [details]
patch
Created attachment 450661 [details]
patch
This solution is fine.
But I have a slight preference for solving as many of these problems as possible in C++ headers rather than in CMake. For example, we could have this code in one of the platform headers:
#if !ENABLED(ACCESSIBILITY)
#undef USE_ATK
#undef USE_ATSPI
#endif
Then we would not have to be careful about those settings in the build/make environment because the header would fix it. My view is that generally speaking our main implementation language is C++, and we should only do the things in the build system that cannot be cleanly done with C++ code.
(In reply to Darin Adler from comment #3) > This solution is fine. > > But I have a slight preference for solving as many of these problems as > possible in C++ headers rather than in CMake. For example, we could have > this code in one of the platform headers: > > #if !ENABLED(ACCESSIBILITY) > #undef USE_ATK > #undef USE_ATSPI > #endif > > Then we would not have to be careful about those settings in the build/make > environment because the header would fix it. My view is that generally > speaking our main implementation language is C++, and we should only do the > things in the build system that cannot be cleanly done with C++ code. Sounds reasonable and Normally I might tend to agree with you and found your suggestion much more convenient. However those USE_ATK/USE_ATSPI are also used by other .cmake files like here: ./WebCore/PlatformWPE.cmake if (USE_ATSPI) set(WebCore_AtspiInterfaceFiles ... In summary, if we don't set those definitions early in the Source/cmake/OptionsWPE.cmake then we could generate again inconsistencies because the differences between the values of those definitions in the cmake and then in the .h .cpp sources. Comment on attachment 450661 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=450661&action=review > Source/WebCore/ChangeLog:3 > + [WPE] Fix for non-unified builds with ACCESSIBILITY=OFF Why is this wpe specific? Committed r289029 (246737@main): <https://commits.webkit.org/246737@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 450661 [details]. |