Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
是否可以轻松获取启动 CMake 配置的主机名?
如果不可能,我如何获得启动 CTest 的主机名?
我在 Windows 和 Linux 下使用 CMake 和 CTest。
谢谢,
CMake site_name() 函数应该给你你想要的。要获取有关它的信息,请执行“cmake --help-command SITE_NAME”。