Skip to content

Commit ba9768b

Browse files
committed
pass args into install_executorch.sh
1 parent b2c02fe commit ba9768b

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

backends/openvino/scripts/openvino_build.sh

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,19 @@
33
# Exit immediately if a command exits with a non-zero status.
44
set -e
55

6+
# Enable debug mode to print each command before executing it
7+
set -x
8+
69
# Define the directory where CMakeLists.txt is located
710
EXECUTORCH_ROOT=$(realpath "$(dirname "$0")/../../..")
811
echo EXECUTORCH_ROOT=${EXECUTORCH_ROOT}
912

1013
main() {
1114
build_type=${1:-"--cpp_runtime"}
1215

16+
shift # Remove the first argument (build_type) from the list of arguments
17+
args=("$@") # Capture all remaining arguments
18+
1319
# If the first arguments is --cpp_runtime (default), build libraries for C++ runtime
1420
if [[ -z "$build_type" || "$build_type" == "--cpp_runtime" ]]; then
1521
echo "Building C++ Runtime Libraries"
@@ -43,7 +49,7 @@ main() {
4349

4450
# Create and enter the build directory
4551
cd "$EXECUTORCH_ROOT"
46-
./install_executorch.sh --clean
52+
./install_executorch.sh --clean "${args[@]}"
4753

4854
# Set parameters to configure the project with CMake
4955
# Note: Add any additional configuration options you need here
@@ -52,7 +58,7 @@ main() {
5258
export CMAKE_BUILD_ARGS="--target openvino_backend"
5359

5460
# Build the package
55-
./install_executorch.sh
61+
./install_executorch.sh "${args[@]}"
5662

5763
# Install torchao
5864
pip install third-party/ao

0 commit comments

Comments
 (0)