blob: f3dfa8107abc0f9ee952c0948c97a124cec98156 [file] [log] [blame]
Patrick Williamsd8c66bc2016-06-20 12:57:21 -05001# Distribution definition for: poky-tiny
2#
3# Copyright (c) 2011, Intel Corporation.
4# All rights reserved.
5#
6# This file is released under the MIT license as described in
7# ../meta/COPYING.MIT.
8#
9# Poky-tiny is intended to define a tiny Linux system comprised of a
10# Linux kernel tailored to support each specific MACHINE and busybox.
11# Poky-tiny sets some basic policy to ensure a usable system while still
12# keeping the rootfs and kernel image as small as possible.
13#
14# The policies defined are intended to meet the following goals:
15# o Serial consoles only (no framebuffer or VGA console)
16# o Basic support for IPV4 networking
17# o Single user ash shell
18# o Static images (no support for adding packages or libraries later)
19# o Read-only or RAMFS root filesystem
20# o Combined Linux kernel + rootfs in under 4MB
21# o Allow the user to select between eglibc or uclibc with the TCLIBC variable
22#
23# This is currently a partial definition, the following tasks remain:
24# [ ] Integrate linux-yocto-tiny ktype into linux-yocto
25# [ ] Define linux-yocto-tiny configs for all supported BSPs
26# [ ] Drop ldconfig from the installation
27# [ ] Modify the runqemu scripts to work with ext2 parameter:
28# runqemu qemux86 qemuparams="-nographic" bootparams="console=ttyS0,115200 root=0800"
Andrew Geissler95ac1b82021-03-31 14:34:31 -050029# [ ] Modify busybox to allow for DISTRO_FEATURES-like configuration
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050030
31require conf/distro/poky.conf
Andrew Geissler09209ee2020-12-13 08:44:15 -060032require conf/distro/include/gcsections.inc
33
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050034DISTRO = "poky-tiny"
Patrick Williams03907ee2022-05-01 06:28:52 -050035DISTRO_NAME = "Poky Tiny"
Brad Bishop6e60e8b2018-02-01 10:27:11 -050036DISTROOVERRIDES = "poky:poky-tiny"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050037TCLIBC = "musl"
Andrew Geissler6ce62a22020-11-30 19:58:47 -060038
39FULL_OPTIMIZATION="-Os -pipe ${DEBUG_FLAGS}"
40
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050041# FIXME: consider adding a new "tiny" feature
42#DISTRO_FEATURES_append = " tiny"
43
44# Distro config is evaluated after the machine config, so we have to explicitly
45# set the kernel provider to override a machine config.
46PREFERRED_PROVIDER_virtual/kernel = "linux-yocto-tiny"
Patrick Williams169d7bc2024-01-05 11:33:25 -060047PREFERRED_VERSION_linux-yocto-tiny ?= "6.6%"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050048
49# We can use packagegroup-core-boot, but in the future we may need a new packagegroup-core-tiny
50#POKY_DEFAULT_EXTRA_RDEPENDS += "packagegroup-core-boot"
51# Drop kernel-module-af-packet from RRECOMMENDS
52POKY_DEFAULT_EXTRA_RRECOMMENDS = ""
53
54# FIXME: what should we do with this?
55TCLIBCAPPEND = ""
56
57# Disable wide char support for ncurses as we don't include it in
58# in the LIBC features below.
59# Leave native enable to avoid build failures
60ENABLE_WIDEC = "false"
Patrick Williams213cb262021-08-07 19:21:33 -050061ENABLE_WIDEC:class-native = "true"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050062
63# Drop native language support. This removes the
64# eglibc->bash->gettext->libc-posix-clang-wchar dependency.
65USE_NLS="no"
Patrick Williams03907ee2022-05-01 06:28:52 -050066# As we don't have native language support, don't install locales into images
67IMAGE_LINGUAS = ""
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050068
69# Comment out any of the lines below to disable them in the build
70# DISTRO_FEATURES options:
Brad Bishop393846f2019-05-20 12:24:11 -040071# alsa bluetooth ext2 pcmcia usbgadget usbhost wifi nfs zeroconf pci
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050072DISTRO_FEATURES_TINY = "pci"
73DISTRO_FEATURES_NET = "ipv4 ipv6"
74DISTRO_FEATURES_USB = "usbhost"
75#DISTRO_FEATURES_USBGADGET = "usbgadget"
76#DISTRO_FEATURES_WIFI = "wifi"
77
78DISTRO_FEATURES = "${DISTRO_FEATURES_TINY} \
79 ${DISTRO_FEATURES_NET} \
80 ${DISTRO_FEATURES_USB} \
81 ${DISTRO_FEATURES_USBGADGET} \
82 ${DISTRO_FEATURES_WIFI} \
83 "
84
Patrick Williams213cb262021-08-07 19:21:33 -050085DISTRO_FEATURES:class-native = "${DISTRO_FEATURES_DEFAULT} ${POKY_DEFAULT_DISTRO_FEATURES}"
86DISTRO_FEATURES:class-nativesdk = "${DISTRO_FEATURES_DEFAULT} ${POKY_DEFAULT_DISTRO_FEATURES}"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050087
Patrick Williamsc0f7c042017-02-23 20:41:17 -060088# enable mdev/busybox for init
Andrew Geisslerc5535c92023-01-27 16:10:19 -060089POKY_INIT_MANAGER:poky-tiny = "mdev-busybox"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -050090
91# FIXME: Consider adding "modules" to MACHINE_FEATURES and using that in
92# packagegroup-core-base to select modutils-initscripts or not. Similar with "net" and
93# netbase.
94
95# By default we only support initramfs. We don't build live as that
96# pulls in a lot of dependencies for the live image and the installer, like
97# udev, grub, etc. These pull in gettext, which fails to build with wide
98# character support.
99IMAGE_FSTYPES = "cpio.gz"
Andrew Geissler7e0e3c02022-02-25 20:34:39 +0000100QB_DEFAULT_FSTYPE = "cpio.gz"
Patrick Williamsc0f7c042017-02-23 20:41:17 -0600101
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500102# Drop v86d from qemu dependency list (we support serial)
103# Drop grub from meta-intel BSPs
104# FIXME: A different mechanism is needed here. We could define -tiny
105# variants of all compatible machines, but that leads to a lot
106# more machine configs to maintain long term.
107MACHINE_ESSENTIAL_EXTRA_RDEPENDS = ""
108
109# The mtrace script included by eglibc is a perl script. This means the system
110# will build perl in case this package is installed. Since we don't care about
111# this script for the purposes of tiny, remove the dependency from here.
Patrick Williams213cb262021-08-07 19:21:33 -0500112RDEPENDS:${PN}-mtrace:pn-eglibc = ""
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500113
Andrew Geissler7e0e3c02022-02-25 20:34:39 +0000114SKIP_RECIPE[build-appliance-image] = "not buildable with poky-tiny"
115SKIP_RECIPE[core-image-rt] = "not buildable with poky-tiny"
116SKIP_RECIPE[core-image-rt-sdk] = "not buildable with poky-tiny"
117SKIP_RECIPE[core-image-sato] = "not buildable with poky-tiny"
118SKIP_RECIPE[core-image-sato-dev] = "not buildable with poky-tiny"
119SKIP_RECIPE[core-image-sato-sdk] = "not buildable with poky-tiny"
120SKIP_RECIPE[core-image-x11] = "not buildable with poky-tiny"
121SKIP_RECIPE[core-image-weston] = "not buildable with poky-tiny"
Patrick Williamsd8c66bc2016-06-20 12:57:21 -0500122
123# Disable python usage in opkg-utils since it won't build with tiny config
Patrick Williams213cb262021-08-07 19:21:33 -0500124PACKAGECONFIG:remove:pn-opkg-utils = "python"
Patrick Williams2a254922023-08-11 09:48:11 -0500125
126# If shadow-base is brought into the image, logins will fail because it
127# doesn't have the heuristics to work when CONFIG_MULTIUSER is unset.
Patrick Williamsac13d5f2023-11-24 18:59:46 -0600128PACKAGE_EXCLUDE += "shadow-base"