shaderc: Fixed DXIL compiler path. (#3585)

This commit is contained in:
Branimir Karadžić
2026-02-07 17:21:16 -08:00
committed by GitHub
parent 252efb73d9
commit 562ece68a7
2 changed files with 6 additions and 3 deletions

View File

@@ -16,7 +16,7 @@ ifndef TARGET
all:
@echo Usage: make TARGET=# [clean, all, rebuild]
@echo " TARGET=0 (dxil - d3d12)"
@echo " TARGET=1 (hlsl - d3d11 / Windows only!)"
@echo " TARGET=1 (dxbc - d3d11)"
@echo " TARGET=3 (essl - android)"
@echo " TARGET=4 (glsl)"
@echo " TARGET=5 (metal)"

View File

@@ -177,12 +177,15 @@ namespace bgfx { namespace dxil
HRESULT hr = E_FAIL;
bx::FilePath dxcCompilerDll = bx::FilePath(bx::Dir::Executable).getPath();
dxcCompilerDll.join(dxcCompilerDllName);
Dxc dxc;
dxc.dll = bx::dlopen(dxcCompilerDllName);
dxc.dll = bx::dlopen(dxcCompilerDll.getCPtr() );
if (NULL == dxc.dll)
{
BX_TRACE("Error: Unable to open %s shader compiler.\n", dxcCompilerDllName);
BX_TRACE("Error: Unable to open %s shader compiler.\n", dxcCompilerDll.getCPtr() );
return Dxc{};
}