Poky PREFERRED VERSION

From Crashcourse Wiki

Jump to: navigation, search

When there are multiple versions of the same recipe, BitBake will always take the most recent version unless told otherwise, say by a recipe, your local.conf file, or a distro definition conf file. Here are some examples from Poky-related distro files from the meta-yocto layer.

For example, there are multiple versions of the kernel recipes:

linux-dummy.bb
linux-yocto_3.10.bb
linux-yocto_3.14.bb
linux-yocto_3.4.bb
linux-yocto-dev.bb
linux-yocto-rt_3.10.bb
linux-yocto-rt_3.14.bb
linux-yocto-rt_3.4.bb
linux-yocto-tiny_3.10.bb
linux-yocto-tiny_3.14.bb
linux-yocto-tiny_3.4.bb

Contents

[edit] Sample configuration files

[edit] poky.conf

... snip ...
PREFERRED_VERSION_linux-yocto ?= "3.14%"
PREFERRED_VERSION_linux-yocto_qemux86 ?= "3.14%"
PREFERRED_VERSION_linux-yocto_qemux86-64 ?= "3.14%"
PREFERRED_VERSION_linux-yocto_qemuarm ?= "3.14%"
PREFERRED_VERSION_linux-yocto_qemumips ?= "3.14%"
PREFERRED_VERSION_linux-yocto_qemumips64 ?= "3.14%"
PREFERRED_VERSION_linux-yocto_qemuppc ?= "3.14%"
... snip ...

[edit] poky-lsb.conf

... snip ...
require conf/distro/poky.conf
require conf/distro/include/security_flags.inc
... snip ...

[edit] poky-bleeding.conf

PREFERRED_VERSION_glib-2.0 ?= "2.17.4"
PREFERRED_VERSION_glib-2.0-native ?= "2.17.4"
PREFERRED_VERSION_atk ?= "1.22.0"
PREFERRED_VERSION_pango ?= "1.21.2"
PREFERRED_VERSION_gtk+ ?= "2.13.3"

require conf/distro/include/poky-floating-revisions.inc
require conf/distro/poky.conf

[edit] Overriding the default preference

You might want to provide a cutting-edge recipe, without making it the default, by adding the following to the recipe file:

$ grep -r DEFAULT_PREFERENCE recipes-*
recipes-bsp/grub/grub_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-bsp/grub/grub_git.bb:DEFAULT_PREFERENCE_arm = "1"            <--- ARM only
recipes-core/busybox/busybox_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-devtools/pseudo/pseudo_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-devtools/qemu/qemu_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-devtools/pkgconfig/pkgconfig_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-devtools/rpm/rpm_5.4+cvs.bb:DEFAULT_PREFERENCE = "-1"
recipes-graphics/xorg-proto/xcb-proto_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-graphics/drm/libdrm_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-graphics/xorg-lib/libxcb_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-graphics/mesa/mesa_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-kernel/oprofile/oprofile_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/gstreamer/gstreamer1.0-plugins-good_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/gstreamer/gstreamer1.0-plugins-bad_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/gstreamer/gstreamer1.0-plugins-ugly_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/gstreamer/gstreamer1.0-libav_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/gstreamer/gstreamer1.0-plugins-base_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/gstreamer/gstreamer1.0-omx_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/gstreamer/gstreamer1.0_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-multimedia/libav/libav_9.13.bb:DEFAULT_PREFERENCE = "-1"
recipes-sato/matchbox-theme-sato/matchbox-theme-sato_git.bb:DEFAULT_PREFERENCE = "-1"
$

You can make the preference conditional, as in:

recipes-bsp/grub/grub_git.bb:DEFAULT_PREFERENCE = "-1"
recipes-bsp/grub/grub_git.bb:DEFAULT_PREFERENCE_arm = "1"



(Back to Poky)

Personal tools