simon-git: msvc-extract (main): Simon Tatham

Commits to Tartarus hosted VCS tartarus-commits at lists.tartarus.org
Thu May 13 14:52:48 BST 2021


TL;DR:
  afe71dd Work around cmake unused-variable warning.

Repository:     https://git.tartarus.org/simon/msvc-extract.git
On the web:     https://git.tartarus.org/?p=simon/msvc-extract.git
Branch updated: main
Committer:      Simon Tatham <anakin at pobox.com>
Date:           2021-05-13 14:52:48

commit afe71dd006146b71cb1d36eb5435ca33cfe5e42f
web diff https://git.tartarus.org/?p=simon/msvc-extract.git;a=commitdiff;h=afe71dd006146b71cb1d36eb5435ca33cfe5e42f;hp=db08a97964fb77bf26300d199630c10c73df8e87
Author: Simon Tatham <anakin at pobox.com>
Date:   Thu May 13 14:35:53 2021 +0100

    Work around cmake unused-variable warning.
    
    Sometimes, when regenerating the build files in an existing cmake
    build directory, you get a spurious warning that reads
    
    CMake Warning:
      Manually-specified variables were not used by the project:
    
        CMAKE_TOOLCHAIN_FILE
    
    Apparently this is a well-known annoyance, and other people's
    toolchain files already know what to do about it: in the toolchain
    file itself, make CMAKE_TOOLCHAIN_FILE the condition in an empty if
    statement, which marks the variable as 'used'.
    
    (Of course, if we're _reading_ that file, we must already have used
    the variable containing its name! So the warning is surely spurious.)

 msvc-extract.c | 5 +++++
 1 file changed, 5 insertions(+)



More information about the tartarus-commits mailing list