<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/cmake.git/Tests/Module/ExternalData, branch master</title>
<subtitle>gitlab.kitware.com: cmake/cmake.git
</subtitle>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/'/>
<entry>
<title>Tests: Avoid duplicate custom commands for Xcode "new build system"</title>
<updated>2020-09-18T17:02:19+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2020-09-15T15:21:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=1806cdd17c17fc202b4d7c195b1830cfc038a3a2'/>
<id>1806cdd17c17fc202b4d7c195b1830cfc038a3a2</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Tests: Avoid duplicate rules in ExternalData test</title>
<updated>2018-04-13T12:06:48+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2018-04-13T12:02:17+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=bb66cea6c510b85f8c84e047f9e8a25ef1ada17c'/>
<id>bb66cea6c510b85f8c84e047f9e8a25ef1ada17c</id>
<content type='text'>
In commit v3.7.0-rc1~158^2 (ExternalData: Tolerate files duplicated
across multiple targets, 2016-07-07) we added a test case for repeating
the same data file reference in three different targets in the same
directory in order to exercise its corresponding fix.  However, we
re-used the top-level `Data.dat` file which is already produced by
an unrelated test case.  `ninja` diagnoses the duplicate rule.

Update the test to use a dedicated data file name for the three-times
repeated case to avoid this conflict.  It still covers the original
purpose of the test.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In commit v3.7.0-rc1~158^2 (ExternalData: Tolerate files duplicated
across multiple targets, 2016-07-07) we added a test case for repeating
the same data file reference in three different targets in the same
directory in order to exercise its corresponding fix.  However, we
re-used the top-level `Data.dat` file which is already produced by
an unrelated test case.  `ninja` diagnoses the duplicate rule.

Update the test to use a dedicated data file name for the three-times
repeated case to avoid this conflict.  It still covers the original
purpose of the test.
</pre>
</div>
</content>
</entry>
<entry>
<title>gitattributes: prefer `-text` for binary files</title>
<updated>2017-08-23T17:30:00+00:00</updated>
<author>
<name>Ben Boeckel</name>
<email>ben.boeckel@kitware.com</email>
</author>
<published>2017-08-23T17:21:36+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=b85c2589a1a22fb46620d7b0fd8aa6ec28ac5670'/>
<id>b85c2589a1a22fb46620d7b0fd8aa6ec28ac5670</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>ExternalData: Add support for SHA-3 algorithms</title>
<updated>2016-11-11T16:46:00+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2016-11-10T21:35:59+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=b4ffd26fd8750989a8aadd626242c314068ba987'/>
<id>b4ffd26fd8750989a8aadd626242c314068ba987</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>ExternalData: Add support for multiple hash algorithms</title>
<updated>2016-10-18T15:16:45+00:00</updated>
<author>
<name>Matt McCormick</name>
<email>matt.mccormick@kitware.com</email>
</author>
<published>2016-10-12T18:57:32+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=33a9aaa89b437da29a70f27d25b267242b6f982c'/>
<id>33a9aaa89b437da29a70f27d25b267242b6f982c</id>
<content type='text'>
Add support for projects to have `Data.txt.md5` *and* `Data.txt.sha512`
where the content links hold hashes for the same file.  Check all
`ExternalData_URL_TEMPLATES` entries in order for all available hashes.
The data acquisition is considered a failure if none of the available
URL resources has any of the given hashes.  This makes it possible to
have multiple data server resources where all servers do not support all
hashing algorithms.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add support for projects to have `Data.txt.md5` *and* `Data.txt.sha512`
where the content links hold hashes for the same file.  Check all
`ExternalData_URL_TEMPLATES` entries in order for all available hashes.
The data acquisition is considered a failure if none of the available
URL resources has any of the given hashes.  This makes it possible to
have multiple data server resources where all servers do not support all
hashing algorithms.
</pre>
</div>
</content>
</entry>
<entry>
<title>ExternalData: Tolerate files duplicated across multiple targets</title>
<updated>2016-09-07T19:17:33+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2016-09-07T19:09:19+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=f9973166e82c3f5d8e05e2ab57aceb15ff267295'/>
<id>f9973166e82c3f5d8e05e2ab57aceb15ff267295</id>
<content type='text'>
If multiple ExternalData_Target_Add calls generate the same output file
then we need to avoid calling add_custom_command multiple times with
that output.  This was already done within a single target by setting a
variable in the local function scope.  This will not be visible in other
calls though so we need to use a directory property instead to prevent
adding a custom command multiple times for one output in a directory.

Normally it is not safe to have multiple custom commands that produce
the same output file across multiple independent targets, but since we
use atomic replacement of outputs the resulting races should not be a
problem.  For the convenience of projects, tolerate this instead of
diagnosing it.  In particular, we previously allowed up to two copies
of the custom command in one directory because CMake has a fallback
from MAIN_DEPENDENCY to an `&lt;output&gt;.rule` file.

