Skip to content

Commit 8caace9

Browse files
author
Greg Roth
authored
Revert mistaken debug changes to hctbuild (microsoft#5888)
The previous PR microsoft#5881 didn't do what it meant to and had a lot of debug code due to a mistaken commit. This reverts that commit and restores the setting of the build type flag
1 parent 9998ec1 commit 8caace9

File tree

3 files changed

+1
-11
lines changed

3 files changed

+1
-11
lines changed

CMakeLists.txt

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,17 @@
11
# See docs/CMake.html for instructions about how to build LLVM with CMake.
22
cmake_minimum_required(VERSION 3.17.2) # HLSL Change - Require CMake 3.17.2.
33

4-
message(CMAKE_BUILD_TYPE0!!!!!="${CMAKE_BUILD_TYPE}")
5-
message(CMAKE_CONFIGURATION_TYPES!!!!!="${CMAKE_CONFIGURATION_TYPES}")
6-
message(CMAKE_CXX_FLAGS_RELEASE!!!!!="${CMAKE_CXX_FLAGS_RELEASE}")
74
set(CMAKE_CXX_STANDARD 17)
85
set(CMAKE_CXX_STANDARD_REQUIRED ON)
96

107
if (NOT "${DXC_CMAKE_BEGINS_INCLUDE}" STREQUAL "")
118
include(${DXC_CMAKE_BEGINS_INCLUDE})
129
endif()
1310

14-
1511
if (NOT CMAKE_BUILD_TYPE AND NOT CMAKE_CONFIGURATION_TYPES)
1612
message(STATUS "No build type selected, default to Debug")
1713
set(CMAKE_BUILD_TYPE "Debug")
1814
endif()
19-
message(CMAKE_BUILD_TYPE1!!!!!="${CMAKE_BUILD_TYPE}")
2015

2116
if(POLICY CMP0022)
2217
cmake_policy(SET CMP0022 NEW) # automatic when 2.8.12 is required
@@ -320,15 +315,11 @@ option(LLVM_ENABLE_LIBCXXABI "Use libc++abi when using libc++." OFF)
320315
option(LLVM_ENABLE_PEDANTIC "Compile with pedantic enabled." ON)
321316
option(LLVM_ENABLE_WERROR "Fail and stop if a warning is triggered." OFF)
322317

323-
message(uppercase_CMAKE_BUILD_TYPE!!!!!="${CMAKE_BUILD_TYPE}")
324318
if( NOT uppercase_CMAKE_BUILD_TYPE STREQUAL "DEBUG" )
325-
message(assertions OFF)
326319
option(LLVM_ENABLE_ASSERTIONS "Enable assertions" OFF)
327320
else()
328-
message(assertions ON)
329321
option(LLVM_ENABLE_ASSERTIONS "Enable assertions" ON)
330322
endif()
331-
message(LLVM_ENABLE_ASSERTIONS!!!!!="${LLVM_ENABLE_ASSERTIONS}")
332323

333324
set(LLVM_ABI_BREAKING_CHECKS "WITH_ASSERTS" CACHE STRING
334325
"Enable abi-breaking checks. Can be WITH_ASSERTS, FORCE_ON or FORCE_OFF.")

cmake/modules/HandleLLVMOptions.cmake

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,6 @@ int main() { return (float)x; }"
5656
endif()
5757

5858
if( LLVM_ENABLE_ASSERTIONS )
59-
message(how did I get here?)
6059
# MSVC doesn't like _DEBUG on release builds. See PR 4379.
6160
# HLSL Note: the above comment referrs to llvm.org problem, not pull request:
6261
# https://bugs.llvm.org/show_bug.cgi?id=4379

utils/hct/hctbuild.cmd

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -474,7 +474,7 @@ if "%DO_SETUP%"=="1" (
474474
rem BUILD_TYPE is mostly ignored in this path as VS generates multiple targets
475475
rem it is still needed to satisfy cmake file expectations
476476
echo Running "%CMAKE_PATH%" -DCMAKE_BUILD_TYPE:STRING=%1 %CMAKE_OPTS% -G %4 %5 %HLSL_SRC_DIR% > %3\cmake-log.txt
477-
"%CMAKE_PATH%" %CMAKE_OPTS% -G %4 %5 %HLSL_SRC_DIR% >> %3\cmake-log.txt 2>&1
477+
"%CMAKE_PATH%" -DCMAKE_BUILD_TYPE:STRING=%1 %CMAKE_OPTS% -G %4 %5 %HLSL_SRC_DIR% >> %3\cmake-log.txt 2>&1
478478
)
479479
if %SHOW_CMAKE_LOG%==1 (
480480
echo ------- Start of %3\cmake-log.txt -------

0 commit comments

Comments
 (0)