summaryrefslogtreecommitdiffstats
path: root/meta/classes/package_ipk.bbclass
diff options
context:
space:
mode:
Diffstat (limited to 'meta/classes/package_ipk.bbclass')
-rw-r--r--meta/classes/package_ipk.bbclass31
1 files changed, 28 insertions, 3 deletions
diff --git a/meta/classes/package_ipk.bbclass b/meta/classes/package_ipk.bbclass
index c0893a6cda..b5319bcbd0 100644
--- a/meta/classes/package_ipk.bbclass
+++ b/meta/classes/package_ipk.bbclass
@@ -83,12 +83,34 @@ package_tryout_install_multilib_ipk() {
83 fi 83 fi
84 done 84 done
85} 85}
86
87split_multilib_packages() {
88 INSTALL_PACKAGES_NORMAL_IPK=""
89 INSTALL_PACKAGES_MULTILIB_IPK=""
90 for pkg in ${INSTALL_PACKAGES_IPK}; do
91 is_multilib=0
92 for item in ${MULTILIB_VARIANTS}; do
93 local pkgname_prefix="${item}-"
94 if [ ${pkg:0:${#pkgname_prefix}} == ${pkgname_prefix} ]; then
95 is_multilib=1
96 break
97 fi
98 done
99
100 if [ ${is_multilib} = 0 ]; then
101 INSTALL_PACKAGES_NORMAL_IPK="${INSTALL_PACKAGES_NORMAL_IPK} ${pkg}"
102 else
103 INSTALL_PACKAGES_MULTILIB_IPK="${INSTALL_PACKAGES_MULTILIB_IPK} ${pkg}"
104 fi
105 done
106}
107
86# 108#
87# install a bunch of packages using opkg 109# install a bunch of packages using opkg
88# the following shell variables needs to be set before calling this func: 110# the following shell variables needs to be set before calling this func:
89# INSTALL_ROOTFS_IPK - install root dir 111# INSTALL_ROOTFS_IPK - install root dir
90# INSTALL_CONF_IPK - configuration file 112# INSTALL_CONF_IPK - configuration file
91# INSTALL_PACKAGES_NORMAL_IPK - packages to be installed 113# INSTALL_PACKAGES_IPK - packages to be installed
92# INSTALL_PACKAGES_ATTEMPTONLY_IPK - packages attemped to be installed only 114# INSTALL_PACKAGES_ATTEMPTONLY_IPK - packages attemped to be installed only
93# INSTALL_PACKAGES_LINGUAS_IPK - additional packages for uclibc 115# INSTALL_PACKAGES_LINGUAS_IPK - additional packages for uclibc
94# INSTALL_TASK_IPK - task name 116# INSTALL_TASK_IPK - task name
@@ -97,12 +119,15 @@ package_install_internal_ipk() {
97 119
98 local target_rootfs="${INSTALL_ROOTFS_IPK}" 120 local target_rootfs="${INSTALL_ROOTFS_IPK}"
99 local conffile="${INSTALL_CONF_IPK}" 121 local conffile="${INSTALL_CONF_IPK}"
100 local package_to_install="${INSTALL_PACKAGES_NORMAL_IPK}"
101 local package_attemptonly="${INSTALL_PACKAGES_ATTEMPTONLY_IPK}" 122 local package_attemptonly="${INSTALL_PACKAGES_ATTEMPTONLY_IPK}"
102 local package_linguas="${INSTALL_PACKAGES_LINGUAS_IPK}" 123 local package_linguas="${INSTALL_PACKAGES_LINGUAS_IPK}"
103 local package_multilib="${INSTALL_PACKAGES_MULTILIB_IPK}"
104 local task="${INSTALL_TASK_IPK}" 124 local task="${INSTALL_TASK_IPK}"
105 125
126 split_multilib_packages
127
128 local package_to_install="${INSTALL_PACKAGES_NORMAL_IPK}"
129 local package_multilib="${INSTALL_PACKAGES_MULTILIB_IPK}"
130
106 mkdir -p ${target_rootfs}${localstatedir}/lib/opkg/ 131 mkdir -p ${target_rootfs}${localstatedir}/lib/opkg/
107 132
108 local ipkg_args="-f ${conffile} -o ${target_rootfs} --force-overwrite" 133 local ipkg_args="-f ${conffile} -o ${target_rootfs} --force-overwrite"