fix: install Python dependencies
This change adds a new script - `install_python_deps_tf.sh` - which
creates and loads a clean Python virtual environment and within it
installs TF-A's Python dependencies.
The previous method for doing this (sourcing the environment from
within the pre-build hook) was not working as the environment was going
out of scope after returning from the function.
Change-Id: I1c2e404665853d33212254ad576a8095b5c25aa0
Signed-off-by: Chris Kay <chris.kay@arm.com>
diff --git a/script/install_python_deps_tf.sh b/script/install_python_deps_tf.sh
new file mode 100644
index 0000000..1103181
--- /dev/null
+++ b/script/install_python_deps_tf.sh
@@ -0,0 +1,11 @@
+#!/usr/bin/env bash
+
+#
+# Copyright (c) 2021 Arm Limited. All rights reserved.
+#
+# SPDX-License-Identifier: BSD-3-Clause
+#
+
+python3 -m venv .venv && \
+ . .venv/bin/activate && \
+ python3 -m pip install -r "$tf_root/docs/requirements.txt"