misc: Make spirv compile and mv one command
authorCourtney Goeltzenleuchter <courtney@LunarG.com>
Fri, 10 Jul 2015 15:42:33 +0000 (09:42 -0600)
committerCourtney Goeltzenleuchter <courtney@LunarG.com>
Fri, 10 Jul 2015 15:42:33 +0000 (09:42 -0600)
Seeing some issues where a parallel make causes problems
by moving result of a different compile. Combined the
commands into one line to try and reduce odds that happens.

demos/CMakeLists.txt

index f3f745f3ee1b3f65b4e8e9319aae4aecfa46cae0..d03a0ea09bf27c32472ed15614c06ddff7867013 100644 (file)
@@ -52,24 +52,20 @@ if(WIN32)
 endif()
 if(NOT WIN32)
     add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/tri-vert.spv
-       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/tri.vert
-       COMMAND mv vert.spv ${CMAKE_BINARY_DIR}/demos/tri-vert.spv
+       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/tri.vert && mv vert.spv ${CMAKE_BINARY_DIR}/demos/tri-vert.spv
        DEPENDS tri.vert ${GLSLANG_PREFIX}/build/install/bin/glslangValidator
        )
     add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/tri-frag.spv
-       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/tri.frag
-       COMMAND mv frag.spv ${CMAKE_BINARY_DIR}/demos/tri-frag.spv
+       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/tri.frag && mv frag.spv ${CMAKE_BINARY_DIR}/demos/tri-frag.spv
        DEPENDS tri.frag ${GLSLANG_PREFIX}/build/install/bin/glslangValidator
        )
     add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/cube-vert.spv
-       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/cube.vert
-       COMMAND mv vert.spv ${CMAKE_BINARY_DIR}/demos/cube-vert.spv
+       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/cube.vert && mv vert.spv ${CMAKE_BINARY_DIR}/demos/cube-vert.spv
        DEPENDS cube.vert ${GLSLANG_PREFIX}/build/install/bin/glslangValidator
        )
 
     add_custom_command(OUTPUT ${CMAKE_BINARY_DIR}/demos/cube-frag.spv
-       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/cube.frag
-       COMMAND mv frag.spv ${CMAKE_BINARY_DIR}/demos/cube-frag.spv
+       COMMAND ${GLSLANG_PREFIX}/build/install/bin/glslangValidator -s -V ${PROJECT_SOURCE_DIR}/demos/cube.frag && mv frag.spv ${CMAKE_BINARY_DIR}/demos/cube-frag.spv
        DEPENDS cube.frag ${GLSLANG_PREFIX}/build/install/bin/glslangValidator
        )
 endif()