cmake工程文件改用宏控制,方便添加多个工程

This commit is contained in:
hyzboy 2019-05-05 00:25:24 +08:00
parent 95db470e85
commit 977ee1327c

View File

@ -1,2 +1,8 @@
add_executable(VulkanTest main.cpp ${SHADER_FILES})
target_link_libraries(VulkanTest ${ULRE})
macro(CreateProject name main_file)
add_executable(${name} ${main_file}.cpp)
target_link_libraries(${name} ${ULRE})
endmacro()
CreateProject(0.triangle main)
CreateProject(1.cube cube)