]> git.ipfire.org Git - thirdparty/git.git/commit
cmake: generalize the handling of the `CLAR_TEST_OBJS` list
authorJohannes Schindelin <johannes.schindelin@gmx.de>
Thu, 6 Mar 2025 10:26:20 +0000 (10:26 +0000)
committerJunio C Hamano <gitster@pobox.com>
Thu, 6 Mar 2025 16:35:08 +0000 (08:35 -0800)
commit970916368764347c38d36c727b2e6e0086e784e3
treef81e92e74dfd7b2a47501acd0b398f0f5c4c8d2a
parent31761f391192909f6486ecb532e72dfaee756be6
cmake: generalize the handling of the `CLAR_TEST_OBJS` list

A late-comer to the v2.49.0 party, `sk/unit-test-oid`, added yet another
array item to `CLAR_TEST_OBJS`, causing the `win+VS build` job to fail
with symptoms like this one:

  unit-tests-lib.lib(u-oid-array.obj) : error LNK2019: unresolved
  external symbol cl_parse_any_oid referenced in function fill_array

This is a similar scenario to the one that forced me to write
8afda42fce60 (cmake: generalize the handling of the `UNIT_TEST_OBJS`
list, 2024-09-18): The hard-coded echo of `CLAR_TEST_OBJS` in
`CMakeLists.txt` that recapitulates faithfully what was already
hard-coded in `Makefile` would either have to be updated whack-a-mole
style, or generalized.

Just like I chose the latter option for `UNIT_TEST_OBJS`, I now do the
same for `CLAR_TEST_OBJS`.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/buildsystems/CMakeLists.txt