diff --git a/config/functions b/config/functions
index cc81c1f090..8bc00b9d8e 100644
--- a/config/functions
+++ b/config/functions
@@ -935,7 +935,7 @@ pkg_call_exists() {
pkg_call() {
[ -n "${PKG_NAME}" ] || die "$(print_color CLR_ERROR "FAILURE: Cannot call ${1} package function when package is not known!")"
- ${1}
+ "${@}"
}
unset_functions() {
@@ -955,7 +955,7 @@ unset_functions() {
unset -f pre_install post_install
- unset -f addon
+ unset -f addon post_install_addon
}
# p1: name of package to be sourced
@@ -1283,6 +1283,10 @@ install_addon_files() {
install_addon_images "$1"
create_addon_xml "$1"
python_fix_abi "$1"
+
+ if pkg_call_exists post_install_addon; then
+ INSTALL="$1" pkg_call post_install_addon
+ fi
}
install_driver_addon_files() {
diff --git a/packages/readme.md b/packages/readme.md
index e3c5083cbe..133b76c3c8 100644
--- a/packages/readme.md
+++ b/packages/readme.md
@@ -154,6 +154,7 @@ Full list of overwrittable functions.
| make_\[stage]
pre_make_\[stage]
post_make_\[stage] | yes | Build of the package |
| makeinstall_\[stage]
pre_makeinstall_\[stage]
post_makeinstall_\[stage] | yes | Installation of the files in the correct pathes
host: TOOLCHAIN
target: SYSROOT and IMAGE
bootstrap and init: temporary destination
| addon | - | Copy all files together for addon creation. This is requiered for addons |
+| post_install_addon | - | Post processing of installed addon files in `${INSTALL}` directory |
## Late Binding variable assignment
diff --git a/tools/pkgcheck b/tools/pkgcheck
index 55282dc9b7..491017e061 100755
--- a/tools/pkgcheck
+++ b/tools/pkgcheck
@@ -101,7 +101,7 @@ check_func_name() {
pre_configure \
${TARGET_FUNCS} \
pre_install post_install \
- addon \
+ addon post_install_addon \
; do
[[ ${line} =~ ^${f} ]] && return 0
done