- 
    
Bug
 - 
    Resolution: Fixed
 - 
    
P2: Important
 - 
    6.5.0
 
- 
        67c6d77e5 (dev), e92460baa (dev), 3c6715b9d (6.5), df16995be (6.5)
 
Please find the attached reproducer and run it on Qt6.5.0.
Trying to add translation from CMakeLists.txt in subdirectory 'translations': CMake cannot find source file xxx.qm.
Trying to add translation from CMakeLists.txt in root (parent) subdirectory: works fine.
However, adding translation from subdirectory works in Qt6.4.x.
The issue seems to influence many other CMake commands that involves 'target', e.g., add shader or add resource.
| For Gerrit Dashboard: QTBUG-112841 | ||||||
|---|---|---|---|---|---|---|
| # | Subject | Branch | Project | Status | CR | V | 
| 472234,3 | CMake: Mark qm files as GENERATED in the target scope | dev | qt/qttools | Status: MERGED | +2 | 0 | 
| 472237,3 | CMake: Add note about CMake version requirements | dev | qt/qttools | Status: MERGED | +2 | 0 | 
| 472772,2 | CMake: Mark qm files as GENERATED in the target scope | 6.5 | qt/qttools | Status: MERGED | +2 | 0 | 
| 472773,2 | CMake: Add note about CMake version requirements | 6.5 | qt/qttools | Status: MERGED | +2 | 0 |