summaryrefslogtreecommitdiff
path: root/src/ipa/ipa-sign-install.sh
diff options
context:
space:
mode:
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-05-12 19:24:23 +0300
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>2020-05-13 22:06:43 +0300
commit924778eb073c47a0defc7319e98029c712129ede (patch)
tree441d509df8c7a921a023edab3f1e2f02ff1e237a /src/ipa/ipa-sign-install.sh
parente8655c2161a97261971ef19621a34651980b76d6 (diff)
ipa: Only sign IPA modules that are being installed
The ipa-sign-install.sh script, run when installing libcamera, signs all IPA modules present in the module directory. This would result in third-party modules being signed if any are present in the directory. Fix it by explicitly passing the list of IPA modules to the ipa-sign-install.sh script. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Tested-by: Tomasz Figa <tfiga@chromium.org> Reviewed-by: Tomasz Figa <tfiga@chromium.org>
Diffstat (limited to 'src/ipa/ipa-sign-install.sh')
-rwxr-xr-xsrc/ipa/ipa-sign-install.sh12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/ipa/ipa-sign-install.sh b/src/ipa/ipa-sign-install.sh
index 5317a8a2..bcedb8b5 100755
--- a/src/ipa/ipa-sign-install.sh
+++ b/src/ipa/ipa-sign-install.sh
@@ -6,13 +6,17 @@
#
# ipa-sign-install.sh - Regenerate IPA module signatures when installing
-libdir=$1
-key=$2
+key=$1
+shift
+modules=$*
ipa_sign=$(dirname "$0")/ipa-sign.sh
echo "Regenerating IPA modules signatures"
-for module in "${MESON_INSTALL_DESTDIR_PREFIX}/${libdir}"/*.so ; do
- "${ipa_sign}" "${key}" "${module}" "${module}.sign"
+for module in ${modules} ; do
+ module="${MESON_INSTALL_DESTDIR_PREFIX}/${module}"
+ if [ -f "${module}" ] ; then
+ "${ipa_sign}" "${key}" "${module}" "${module}.sign"
+ fi
done