Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add build from source for DML #20384

Merged
merged 2 commits into from
Apr 21, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 14 additions & 1 deletion docs/genai/howto/build-from-source.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,12 +87,18 @@ Build from source and copy the include and libraries into `ORT_HOME`
On Windows

```cmd
build.bat --build_shared_lib --skip_tests --parallel [--use_cuda] --config Release
build.bat --build_shared_lib --skip_tests --parallel [--use_dml | --use_cuda] --config Release
copy include\onnxruntime\core\session\onnxruntime_c_api.h <ORT_HOME>\include
copy build\Windows\Release\Release\*.dll <ORT_HOME>\lib
copy build\Windows\Release\Release\onnxruntime.lib <ORTHOME>\lib
```

If building for DirectML

```cmd
copy include\onnxruntime\core\providers\dml\dml_provider_factory.h <ORT_HOME>\include
```

On Linux

```bash
Expand Down Expand Up @@ -127,6 +133,13 @@ These instructions assume you already have CUDA installed.
cd ..
python build.py --cuda_home <path to cuda home> [--ort_home <ORT_HOME>]
```

### Build for DirectML

```bash
cd ..
python build.py --use_dml
```

## Install the library into your application

Expand Down
Loading