While at it, add a note to the documentation that typically only one
external data target should be needed for a project.

Reported-by: David Manthey &lt;david.manthey@kitware.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
If multiple ExternalData_Target_Add calls generate the same output file
then we need to avoid calling add_custom_command multiple times with
that output.  This was already done within a single target by setting a
variable in the local function scope.  This will not be visible in other
calls though so we need to use a directory property instead to prevent
adding a custom command multiple times for one output in a directory.

Normally it is not safe to have multiple custom commands that produce
the same output file across multiple independent targets, but since we
use atomic replacement of outputs the resulting races should not be a
problem.  For the convenience of projects, tolerate this instead of
diagnosing it.  In particular, we previously allowed up to two copies
of the custom command in one directory because CMake has a fallback
from MAIN_DEPENDENCY to an `&lt;output&gt;.rule` file.

While at it, add a note to the documentation that typically only one
external data target should be needed for a project.

Reported-by: David Manthey &lt;david.manthey@kitware.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ExternalData: Add option to disable use of symlinks</title>
<updated>2015-05-22T13:21:47+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2015-05-22T13:15:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=0de47b05f74bd12d41b46634f00aea3bcb6f3678'/>
<id>0de47b05f74bd12d41b46634f00aea3bcb6f3678</id>
<content type='text'>
Add an ExternalData_NO_SYMLINKS to enable use of copies instead of
symlinks to populate the real data files behind a DATA{} reference.
This will be useful on UNIX-like systems when the underlying filesystem
does not actually support symbolic links.

Suggested-by: Matt McCormick &lt;matt.mccormick@kitware.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add an ExternalData_NO_SYMLINKS to enable use of copies instead of
symlinks to populate the real data files behind a DATA{} reference.
This will be useful on UNIX-like systems when the underlying filesystem
does not actually support symbolic links.

Suggested-by: Matt McCormick &lt;matt.mccormick@kitware.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>ExternalData: Add option to recursively match under directories</title>
<updated>2015-03-27T18:44:54+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2015-03-25T14:23:51+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=230f2d6e7060e70b7205fc65f6bee7ce37e3f27b'/>
<id>230f2d6e7060e70b7205fc65f6bee7ce37e3f27b</id>
<content type='text'>
Extend the ``DATA{Dir/,...}`` syntax with a new ``RECURSE:`` option
to enable recursive matching of associated files.  This will allow
an entire directory tree of data to be referenced at once.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Extend the ``DATA{Dir/,...}`` syntax with a new ``RECURSE:`` option
to enable recursive matching of associated files.  This will allow
an entire directory tree of data to be referenced at once.
</pre>
</div>
</content>
</entry>
<entry>
<title>ExternalData: Add support for custom algorithm-to-URL mapping</title>
<updated>2015-02-25T13:28:05+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2015-02-25T13:11:39+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=f7f4ca55bde68b174b7542fe417426a7cbf76fe3'/>
<id>f7f4ca55bde68b174b7542fe417426a7cbf76fe3</id>
<content type='text'>
Allow URL templates to contain a %(algo:&lt;key&gt;) placeholder that is
replaced by mapping the canonical hash algorithm name through a map
defined by the &lt;key&gt;.

Extend the Module.ExternalData test to cover the behavior.
Extend the RunCMake.ExternalData test to cover error cases.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Allow URL templates to contain a %(algo:&lt;key&gt;) placeholder that is
replaced by mapping the canonical hash algorithm name through a map
defined by the &lt;key&gt;.

Extend the Module.ExternalData test to cover the behavior.
Extend the RunCMake.ExternalData test to cover error cases.
</pre>
</div>
</content>
</entry>
<entry>
<title>ExternalData: Add support for custom download scripts</title>
<updated>2015-01-15T15:48:09+00:00</updated>
<author>
<name>Brad King</name>
<email>brad.king@kitware.com</email>
</author>
<published>2015-01-13T15:03:56+00:00</published>
<link rel='alternate' type='text/html' href='http://git.baserock.org/cgit/delta/cmake.git/commit/?id=0fe4d8bb3b9e8074f7efd95ae92fa32fe29a2c02'/>
<id>0fe4d8bb3b9e8074f7efd95ae92fa32fe29a2c02</id>
<content type='text'>
Add support for a special URL template to map the fetch operation
to a project-specified .cmake script insead of using file(DOWNLOAD).

Extend the Module.ExternalData test to cover the behavior.
Extend the RunCMake.ExternalData test to cover error cases.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add support for a special URL template to map the fetch operation
to a project-specified .cmake script insead of using file(DOWNLOAD).

Extend the Module.ExternalData test to cover the behavior.
Extend the RunCMake.ExternalData test to cover error cases.
</pre>
</div>
</content>
</entry>
</feed>
