Fixes Qt5LinguistToolsMacros file extension bug
authorLuís Pereira <luis.artur.pereira@gmail.com>
Tue, 4 Nov 2014 20:14:44 +0000 (12:14 -0800)
committerLuís Pereira <luis.artur.pereira@gmail.com>
Tue, 4 Nov 2014 20:14:44 +0000 (12:14 -0800)
commita506a0ece4809d5b68cf4a1e8b1f29ec22b4252c
treef1582f11ce6c8b5a649b9413b515d566829b475a
parentf54f037cfb6d82ff76b1f581afd70c0bf0b43eec
Fixes Qt5LinguistToolsMacros file extension bug

get_filename_component and name_we are used get the base of the
translations filename. But, NAME_WE, takes everything after first dot as
the file extension. Which means that two files:
lxqt-config-session_zh_CN.ts
lxqt-config-session_zh_CN.GB2312.ts
will have the same basename(lxqt-config-session_zh_CN) which is just plain
wrong, for our purposes. This wrong computation leads to an target names
collision that least to cmake configure errors.

Just replaced get_filename_component and NAME_WE to get a proper basename.
cmake/modules/LXQtTranslateTs.cmake
cmake/modules/Qt5LinguistToolsMacros.cmake [deleted file]
cmake/modules/Qt5PatchedLinguistToolsMacros.cmake [new file with mode: 0644]