builds and runs on intel-x86 and rpi4 with acceptable realtime performance
This commit is contained in:
1 parent
2bce6fa556
commit
3faf544f0b
120 files changed
+6317
-1
No files matched your search
@@ -0,0 +1,68 @@
|
||||
# Add profiling optimization type
|
||||
PROFILING_OPTIMIZATION = "${FULL_OPTIMIZATION} -fno-omit-frame-pointer -fvisibility=default"
|
||||
SELECTED_OPTIMIZATION[vardeps] += "PROFILING_OPTIMIZATION"
|
||||
|
||||
# Some packages have problems with PROFILING_OPTIMIZATION
|
||||
#
|
||||
# fix linking/relocating error
|
||||
PROFILING_OPTIMIZATION:remove:pn-llvm:powerpc = "-fno-omit-frame-pointer"
|
||||
# fix error: r7 cannot be used in asm here
|
||||
PROFILING_OPTIMIZATION:remove:pn-pulseaudio:arm = "-fno-omit-frame-pointer"
|
||||
# gcc-sanitizers makes extensive use of hidden visibility and frame pointer omission.
|
||||
# Trying to override that can cause build failures.
|
||||
PROFILING_OPTIMIZATION:pn-gcc-sanitizers = "${FULL_OPTIMIZATION}"
|
||||
# Fix traps: python[550] trap invalid opcode ip:b7f80f00 sp:bfb09a10 error:0 in ld-2.30.so[b7f7b000+1c000]
|
||||
PROFILING_OPTIMIZATION:remove:pn-glibc:x86 = "-fno-omit-frame-pointer"
|
||||
# Fix | stress-enosys.c: In function 'exercise_syscall':
|
||||
# | stress-enosys.c:230:1: error: bp cannot be used in 'asm' here
|
||||
# | 230 | }
|
||||
PROFILING_OPTIMIZATION:remove:pn-stress-ng:x86-64 = "-fno-omit-frame-pointer"
|
||||
PROFILING_OPTIMIZATION:remove:pn-stress-ng:x86 = "-fno-omit-frame-pointer"
|
||||
|
||||
# Set for SPDX 3
|
||||
SPDX_AUTHORS_openembedded_comment ??= "${DISTRO_NAME} ${DISTRO_VERSION}"
|
||||
SPDX_PACKAGE_VERSION ?= "${EXTENDPKGV}"
|
||||
|
||||
# PACKAGECONFIG settings for WRLinux
|
||||
include conf/distro/include/wrlinux-packageconfigs.inc
|
||||
|
||||
# MIRRORS are used only if we don't have a local copy, and the stated upstream
|
||||
# is no longer available.
|
||||
MIRRORS =+ "\
|
||||
git://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
|
||||
gitsm://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
|
||||
hg://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
|
||||
p4://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
|
||||
svn://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
|
||||
ftp://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
|
||||
http://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n \
|
||||
https://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n"
|
||||
|
||||
# dnsmasq and named (provided by bind) use the same default port 53:
|
||||
# | dnsmasq: failed to create listening socket for port 53: Address already in use
|
||||
# So disable the service by default, and if the user want to use both of them,
|
||||
# it need to be set to a different port in dnsmasq.conf before starting the service.
|
||||
INITSCRIPT_PARAMS:pn-dnsmasq = "stop 20 0 1 6 ."
|
||||
SYSTEMD_AUTO_ENABLE:pn-dnsmasq = "disable"
|
||||
|
||||
# Exclude download layers from eSDK.
|
||||
SDK_LAYERS_EXCLUDE_PATTERN ?= ".*-dl$ .*-dl-[0-9.]+$"
|
||||
|
||||
# do_kernel_version_sanity_check in oe-core checks if the defined version in
|
||||
# metadata(LINUX_VERSION) matches the version written in the source code. For
|
||||
# release branches we have Jenkins to take care of the version updating. For
|
||||
# CI/CD branch we aim to use the latest source and directly use Yocto kernel
|
||||
# source code which frequently gets updated. But oe-core does not tightly follow
|
||||
# the latest version. We don't necessarily frequently manually bump up the
|
||||
# version.
|
||||
KERNEL_VERSION_SANITY_SKIP = "1"
|
||||
|
||||
require conf/distro/include/plcos_security_flags.inc
|
||||
|
||||
# Enable predictable network interface names. This was intentionally
|
||||
# not supported in 10.22.33.x and earlier releases.
|
||||
#
|
||||
PNI_NAMES_FEATURES ??= "pni-names"
|
||||
DISTRO_FEATURES:append = " ${PNI_NAMES_FEATURES}"
|
||||
|
||||
EXTRA_IMAGEDEPENDS:remove:qemuriscv64:pn-${INITRAMFS_IMAGE} = "opensbi"
|
||||
@@ -0,0 +1,4 @@
|
||||
MAX_PAGE_SIZE_FLAGS ?= " -Wl,-z,max-page-size=0x10000"
|
||||
MAX_PAGE_SIZE_FLAGS:pn-lib32-systemd-boot = ""
|
||||
CFLAGS:append:virtclass-multilib-lib32 = "${MAX_PAGE_SIZE_FLAGS}"
|
||||
LDFLAGS:append:virtclass-multilib-lib32 = "${MAX_PAGE_SIZE_FLAGS}"
|
||||
@@ -0,0 +1,139 @@
|
||||
OSTREE_INITRAMFS_IMAGE ?= "initramfs-ostree-image"
|
||||
OSTREE_REPO ??= "${DEPLOY_DIR_IMAGE}/ostree_repo"
|
||||
|
||||
OSTREE_BRANCHNAME ??= "${IMAGE_BASENAME}"
|
||||
|
||||
# This is set to the name of the loader to include into a disk image
|
||||
# Not all BSPs will need this, so it can be unset by the BSP
|
||||
OSTREE_BOOTLOADER_INCLUDE ??= "${OSTREE_BOOTLOADER}"
|
||||
OSTREE_KERNEL_ARGS ??= "devmd=0"
|
||||
OSTREE_INST_ARGS ??= "devmd=0"
|
||||
|
||||
# The OSTREE_SKIP_BOOT_DIFF can be one of the following:
|
||||
# 0 = Perform a full fsck and boot diff
|
||||
# 1 = Skip the FSCK check
|
||||
# 2 = Skip the FSCK and the boot
|
||||
OSTREE_SKIP_BOOT_DIFF ??= "2"
|
||||
|
||||
# Generate rootfs.ostree.tar.bz2 files which could be used to build a new repo
|
||||
# OSTREE_CREATE_TARBALL = "1"
|
||||
|
||||
# Configuration of image upgrade and install variables
|
||||
|
||||
OSTREE_USE_AB ??= "0"
|
||||
OSTREE_REMOTE_NAME ??= "${OSTREE_OSNAME}"
|
||||
OSTREE_REMOTE_URL ??= ""
|
||||
|
||||
# WIC wks configuration variables follow
|
||||
# The selection of the wks file is:
|
||||
# Bootloader - ab/noab
|
||||
|
||||
OSTREE_ARCH_WKS:x86 ??= "ostree-grub"
|
||||
OSTREE_ARCH_WKS:x86-64 ??= "ostree-grub"
|
||||
|
||||
OSTREE_ARCH_WKS:arm ??= "ostree-uboot-sd"
|
||||
OSTREE_ARCH_WKS:armv7 ??= "ostree-uboot-sd"
|
||||
OSTREE_ARCH_WKS:armv7ve ??= "ostree-uboot-sd"
|
||||
OSTREE_ARCH_WKS:aarch64 ??= "ostree-uboot-sd"
|
||||
|
||||
OSTREE_AB_WKS ??= "${@oe.utils.conditional('OSTREE_USE_AB', '1', '-ab', '-noab', d)}"
|
||||
|
||||
OSTREE_USE_FIT ??= "0"
|
||||
|
||||
# Set a fixed size in the wks file for the various partitions from local.conf e.g.
|
||||
#OSTREE_WKS_EFI_SIZE = "--size=32M --overhead-factor 1"
|
||||
#OSTREE_WKS_BOOT_SIZE = "--size=300M --overhead-factor 1"
|
||||
#OSTREE_WKS_ROOT_SIZE = "--size=1024M --overhead-factor 1"
|
||||
#OSTREE_WKS_FLUX_SIZE = "--size=1024M --overhead-factor 1"
|
||||
|
||||
OSTREE_WKS_EFI_SIZE ??= "--size=32M"
|
||||
OSTREE_WKS_BOOT_SIZE ??= ""
|
||||
OSTREE_WKS_ROOT_SIZE ??= ""
|
||||
OSTREE_WKS_FLUX_SIZE ??= ""
|
||||
|
||||
# Parition type for /var
|
||||
OSTREE_FLUX_PART ??= "${@bb.utils.contains('DISTRO_FEATURES', 'luks', 'luksfluxdata', 'fluxdata',d)}"
|
||||
|
||||
# Name of the boot loader to include in the file system
|
||||
OSTREE_BOOTLOADER:x86 ??= 'grub'
|
||||
OSTREE_BOOTLOADER:x86-64 ??= 'grub'
|
||||
OSTREE_BOOTLOADER:arm ??= 'u-boot'
|
||||
OSTREE_BOOTLOADER:armv7 ??= 'u-boot'
|
||||
OSTREE_BOOTLOADER:armv7ve ??= 'u-boot'
|
||||
OSTREE_BOOTLOADER:aarch64 ??= 'u-boot'
|
||||
|
||||
# Define any special partitions required where loaders, firmware etc
|
||||
# live It is intended that these are defined by the BSP as needed
|
||||
OSTREE_SD_UBOOT_WIC1 ??= "part / --source rawcopy --sourceparams="file=${UBOOT_BINARY}" --ondisk mmcblk --no-table --align 1 --size 1"
|
||||
OSTREE_SD_UBOOT_WIC2 ??= ""
|
||||
OSTREE_SD_UBOOT_WIC3 ??= ""
|
||||
OSTREE_SD_UBOOT_WIC4 ??= ""
|
||||
|
||||
# The OSTREE_CONSOLE variable will control what kernel command line
|
||||
# parameters are passed for the console these should be formatted for
|
||||
# the boot loader specific to the BSP and the OSTREE_CONSOLE_AUX
|
||||
# should end with a SPACE
|
||||
OSTREE_CONSOLE_PRI ??= "console=tty1"
|
||||
OSTREE_CONSOLE_PRI:arm ??= "console=\${console},\${baudrate}"
|
||||
OSTREE_CONSOLE_PRI:armv7 ??= "console=\${console},\${baudrate}"
|
||||
OSTREE_CONSOLE_PRI:armv7ve ??= "console=\${console},\${baudrate}"
|
||||
OSTREE_CONSOLE_PRI:aarch64 ??= "console=\${console},\${baudrate}"
|
||||
|
||||
OSTREE_CONSOLE_AUX ??= "console=ttyS0,115200 "
|
||||
OSTREE_CONSOLE_AUX:x86 ??= "console=ttyS0,115200 "
|
||||
OSTREE_CONSOLE_AUX:x86-64 ??= "console=ttyS0,115200 "
|
||||
OSTREE_CONSOLE_AUX:arm ??= "console=tty0 "
|
||||
OSTREE_CONSOLE_AUX:armv7 ??= "console=tty0 "
|
||||
OSTREE_CONSOLE_AUX:armv7ve ??= "console=tty0 "
|
||||
OSTREE_CONSOLE_AUX:aarch64 ??= "console=tty0 "
|
||||
|
||||
OSTREE_CONSOLE ??= "${OSTREE_CONSOLE_AUX}${OSTREE_CONSOLE_PRI}"
|
||||
|
||||
# This is set to the name of the loader to include into a disk image
|
||||
# Not all BSPs will need this, so it can be unset by the BSP
|
||||
OSTREE_SD_BOOT_ALIGN ??= "4"
|
||||
|
||||
# Copy the IMAGE_BOOT_FILES when generating the ostree boot partition
|
||||
OSTREE_COPY_IMAGE_BOOT_FILES ??= "0"
|
||||
|
||||
# Use this WKS file with wic (WKS_FILE = "${OSTREE_WKS_FILE}" should be set in the feature
|
||||
# template or local.conf
|
||||
OSTREE_WKS_FILE ??= "${OSTREE_ARCH_WKS}${OSTREE_AB_WKS}.wks.in"
|
||||
|
||||
# Below are additional variables that can be set in local.conf which are the
|
||||
# defaults for the network installer
|
||||
|
||||
# Boot Loader Magic block offset (where the first partition should start in sectors)
|
||||
# NOTE: The FSZ, BSZ and RSZ are numeric in MB only e.g. OSTREE_FDISK_FSZ = "64"
|
||||
OSTREE_FDISK_BLM ??= "2506"
|
||||
# Size of the Fat / EFI partition
|
||||
OSTREE_FDISK_FSZ ??= "32"
|
||||
# Size of the Boot partition
|
||||
OSTREE_FDISK_BSZ ??= "200"
|
||||
# Size of the Root partition
|
||||
OSTREE_FDISK_RSZ ??= "1400"
|
||||
# Size of the /var partition 0 for fill disk
|
||||
OSTREE_FDISK_VSZ ??= "0"
|
||||
|
||||
# Allow the var directory to be erased via the initramfs boot, when
|
||||
# using "ostree_upgrade.sh -e". The default is 1, but for very secure
|
||||
# targets this could be a dangerous operation so it is configurable.
|
||||
# OSTREE_ALLOW_RM_VAR = "0"
|
||||
|
||||
# What uboot command should be used to start the kernel in the boot.scr file
|
||||
# OSTREE_UBOOT_CMD ??= "bootz"
|
||||
|
||||
# Use file system links for the ostree boot mounts (more secure and the default)
|
||||
# OSTREE_BOOTSCR ??= "fs_links"
|
||||
# Or read a uEnv.txt file from the disk which allows kernel args
|
||||
# to be controlled via ostree (less secure)
|
||||
# OSTREE_BOOTSCR ??= "env_import"
|
||||
|
||||
# Allow a BSP to specify extra cmds in the boot.scr if needed
|
||||
OSTREE_BOOTSCR_PRECMD ??= ""
|
||||
|
||||
# Grub settings for ostree
|
||||
OSTREE_GRUB_USER ??= "root"
|
||||
|
||||
OSTREE_KERNEL ??= "${KERNEL_IMAGETYPE}"
|
||||
RAMDISK_EXT ?= ".${INITRAMFS_FSTYPES}"
|
||||
@@ -0,0 +1,2 @@
|
||||
MULTILIBS ?= "multilib:lib32"
|
||||
DEFAULTTUNE:virtclass-multilib-lib32 ?= "armv7vethf"
|
||||
@@ -0,0 +1,3 @@
|
||||
MULTILIBS ?= "multilib:lib32"
|
||||
DEFAULTTUNE:virtclass-multilib-lib32 ?= "core2-32"
|
||||
|
||||
@@ -0,0 +1 @@
|
||||
# The recipes which are needed adjust during the build
|
||||
@@ -0,0 +1,20 @@
|
||||
# copied from meta-mentor/conf/distro/include/sstate.inc
|
||||
def lsb_distro_adjust(distro_id, ver):
|
||||
"""This hook ensures that RHEL server, RHEL client, and CentOS all return
|
||||
'RedHat' for distro, and '5' for the version, as we know minor
|
||||
versions for these distros are compatible, and these distros are
|
||||
compatible with one another."""
|
||||
|
||||
if distro_id in ('RedHatEnterpriseClient', 'RedHatEnterpriseServer',
|
||||
'CentOS'):
|
||||
distro_id = 'RedHat'
|
||||
|
||||
try:
|
||||
major_ver, _ = ver.split('.', 1)
|
||||
except ValueError:
|
||||
pass
|
||||
else:
|
||||
ver = major_ver
|
||||
return distro_id, ver
|
||||
|
||||
LSB_DISTRO_ADJUST = "lsb_distro_adjust"
|
||||
@@ -0,0 +1,17 @@
|
||||
# Base on oe-core security flags
|
||||
#include conf/distro/include/security_flags.inc
|
||||
|
||||
# To override for multilib, use SECURITY_CFLAGS:pn-<pkg>_pn-<mlib>-<pkg>.
|
||||
# If just SECURITY_CFLAGS:pn-<pkg> is defined, it will be used for all
|
||||
# multilib variants, too.
|
||||
|
||||
# Reason: The recipe vdso-test located in wrlinux which has assemble code
|
||||
SECURITY_CFLAGS:pn-vdso-test = ""
|
||||
|
||||
# Reason:
|
||||
# upstream meta-secure-core refuse to set var-SECURITY_STACK_PROTECTOR to
|
||||
# LDFLAGS and upstream oe-core refuse to remove var-SECURITY_STACK_PROTECTOR
|
||||
# from LDFLAGS
|
||||
SECURITY_LDFLAGS:remove:pn-libsign = "-fstack-protector-strong"
|
||||
SECURITY_LDFLAGS:remove:pn-cryptfs-tpm2 = "-fstack-protector-strong"
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
# PACKAGECONFIG settings of recipes for WRLinux
|
||||
|
||||
# Workaround for nmap possibly requiring python-pygtk which is not available
|
||||
PACKAGECONFIG:remove:pn-nmap = "zenmap"
|
||||
|
||||
# we usually use gnutls as the default PACKAGECONFIG of wpa-supplicant, but its sub-packege gnutls-openssl
|
||||
# is GPLv3, so need this check to switch to openssl if GLPv3 is blacklisted.
|
||||
PACKAGECONFIG:pn-wpa-supplicant ?= "${@bb.utils.contains('INCOMPATIBLE_LICENSE', 'GPL-3.0-only', 'openssl', 'gnutls', d)}"
|
||||
|
||||
PACKAGECONFIG:pn-sysstat ?= "${@bb.utils.filter('DISTRO_FEATURES', 'systemd', d)} lm-sensors cron"
|
||||
|
||||
PACKAGECONFIG:append:pn-mesa-demos = "${@bb.utils.contains('DISTRO_FEATURES', 'weston-demo', ' wayland ', ' ', d)}"
|
||||
@@ -0,0 +1,7 @@
|
||||
# PLC-OS Real-Time Operating System (with Graphics Support)
|
||||
|
||||
PLCOS_VARIANT = " Graphics"
|
||||
|
||||
require conf/distro/plcos.conf
|
||||
|
||||
DISTRO_FEATURES:append = " x11 opengl wayland vulkan polkit"
|
||||
@@ -0,0 +1,15 @@
|
||||
# Anaconda-based Installer for PLC-OS
|
||||
|
||||
require plcos-graphics.conf
|
||||
require conf/distro/anaconda.conf
|
||||
|
||||
PLCOS_VARIANT = " Installer"
|
||||
DISTRO = "anaconda"
|
||||
|
||||
IMAGE_FSTYPES:pn-wrlinux-image-installer:append = " live"
|
||||
|
||||
CUSTOMIZE_LOGOS ?= "plcos-logos"
|
||||
|
||||
#TODO remove all dependency on WRTEMPLATE
|
||||
# clear WRTEMPLATE for installer image
|
||||
WRTEMPLATE:anaconda = ""
|
||||
@@ -0,0 +1,105 @@
|
||||
#lighter-weight version of PLC-OS with smaller footprint but fewer features
|
||||
|
||||
# The following modifications to PLC-OS have been made or are planned for testing
|
||||
# x Serial only (no graphics)
|
||||
# x Basic IPV4 support (no IPV6)
|
||||
# x Single user shell
|
||||
# x Static images (no package management)
|
||||
# x Read-only or RAMFS root filesystem
|
||||
|
||||
# The current target for these efforts is:
|
||||
# x Complete Image size: under 1GB
|
||||
#
|
||||
|
||||
PLCOS_VARIANT = " Tiny"
|
||||
|
||||
require conf/distro/plcos.conf
|
||||
|
||||
# Distro config is evaluated after the machine config, so we have to explicitly
|
||||
# set the kernel provider to override a machine config.
|
||||
#TODO create recipe for "linux-yocto-rt-tiny"
|
||||
PREFERRED_PROVIDER_virtual/kernel = "linux-yocto-rt"
|
||||
|
||||
# Drop kernel-module-af-packet from RRECOMMENDS
|
||||
PLCOS_DEFAULT_EXTRA_RRECOMMENDS = ""
|
||||
|
||||
# Drop native language support.
|
||||
# this removes a significant dependency chain, reducing final size significantly
|
||||
USE_NLS = "no"
|
||||
# XXX-dev packages require pkgconfig, and are not currently supported on plcos-tiny.
|
||||
#This line disables pkgconfig
|
||||
ASSUME_PROVIDED += "pkgconfig$"
|
||||
|
||||
# Comment out any of the lines below to disable them in the build
|
||||
# DISTRO_FEATURES options:
|
||||
# alsa bluetooth ext2 irda pcmcia usbgadget usbhost wifi nfs zeroconf pci
|
||||
DISTRO_FEATURES_TINY = "pci"
|
||||
DISTRO_FEATURES_NET = "ipv4 ipv6"
|
||||
DISTRO_FEATURES_USB = "usbhost"
|
||||
#DISTRO_FEATURES_USBGADGET = "usbgadget"
|
||||
DISTRO_FEATURES_WIFI = "wifi"
|
||||
|
||||
DISTRO_FEATURES = "${DISTRO_FEATURES_TINY} \
|
||||
${DISTRO_FEATURES_NET} \
|
||||
${DISTRO_FEATURES_USB} \
|
||||
${DISTRO_FEATURES_USBGADGET} \
|
||||
${DISTRO_FEATURES_WIFI} \
|
||||
"
|
||||
|
||||
# Enable LFS - see bug YOCTO #5865
|
||||
DISTRO_FEATURES:append:libc-musl = " largefile"
|
||||
|
||||
# From poky:
|
||||
PLCOS_DEFAULT_DISTRO_FEATURES = "largefile opengl ptest multiarch wayland vulkan"
|
||||
|
||||
DISTRO_FEATURES:class-native = "${DISTRO_FEATURES_DEFAULT} ${WRLINUX_DEFAULT_DISTRO_FEATURES}"
|
||||
DISTRO_FEATURES:class-nativesdk = "${DISTRO_FEATURES_DEFAULT} ${WRLINUX_DEFAULT_DISTRO_FEATURES}"
|
||||
|
||||
# enable mdev/busybox for init
|
||||
INIT_MANAGER = "mdev-busybox"
|
||||
VIRTUAL-RUNTIME_no-busybox = ""
|
||||
|
||||
# FIXME: Consider adding "modules" to MACHINE_FEATURES and using that in
|
||||
# packagegroup-core-base to select modutils-initscripts or not. Similar with "net" and
|
||||
# netbase.
|
||||
|
||||
# By default we only support initramfs and tar.bz2. We don't build live as that
|
||||
# pulls in a lot of dependencies for the live image and the installer, like
|
||||
# udev, grub, etc. These pull in gettext, which fails to build with wide
|
||||
# character support.
|
||||
IMAGE_FSTYPES += "cpio.gz tar.bz2"
|
||||
|
||||
# Drop v86d from qemu dependency list (we support serial)
|
||||
# Drop grub from meta-intel BSPs
|
||||
# FIXME: A different mechanism is needed here. We could define -tiny
|
||||
# variants of all compatible machines, but that leads to a lot
|
||||
# more machine configs to maintain long term.
|
||||
MACHINE_ESSENTIAL_EXTRA_RDEPENDS = ""
|
||||
|
||||
# The mtrace script included by glibc is a perl script. This means the system
|
||||
# will build perl in case this package is installed. Since we don't care about
|
||||
# this script for the purposes of tiny, remove the dependency from here.
|
||||
RDEPENDS:${PN}-mtrace:pn-glibc = ""
|
||||
|
||||
SKIP_RECIPE[build-appliance-image] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-base] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-clutter] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-full-cmdline] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-rt] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-rt-sdk] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-sato] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-sato-dev] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-sato-sdk] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-x11] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[core-image-weston] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[plcos-image-sato] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[plcos-image-weston] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[plcos-image-base] = "not buildable with plcos-tiny"
|
||||
SKIP_RECIPE[plcos-image-dev] = "not buildable with plcos-tiny"
|
||||
|
||||
# Disable python usage in opkg-utils since it won't build with tiny config
|
||||
PACKAGECONFIG:pn-opkg-utils = "update-alternatives"
|
||||
PACKAGECONFIG:pn-lib32-opkg-utils = "update-alternatives"
|
||||
|
||||
TEMPLATES_PATH = "${LAYER_PATH_plcos}/plcos-distro/templates"
|
||||
WRTEMPLATE:append = " feature/posix-timers"
|
||||
@@ -0,0 +1,281 @@
|
||||
|
||||
#@TYPE: Distro
|
||||
#@NAME: PLC-OS
|
||||
#@DESCRIPTION: Open Source Realtime OS for running PLC logic (Full Featured Distribution)
|
||||
|
||||
# we want to use rsyslog as the default syslog, but it's GPLv3, so need this
|
||||
# check to switch to sysklogd if GLPv3 is blacklisted.
|
||||
VIRTUAL-RUNTIME_syslog ?= "${@bb.utils.contains('INCOMPATIBLE_LICENSE', 'GPL-3.0-only', 'sysklogd', 'rsyslog', d)}"
|
||||
VIRTUAL-RUNTIME_base-utils-syslog ?= "${VIRTUAL-RUNTIME_syslog}"
|
||||
|
||||
# 1. for xfce, The networkmanager is required by xfce4-power-manager,
|
||||
# and it conflicts with connman. The setting can avoid connman-gnome
|
||||
# be added to packagegroup-core-x11-sato's RDEPENDS (when build image plcos-image-glibc-std-sato).
|
||||
# 2. for std-sato image, bind also conflicts with connman, this can avoid
|
||||
# connman-gnome be added to packagegroup-core-x11-sato's RDEPENDS
|
||||
NETWORK_MANAGER = ""
|
||||
|
||||
# common plcos distro definitions
|
||||
#
|
||||
#############################################################################################################
|
||||
# We need this to add multilib support to the built-in QEMU BSPs
|
||||
include conf/distro/include/plcos-bsp-${MACHINE}.inc
|
||||
|
||||
MAINTAINER = "Vaughn Varma <vaughnvarma@gmail.com>"
|
||||
|
||||
PLCOS_VARIANT ??= ""
|
||||
PLCOS_NAME = "PLC-OS"
|
||||
PLCOS_VERSION ??= "0.1"
|
||||
PLCOS_UPDATE_VERSION = "0"
|
||||
PLCOS_BRANCH ?= ""
|
||||
#this may not be necessary, but is just for parity with poky
|
||||
DISTRO = "plcos"
|
||||
DISTRO_NAME ?= "${PLCOS_NAME}${PLCOS_VARIANT}"
|
||||
|
||||
DISTRO_VERSION ?= "${PLCOS_VERSION}"
|
||||
SDK_VERSION ?= "${PLCOS_VERSION}"
|
||||
SDK_VERSION[vardepvalue] = "${SDK_VERSION}"
|
||||
DISTRO_PRETTY_VERSION ?= "${PLCOS_VERSION}${@' Update ${PLCOS_UPDATE_VERSION}' if d.getVar('PLCOS_UPDATE_VERSION') != '0' else ''}"
|
||||
#TODO release own distro codename
|
||||
DISTRO_CODENAME ?= "wrynose"
|
||||
|
||||
#TODO: build own SDK
|
||||
#SDK_VENDOR = "-wrlinuxsdk"
|
||||
SDK_VENDOR = "-pokysdk"
|
||||
#TARGET_VENDOR = "-wrs"
|
||||
#possible issue of this making full path names too long??
|
||||
TARGET_VENDOR = "-poky"
|
||||
|
||||
# Append 'osv-wrlinux' to the DISTROOVERRIDE
|
||||
DISTROOVERRIDES:append = "${@['', ':'][(d.getVar('DISTRO', True) != '')]}poky"
|
||||
|
||||
LOCALCONF_VERSION = "2"
|
||||
|
||||
#from wrlinux
|
||||
#SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${TARGET_ARCH}"
|
||||
#SDK_PS1 ??= "(wrlinuxsdk-${SDK_ARCH}-${TARGET_ARCH}) \${PS1#(wrlinuxsdk-${SDK_ARCH}-${TARGET_ARCH}) }"
|
||||
#from poky
|
||||
SDK_NAME = "${DISTRO}-${TCLIBC}-${SDKMACHINE}-${IMAGE_BASENAME}-${TUNE_PKGARCH}-${MACHINE}"
|
||||
SDKPATHINSTALL = "/opt/${DISTRO}/${SDK_VERSION}"
|
||||
#TCSDKMACH = "${@['', '_${SDK_OS}']['${SDK_OS}' != 'linux']}"
|
||||
#TOOLCHAIN_OUTPUTNAME = "${DISTRO}-${DISTRO_VERSION}-${TCLIBC}-${SDK_ARCH}${TCSDKMACH}-${MACHINE_ARCH}-${PN}-sdk"
|
||||
#TOOLCHAINEXT_OUTPUTNAME = "${DISTRO}-${DISTRO_VERSION}-${TCLIBC}-${SDK_ARCH}${TCSDKMACH}-${MACHINE_ARCH}-${PN}-sdk-ext"
|
||||
|
||||
#TOOLCHAIN_OUTPUTNAME:pn-buildtools-tarball:forcevariable = "${SDK_ARCH}-buildtools-nativesdk-standalone-${DISTRO_VERSION}"
|
||||
|
||||
# Workaround for extensible SDK
|
||||
#TOOLCHAIN_OUTPUTNAME:pn-uninative-tarball = "${SDK_ARCH}-nativesdk-libc"
|
||||
#ESDK_CLASS_INHERIT_DISABLE:append = " packagefeed-stability"
|
||||
|
||||
# Override these in wrlinux based distros to modify DISTRO_*
|
||||
|
||||
|
||||
#CORE_IMAGE_BASE_INSTALL:append = " packagegroup-core-boot-wrs "
|
||||
PLCOS_DEFAULT_DISTRO_FEATURES = "multiarch ptest"
|
||||
#PLCOS_DEFAULT_DISTRO_FEATURES = "largefile multiarch pulseaudio kvm virtualization"
|
||||
PLCOS_DEFAULT_EXTRA_RDEPENDS = "packagegroup-core-boot packagegroup-plcos-core"
|
||||
#PLCOS_DEFAULT_EXTRA_RDEPENDS += " packagegroup-core-boot-wrs"
|
||||
PLCOS_DEFAULT_EXTRA_RRECOMMENDS = "kernel-module-af-packet"
|
||||
|
||||
#DISTRO_FEATURES:append = "${DISTRO_FEATURES_DEFAULTS} ${PLCOS_DEFAULT_DISTRO_FEATURES}"
|
||||
DISTRO_FEATURES ?= "${DISTRO_FEATURES_DEFAULTS} ${PLCOS_DEFAULT_DISTRO_FEATURES}"
|
||||
#DISTRO_FEATURES:class-native ?= "${DISTRO_FEATURES_DEFAULTS} ${PLCOS_DEFAULT_DISTRO_FEATURES}"
|
||||
#DISTRO_FEATURES:class-nativesdk ?= "${DISTRO_FEATURES_DEFAULTS} ${PLCOS_DEFAULT_DISTRO_FEATURES}"
|
||||
DISTRO_EXTRA_RDEPENDS += " ${PLCOS_DEFAULT_EXTRA_RDEPENDS}"
|
||||
DISTRO_EXTRA_RRECOMMENDS += " ${PLCOS_DEFAULT_EXTRA_RRECOMMENDS}"
|
||||
|
||||
# do not include qemu-config by default
|
||||
#WRLINUXQEMUDEPS = "${@bb.utils.contains("INCOMPATIBLE_LICENSE", "GPL-3.0-only", "", "qemu-config",d)}"
|
||||
#WRLINUXQEMUDEPS = ""
|
||||
|
||||
#DISTRO_EXTRA_RDEPENDS:append:qemuall = " ${WRLINUXQEMUDEPS}"
|
||||
|
||||
#TCLIBCAPPEND = ""
|
||||
|
||||
#default locale / local language processing settings
|
||||
#IMAGE_LINGUAS ?= ""
|
||||
|
||||
# The CONNECTIVITY_CHECK_URI's are used to test whether we can succesfully
|
||||
# fetch from the network (and warn you if not). To disable the test set
|
||||
# the variable to be empty.
|
||||
#CONNECTIVITY_CHECK_URIS ?= "https://www.example.com/"
|
||||
|
||||
|
||||
#TODO evaluate which of these are necessary, modify or replace them to ensure full open source compliance
|
||||
#currently some of these files are from wrlinux
|
||||
#require conf/distro/include/poky-world-exclude.inc
|
||||
#require conf/distro/include/no-static-libs.inc
|
||||
#require conf/distro/include/plcos-uninative.inc
|
||||
#require packagegroup-core-base-utils.inc
|
||||
#require conf/distro/include/plcos_security_flags.inc
|
||||
#require conf/distro/include/plcos-space-optimize.inc
|
||||
|
||||
# Default hash policy for distro
|
||||
#BB_SIGNATURE_HANDLER ?= 'OEBasicHash'
|
||||
BB_SIGNATURE_HANDLER ?= "OEEquivHash"
|
||||
BB_HASHSERVE ??= "auto"
|
||||
INIT_MANAGER ?= "systemd"
|
||||
|
||||
# QA check settings - a little stricter than the OE-Core defaults
|
||||
WARN_TO_ERROR_QA ?= "already-stripped compile-host-path install-host-path \
|
||||
installed-vs-shipped ldflags pn-overrides rpaths staticdev \
|
||||
unknown-configure-option useless-rpaths"
|
||||
WARN_QA:remove = "${WARN_TO_ERROR_QA}"
|
||||
ERROR_QA:append = " ${WARN_TO_ERROR_QA}"
|
||||
|
||||
# Change base package dependency in -dbg packages from recommends to suggests
|
||||
#RRECOMMENDS:${PN}-dbg = ""
|
||||
#RSUGGESTS:${PN}-dbg = "${PN} (= ${EXTENDPKGV})"
|
||||
|
||||
|
||||
# Make sure that ldconfig is only enabled when the user has added ldconfig
|
||||
# to the DISTRO_FEATURES
|
||||
#This was set to BACKFILL_CONSIDERED in previous yocto versions, it seems the change may be breaking something for intel-x86
|
||||
#DISTRO_FEATURES_OPTED_OUT += "ldconfig"
|
||||
|
||||
# Make sure that X11 is only enabled in a graphics configuration
|
||||
#DISTRO_FEATURES_OPTED_OUT += "x11"
|
||||
|
||||
# Multilib configuration
|
||||
MULTILIBS ?= ""
|
||||
MULTILIB_CONF = "${@'conf/multilib.conf' if d.getVar('MULTILIBS') and d.getVar('PACKAGE_CLASSES').split()[0] != 'package_deb' else ''}"
|
||||
require ${MULTILIB_CONF}
|
||||
|
||||
# only support realtime kernels. This OS is focused on realtime performance
|
||||
TARGET_SUPPORTED_KTYPES = "preempt-rt"
|
||||
PREFERRED_PROVIDER_virtual/kernel = "linux-yocto-rt"
|
||||
|
||||
# Blacklisted Packages
|
||||
#SKIP_RECIPE[xyz-abc] ?= "Recipe xyz-abc is blacklisted via SKIP_RECIPE"
|
||||
|
||||
# SANITY_TESTED_DISTROS used to defined the distribution list which we used to build PLC-OS
|
||||
SANITY_TESTED_DISTROS ?= " \
|
||||
ubuntu-24.04 \n \
|
||||
"
|
||||
|
||||
# TODO: This works, but OE documentation recommends either working with the DISTRO_FEATURES variable, or with the DISTRO_FEATURES_OPTED_OUT variable
|
||||
#Same with the MACHINE_FEATURES_OPTED_OUT
|
||||
DISTRO_FEATURES_DEFAULTS:remove:class-target = "x11"
|
||||
DISTRO_FEATURES_DEFAULTS:remove:class-target = "wayland"
|
||||
DISTRO_FEATURES_DEFAULTS:remove:class-target = "vulkan"
|
||||
DISTRO_FEATURES_DEFAULTS:remove:class-target = "3g"
|
||||
DISTRO_FEATURES_DEFAULTS:remove:class-target = "nfc"
|
||||
DISTRO_FEATURES_DEFAULTS:remove:class-target = "nfs"
|
||||
MACHINE_FEATURES:remove:class-target = "3g"
|
||||
MACHINE_FEATURES:remove:class-target = "nfc"
|
||||
|
||||
#ran into an issue where leaving pcbios on meant that the installed EFI would boot into the installer USB by default, despite BIOS settings
|
||||
MACHINE_FEATURES:remove:class-target = "pcbios"
|
||||
#we are using grub-efi for tuned; this is automatically included in x86 and SystemReady ARM configurations, but must be included for *all* architectures, including non-SystemReady ARM devices such as raspberry pi, which must chain-load u-boot into efi
|
||||
MACHINE_FEATURES:append = " efi"
|
||||
|
||||
#PLCOS_DEFAULT_DISTRO_FEATURES += "pam"
|
||||
|
||||
# Native sstate should not depend on multilib provider whitelist
|
||||
#BB_MULTI_PROVIDER_ALLOWED:class-native:forcevariable = ""
|
||||
|
||||
# Configure the root user's home directory
|
||||
#ROOT_HOME ?= "/root"
|
||||
|
||||
# initramfs image for plcos distro
|
||||
#TODO investigate having own initramfs image; wrlinux has its own, but this one should be the yocto one
|
||||
INITRD_IMAGE_LIVE ?= "${@d.getVar('INITRAMFS_IMAGE', True) if d.getVar('INITRAMFS_IMAGE', True) else 'core-image-minimal-initramfs'}"
|
||||
|
||||
# The providers are fftwf, fftwl, fftw
|
||||
PREFERRED_PROVIDER_virtual/fftw = "fftw"
|
||||
|
||||
# Set the default psplash from psplash-default to psplash-windriver
|
||||
|
||||
## Syslinux options for boot menus when using isolinux or linux live
|
||||
SYSLINUX_TIMEOUT = "50"
|
||||
#SYSLINUX_SPLASH = "${@oe.utils.conditional('WRLINUX_BRANCH', 'LTS', '${LAYER_PATH_plcos}/files/syslinux/bootloading-blue-wrl.png', '${LAYER_PATH_plcos}/files/syslinux/bootloading-gray-wrl.png', d)}"
|
||||
SYSLINUX_SPLASH = "${LAYER_PATH_meta-realtime}/recipes-extended/psplash/files/psplash-plcos-img.png"
|
||||
AUTO_SYSLINUXMENU = "1"
|
||||
|
||||
## "1" = Have graphics and serial in the boot menu when use grub-efi in iso
|
||||
GRUB_GFXSERIAL = "0"
|
||||
GRUB_TIMEOUT = "5"
|
||||
|
||||
# Possibly eliminate busybox from an image. The variables defined here
|
||||
# are used by oe-core packagegroup-core-boot.bb. The overrides are
|
||||
# DISTRO names.
|
||||
VIRTUAL-RUNTIME_login_manager = "shadow"
|
||||
|
||||
# We assume that we provide base-utils. This variable must
|
||||
# empty or one item.
|
||||
#
|
||||
#VIRTUAL-RUNTIME_base-utils = "packagegroup-core-base-utils"
|
||||
|
||||
# This runs the busybox-hwclock script during systemv
|
||||
# init. This does NOT supply /sbin/hwclock, only a script!
|
||||
#
|
||||
VIRTUAL-RUNTIME_base-utils-hwclock = "busybox-hwclock"
|
||||
|
||||
# Supply replacements for busybox functions we really, really need.
|
||||
#
|
||||
VIRTUAL-RUNTIME_no-busybox = "packagegroup-core-base-utils"
|
||||
|
||||
#TODO: check if valuable, disabled for parity with poky
|
||||
#IMAGE_INSTALL:append = " ${VIRTUAL-RUNTIME_no-busybox}"
|
||||
|
||||
PREFERRED_PROVIDER_virtual/kernel ?= "linux-yocto-rt"
|
||||
|
||||
INHERIT += "ext_secure_cflags wrlinux-metadata_scm"
|
||||
|
||||
# Support distro features override
|
||||
INHERIT += "distrooverrides"
|
||||
|
||||
INHERIT += "poky-sanity"
|
||||
|
||||
# Define WR sample keys directory
|
||||
#WR_SAMPLE_KEYS_DIR ?= "${LAYER_PATH_plcos-distro}/files/sample-keys"
|
||||
|
||||
# By default the sample keys are used
|
||||
#WR_KEYS_DIR ?= "${WR_SAMPLE_KEYS_DIR}"
|
||||
|
||||
PREFERRED_VERSION_linux-yocto ?= "6.18%"
|
||||
PREFERRED_VERSION_linux-yocto-rt ?= "6.18%"
|
||||
PREFERRED_VERSION_linux-yocto-tiny ?= "6.18%"
|
||||
|
||||
# Third party download notice
|
||||
#INHERIT += "third-party-dl"
|
||||
|
||||
|
||||
# Enable VENDOR REVISION for CVE patches
|
||||
#VENDOR_REVISION_PREFIX ?= ".wr"
|
||||
#INHERIT += "enable-vendor-revision"
|
||||
|
||||
# Extend CLANG_EXTRA_OE_DISTRO to make clang work well on plcos host. See usage in meta-clang.
|
||||
# TODO: check if needed or helpful. removed for parity with poky
|
||||
#CLANG_EXTRA_OE_DISTRO:append = " plcos-graphics:poky plcos:poky"
|
||||
|
||||
#INHERIT += "uninative"
|
||||
#INHERIT += "create-spdx"
|
||||
# We need debug symbols so that SPDX license manifests for the kernel work
|
||||
KERNEL_EXTRA_FEATURES:append = " features/debug/debug-kernel.scc"
|
||||
KERNEL_FEATURES:append = " ${KERNEL_EXTRA_FEATURES}"
|
||||
KERNEL_FEATURES:append = " tuning-and-support.scc"
|
||||
|
||||
EFI_PROVIDER = "grub-efi"
|
||||
|
||||
#default device hostname
|
||||
hostname:pn-base-files = "plc"
|
||||
WKS_FILE:x86 = "plcos-bootdisk-x86.wks.in"
|
||||
WKS_FILE:x86-64 = "plcos-bootdisk-x86.wks.in"
|
||||
WKS_FILE:intel-x86-common = "plcos-bootdisk-intel.wks.in"
|
||||
|
||||
WKS_FILE:aarch64 = "plcos-bootdisk-arm.wks.in"
|
||||
|
||||
DISTRO_FEATURES:append = " pam opengl usbhost largefile "
|
||||
#DISTRO_FEATURES:append = " x11 wayland virtualization "
|
||||
|
||||
#TODO remove WRLinux
|
||||
# The overrides osv-wrlinux will enable wrlinux specific bbappend
|
||||
OVERRIDES:append = ":osv-wrlinux"
|
||||
INHERIT += "rtopts"
|
||||
APPEND += "rcu_nocb_poll nmi-watchdog=0 processor.max_cstate=1 noefi irqaffinity=0"
|
||||
ROOTFS_POSTPROCESS_COMMAND += " set_kernel_opts;"
|
||||
TARGET_SUPPORTED_KTYPES:append = " preempt-rt"
|
||||
DISTRO_FEATURES_DEFAULTS:append = " usbhost"
|
||||
# use systemd as the default init manager
|
||||
INIT_MANAGER = "systemd"
|
||||
Reference in new issue
Block a user