CMake cannot find test if CMAKE_RUNTIME_OUTPUT_DIRECTORY is changed

前端 未结 3 1152
时光说笑
时光说笑 2021-02-07 03:57

I\'m building my project with CMake, and I\'m trying to create a bunch of test suites for each module. Apparently if I modify the variable CMAKE_RUNTIME_OUTPUT_DIRECTORY

3条回答
  •  难免孤独
    2021-02-07 04:43

    Use command:

    add_test(NAME ttest COMMAND $)
    

    Writing NAME and COMMAND is mandatory when using TARGET_FILE (or at least it's not working for me otherwise. Use cmake --help-command add_test for more information.

提交回复
热议问题