Skip to content

Commit 93754d5

Browse files
authored
Merge pull request KhronosGroup#285 from jeremy-lunarg/hayes-fix-271
Remove custom target if skipping install
2 parents 0bcc624 + 539b239 commit 93754d5

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

CMakeLists.txt

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,6 @@ project(SPIRV-Headers VERSION 1.5.5)
4444
# 2. cmake ..
4545
# 3. cmake --build . --target install
4646

47-
# legacy
48-
add_custom_target(install-headers
49-
COMMAND cmake -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/include/spirv
50-
$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/include/spirv)
51-
5247
option(SPIRV_HEADERS_SKIP_EXAMPLES "Skip building examples"
5348
${SPIRV_HEADERS_SKIP_EXAMPLES})
5449

@@ -61,6 +56,10 @@ endif()
6156

6257
if(NOT ${SPIRV_HEADERS_SKIP_INSTALL})
6358
set(SPIRV_HEADERS_ENABLE_INSTALL ON)
59+
# legacy
60+
add_custom_target(install-headers
61+
COMMAND cmake -E copy_directory ${CMAKE_CURRENT_SOURCE_DIR}/include/spirv
62+
$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/include/spirv)
6463
endif()
6564

6665
if (SPIRV_HEADERS_ENABLE_EXAMPLES)

0 commit comments

Comments
 (0)