Skip to content
Jorge Cantón edited this page Apr 11, 2024 · 2 revisions

Compile instrucction for HLSLEverywhere

Download Master y mezclar con add-mslDecoratingBinding Branch.

Crear solución de Visual Studio 2019 con cmake

mkdir Build
cd Build
cmake -G “Visual Studio 16” -t host=x64 -A x64 ../
cmake build .

Describe the additional steps in Linux and Mac

https://github.com/microsoft/ShaderConductor/issues/52

Commit of gongminmin para dependencies problem in Linux and Mac https://github.com/gongminmin/ShaderConductor/commit/05f4536ad3f3be27d30c17b229bed175cf87eddb

Compile Shader Conductor Windows

Python.exe BuildAll.py vs2019 vc142 x86 MinSizeRel
Python.exe BuildAll.py vs2019 vc142 x64 MinSizeRel

Compile Shader Conductor Linux & Mac

git clone “https://github.com/Jorgemagic/ShaderConductor.git”
git fetch
git checkout UpdatedDec2022
python BuildAll.py ninja clang x64 MinSizeRel

Linux additional Steps (Patchelf command) article

patchelf --set-soname libdxcompiler.so libdxcompiler.so
mv libdxcompiler.so libdxcompiler.so.3.7
patchelf --set-rpath '$ORIGIN' libdxcompiler.so.3.7

patchelf --set-rpath '$ORIGIN' libShaderConductor.so

patchelf --set-rpath '$ORIGIN' libShaderConductorWrapper.so

patchelf --set-rpath '$ORIGIN' ShaderConductorCmd

patchelf --set-rpath '$ORIGIN' ShaderConductorTest

Mac pre-requisites

Install Homebrew

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Install ninja
brew install ninja

Install cmake
brew install cmake

Useful Linux commands

patchelf --print-soname mylibrary.so
patchelf --set-soname mylibrary.so
patchelf --print-rpath mylibrary.so
patchelf --set-rpath mylibrary.so
readelf -d mylibrary.so (Show dynamic library required)
ldd mylibrary.so (Resolve dependencies)

Useful Mac commands

(install_name_tool) article

otool -L myLibrary.dylib (Show dynamic library required)