Skip to content
Merged
Show file tree
Hide file tree
Changes from 2 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
10 changes: 7 additions & 3 deletions BUILD.md
Original file line number Diff line number Diff line change
Expand Up @@ -178,9 +178,13 @@ set(CMAKE_FIND_ROOT_PATH_MODE_PACKAGE ONLY)
5. append "-DCMAKE_TOOLCHAIN_FILE=path/to/tool.cmake" to your cmake args, run cmake and make to build it.

### Native compiling on Linux (SLOWER)
Please see [ARM docker file](dockerfiles/Dockerfile.arm32v7). Note that
to build in ACR-Build (Azure Container Registry), you may want to split it to two files and run them one by one.
If you run this Dockerfile directly in ACR-Build, it is likely to hit their timeout limitation (8 hours).

Please see [ARM docker file](dockerfiles/Dockerfile.arm32v7). Docker build run on a Raspberry Pi 3B with Raspbian Stretch Lite OS (Desktop version will run out memory when linking the .so file) will take 8-9 hours in total. If you want to use [Azure Container Registry Tasks](https://docs.microsoft.com/en-us/azure/container-registry/container-registry-tasks-overview) building the Docker image in cloud, you may want to split this Dockerfile to two steps:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

runs

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

building the Docker image -> to build the Docker image.


1. Build environment image creation: steps before onnxruntime repo clone
2. ONNX Runtime and Python binding creation: the rest of steps in the original Dockerfile with step 1 output as base image.

By doing this, you could avoid hit the ACR-Tasks build timeout (8 hours)

### Cross compiling on Windows
(TODO)
3 changes: 1 addition & 2 deletions dockerfiles/Dockerfile.arm32v7
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@ RUN make
RUN sudo make install

# Prepare onnxruntime Repo
# WORKDIR /code/onnxruntime
# RUN git clone --recursive https://github.com/Microsoft/onnxruntime
RUN git clone --recursive https://github.com/Microsoft/onnxruntime

WORKDIR /code/onnxruntime
ARG BUILDTYPE=Debug
Expand Down