Skip to content

Commit

Permalink
Cleanup and minor changes to improve integration with internal projec…
Browse files Browse the repository at this point in the history
…ts (#3199)

* Cleanup and minor changes to improve integration with internal projects

Adds -Debug option to hcttest.cmd

* Case insensitive compare for -Debug and -Release flags in hctbuild and hcttest
  • Loading branch information
hekota committed Oct 14, 2020
1 parent a1b3f67 commit b640fa4
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 6 deletions.
2 changes: 1 addition & 1 deletion cmake/modules/FindDiaSDK.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ elseif (CMAKE_GENERATOR MATCHES "Visual Studio.*ARM" OR CMAKE_GENERATOR_PLATFORM
else (CMAKE_GENERATOR MATCHES "Visual Studio.*Win64" OR CMAKE_GENERATOR_PLATFORM STREQUAL "ARM64")
find_library(DIASDK_GUIDS_LIBRARY NAMES diaguids.lib
HINTS ${DIASDK_INCLUDE_DIR}/../lib )
endif (CMAKE_GENERATOR MATCHES "Visual Studio.*Win64" )
endif (CMAKE_GENERATOR MATCHES "Visual Studio.*Win64" OR CMAKE_GENERATOR_PLATFORM STREQUAL "x64")

set(DIASDK_LIBRARIES ${DIASDK_GUIDS_LIBRARY})
set(DIASDK_INCLUDE_DIRS ${DIASDK_INCLUDE_DIR})
Expand Down
5 changes: 5 additions & 0 deletions include/dxc/Test/HlslTestUtils.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,13 @@

using namespace std;

#ifndef HLSLDATAFILEPARAM
#define HLSLDATAFILEPARAM L"HlslDataDir"
#endif

#ifndef FILECHECKDUMPDIRPARAM
#define FILECHECKDUMPDIRPARAM L"FileCheckDumpDir"
#endif

// If TAEF verify macros are available, use them to alias other legacy
// comparison macros that don't have a direct translation.
Expand Down
2 changes: 1 addition & 1 deletion tools/clang/unittests/HLSL/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,7 @@ if(WIN32)
include_directories(${TAEF_INCLUDE_DIRS})
include_directories(${DIASDK_INCLUDE_DIRS})
include_directories(${D3D12_INCLUDE_DIRS})

include_directories(${LLVM_MAIN_INCLUDE_DIR}/dxc/Test)
endif(WIN32)

# Add includes to directly reference intrinsic tables.
Expand Down
2 changes: 1 addition & 1 deletion tools/clang/unittests/HLSL/ShaderOpTest.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
#include "dxc/Support/dxcapi.use.h" // DxcDllSupport
#include "dxc/DXIL/DxilConstants.h" // ComponentType
#include "WexTestClass.h" // TAEF
#include "dxc/Test/HLSLTestUtils.h" // LogCommentFmt
#include "HLSLTestUtils.h" // LogCommentFmt

#include <stdlib.h>
#include <DirectXMath.h>
Expand Down
4 changes: 2 additions & 2 deletions utils/hct/hctbuild.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -119,11 +119,11 @@ if /i "%1"=="-arm64" (
set BUILD_ARCH=ARM64
shift /1
)
if "%1"=="-Debug" (
if /i "%1"=="-Debug" (
set BUILD_CONFIG=Debug
shift /1
)
if "%1"=="-Release" (
if /i "%1"=="-Release" (
set BUILD_CONFIG=Release
shift /1
)
Expand Down
4 changes: 3 additions & 1 deletion utils/hct/hcttest.cmd
Original file line number Diff line number Diff line change
Expand Up @@ -138,8 +138,10 @@ if "%1"=="-clean" (
set GENERATOR_NINJA=1
) else if "%1"=="-rel" (
set BUILD_CONFIG=Release
) else if "%1"=="-Release" (
) else if /i "%1"=="-Release" (
set BUILD_CONFIG=Release
) else if /i "%1"=="-Debug" (
set BUILD_CONFIG=Debug
) else if "%1"=="-x86" (
rem Allow BUILD_ARCH override. This may be used by HCT_EXTRAS scripts.
set BUILD_ARCH=Win32
Expand Down

0 comments on commit b640fa4

Please sign in to comment.