neovim/test/functional/fixtures/CMakeLists.txt
dundargoc f936a962d0 build: create separate targets for nvim with and without runtime files
This distinction is important for correct dependency management, as the
nvim binary is used to create some runtime files. The nvim binary (and
the target to build it) is thus called `nvim_bin` and the target to
build all of nvim (binary+runtime) is called `nvim`.
2024-01-20 12:59:27 +01:00

24 lines
960 B
CMake

add_library(test_lib INTERFACE)
if(MINGW)
target_link_libraries(test_lib INTERFACE -municode)
endif()
if(WIN32)
target_compile_definitions(test_lib INTERFACE MSWIN)
endif()
target_link_libraries(test_lib INTERFACE nvim_bin)
add_executable(tty-test EXCLUDE_FROM_ALL tty-test.c)
add_executable(shell-test EXCLUDE_FROM_ALL shell-test.c)
# Fake pwsh (powershell) for testing make_filter_cmd(). #16271
add_executable(pwsh-test EXCLUDE_FROM_ALL shell-test.c)
add_executable(printargs-test EXCLUDE_FROM_ALL printargs-test.c)
add_executable(printenv-test EXCLUDE_FROM_ALL printenv-test.c)
add_executable(streams-test EXCLUDE_FROM_ALL streams-test.c)
target_link_libraries(tty-test PRIVATE test_lib)
target_link_libraries(shell-test PRIVATE test_lib)
target_link_libraries(pwsh-test PRIVATE test_lib)
target_link_libraries(printargs-test PRIVATE test_lib)
target_link_libraries(printenv-test PRIVATE test_lib)
target_link_libraries(streams-test PRIVATE test_lib)