(adding yocto@ back to CC)

I don't know where you saw that but that is very wrong.

Set PACKAGE_CLASSES to the package manager that you want to use.  If you want to use opkg, then PACKAGE_CLASSES should be package_ipk (historical naming).  If you want opkg to be present in the images ensure IMAGE_FEATURES contains package-management.

PACKAGE_CLASSES controls what package formats are generated, and multiple are supported for flexibility and testing purposes.  For real world use there's no need to have more than one.  The first entry is the package type that is actually used in the rootfs generation.

package-management needs to be in IMAGE_FEATURES to both get the tools installed (opkg in your case, apt-get for dpkg, yum for rpm) and to keep the package management database on the disk.  By removing package-management from IMAGE_FEATURES all traces of the package manager will be removed from the rootfs, which is useful if you don't want to support on-target use of the package manager.

Ross

On 9 November 2017 at 06:45, Ran Shalit <ranshalit@gmail.com> wrote:
Hi,

We also consider using opkg.

Now, I have some confusion as to how to install opkg.
I see in some documentation that it should be installed as following:

PACKAGE_CLASSES ?= "package_rpm package_ipk"
IMAGE_INSTALL_append = " opkg "

Does it mean there are 2 package managers active ?
How can we know which of them is active ?


If "?=" means that it shall be defined only if not defined previously,
so if it is already defined as  package_rpm , it might not install
package_ipk?
Doesn't it mean that "opkg" might be installed without the required
package_ipk ?

Thank you,
Ran

On Wed, Nov 8, 2017 at 9:26 PM, Burton, Ross <ross.burton@intel.com> wrote:
> Set PACKAGE_CLASSES to package_deb, and then ensure IMAGE_FEATURES includes
> package-management.
>
> Ross
>
> On 8 November 2017 at 19:16, Ran Shalit <ranshalit@gmail.com> wrote:
>>
>> Hello,
>>
>> Is there a way to add "apt-get" command (and package manager) in yocto ?
>>
>> Thank you,
>> Ran
>> --
>> _______________________________________________
>> yocto mailing list
>> yocto@yoctoproject.org
>> https://lists.yoctoproject.org/listinfo/yocto
>
>