<html>
<body>
<div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
<table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 solid;">
<tr>
<td>
This is an automatically generated e-mail. To reply, visit:
<a href="https://git.reviewboard.kde.org/r/117823/">https://git.reviewboard.kde.org/r/117823/</a>
</td>
</tr>
</table>
<br />
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<p style="margin-top: 0;">On May 1st, 2014, 11:58 a.m. CEST, <b>Alex Merry</b> wrote:</p>
<blockquote style="margin-left: 1em; border-left: 2px solid #d0d0d0; padding-left: 10px;">
<table width="100%" border="0" bgcolor="white" style="border: 1px solid #C0C0C0; border-collapse: collapse; margin: 2px padding: 2px;">
<thead>
<tr>
<th colspan="4" bgcolor="#F0F0F0" style="border-bottom: 1px solid #C0C0C0; font-size: 9pt; padding: 4px 8px; text-align: left;">
<a href="https://git.reviewboard.kde.org/r/117823/diff/2/?file=270239#file270239line25" style="color: black; font-weight: bold; text-decoration: underline;">modules/ECMPoQmTools.cmake</a>
<span style="font-weight: normal;">
(Diff revision 2)
</span>
</th>
</tr>
</thead>
<tbody>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">25</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="c"># <install_destination> defaults to ``${LOCALE_INSTALL_DIR}`` if defined,</span></pre></td>
</tr>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">26</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="c"># otherwise it uses ``${CMAKE_INSTALL_LOCALEDIR}`` if that is defined, otherwise</span></pre></td>
</tr>
<tr>
<th bgcolor="#b1ebb0" style="border-right: 1px solid #C0C0C0;" align="right"><font size="2"></font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "></pre></td>
<th bgcolor="#b1ebb0" style="border-left: 1px solid #C0C0C0; border-right: 1px solid #C0C0C0;" align="right"><font size="2">27</font></th>
<td bgcolor="#c5ffc4" width="50%"><pre style="font-size: 8pt; line-height: 140%; margin: 0; "><span class="c"># it uses ``share/locale``.</span></pre></td>
</tr>
</tbody>
</table>
<pre style="white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I wonder if it would be better to actually just have this as an extra argument. I mean, it's easy enough to make the frameworks use
ecm_install_po_files_as_qm(po ${LOCALE_INSTALL_DIR})
or
ecm_install_po_files_as_qm(PODIR po DESTINATION ${LOCALE_INSTALL_DIR})
or something like that.</pre>
</blockquote>
</blockquote>
<pre style="margin-left: 1em; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">I'd rather follow the "convention over configuration" approach here. This argument can always be added later if needed.</pre>
<br />
<p>- Aurélien</p>
<br />
<p>On May 2nd, 2014, 10:55 a.m. CEST, Aurélien Gâteau wrote:</p>
<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" style="background-image: url('https://git.reviewboard.kde.org/static/rb/images/review_request_box_top_bg.ab6f3b1072c9.png'); background-position: left top; background-repeat: repeat-x; border: 1px black solid;">
<tr>
<td>
<div>Review request for Build System, Extra Cmake Modules and KDE Frameworks.</div>
<div>By Aurélien Gâteau.</div>
<p style="color: grey;"><i>Updated May 2, 2014, 10:55 a.m.</i></p>
<div style="margin-top: 1.5em;">
<b style="color: #575012; font-size: 10pt;">Repository: </b>
extra-cmake-modules
</div>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">This patch adds a ecm_install_po_files_as_qm() function to ECMCreateQmFromPoFiles.cmake. This function makes it easy to install all the .po files of a Qt-translated framework.
The primary user of this function is the build system of the framework tarballs. The tarballs will ship with a po/ directory which follows the structure expected by ecm_install_po_files_as_qm(). The only necessary change is to add the following lines to the root CMakeLists.txt file:
if (IS_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/po")
ecm_install_po_files_as_qm(po)
endif()
Since the code checks for the presence of a po/ directory, it can be committed in the framework repository (no need for the tarball release scripts to alter the CMake files), making it easier for developers to reproduce the situation of a released tarball by creating/copying a po/ directory in their working copy.
We need this function (or something similar) because the way we are going to organize po files in the framework tarballs have changed: the current CMake code expects the po files to contain files named '<domain>-<lang>.po', but the final structure is going to be '<lang>/<domain>.po'.
This new function works similarly to ki18n_install() ( https://git.reviewboard.kde.org/r/117804/ ) and kdoctools_install() ( https://git.reviewboard.kde.org/r/117805/ )</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: 1px solid #b8b5a0">
<tr>
<td>
<pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: -moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: break-word;">Modified kbookmarks to call ecm_install_po_files_as_qm(). Works as expected.</pre>
</td>
</tr>
</table>
<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">
<li>modules/ECMCreateQmFromPoFiles.cmake <span style="color: grey">(7457fc5)</span></li>
<li>modules/ECMPoQmTools.cmake <span style="color: grey">(PRE-CREATION)</span></li>
<li>modules/ECMQmLoader.cpp.in <span style="color: grey">(2d8531f)</span></li>
<li>tests/CMakeLists.txt <span style="color: grey">(171f44a)</span></li>
<li>tests/ECMPoQmToolsTest/CMakeLists.txt <span style="color: grey">(PRE-CREATION)</span></li>
<li>tests/ECMPoQmToolsTest/check_tree.cmake.in <span style="color: grey">(PRE-CREATION)</span></li>
<li>tests/ECMPoQmToolsTest/po/es/install-test.po <span style="color: grey">(PRE-CREATION)</span></li>
<li>tests/ECMPoQmToolsTest/po/fr/install-test.po <span style="color: grey">(PRE-CREATION)</span></li>
<li>tests/ECMPoQmToolsTest/test.po <span style="color: grey">(PRE-CREATION)</span></li>
</ul>
<p><a href="https://git.reviewboard.kde.org/r/117823/diff/" style="margin-left: 3em;">View Diff</a></p>
</td>
</tr>
</table>
</div>
</body>
</html>