diff options
Diffstat (limited to 'meta-agl-core')
133 files changed, 1667 insertions, 1024 deletions
diff --git a/meta-agl-core/classes/agl-core-image.bbclass b/meta-agl-core/classes/agl-core-image.bbclass new file mode 100644 index 000000000..bb5580391 --- /dev/null +++ b/meta-agl-core/classes/agl-core-image.bbclass @@ -0,0 +1,32 @@ +# AGL base image class +# +# As opposed to using core-image directly, this class: +# - does not pull in packagegroup-base-extended by default to minimize images. +# This does mean that many of the oe-core / poky MACHINE and DISTRO features +# (e.g. 3g, nfs, etc.) will not result in packages being automatically pulled +# into images since that is driven via packagegroup-base. +# - includes hooks for integrating SELinux via meta-selinux +# - disables locale installation by default +# + +# Disable locales +IMAGE_LINGUAS = "" + +# Hook to allow inheriting e.g. selinux-image by default. +# Any bbclass used as a value should ultimately inherit core-image +AGL_BASE_IMAGE ?= "core-image" + +inherit ${AGL_BASE_IMAGE} + +FEATURE_PACKAGES_selinux = " \ + packagegroup-agl-core-selinux \ + ${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'packagegroup-agl-core-selinux-devel', '', d)} \ +" + +IMAGE_FEATURES:append = " ${@bb.utils.filter('DISTRO_FEATURES', 'selinux', d)}" + +CORE_IMAGE_BASE_INSTALL = " \ + packagegroup-agl-core-boot \ + \ + ${CORE_IMAGE_EXTRA_INSTALL} \ +" diff --git a/meta-agl-core/classes/agl-crosssdk.bbclass b/meta-agl-core/classes/agl-crosssdk.bbclass new file mode 100644 index 000000000..5f6dbf303 --- /dev/null +++ b/meta-agl-core/classes/agl-crosssdk.bbclass @@ -0,0 +1,9 @@ +IMAGE_FEATURES += "dev-pkgs" +IMAGE_INSTALL += "kernel-dev kernel-devsrc" + +inherit populate_sdk + +# Task do_populate_sdk and do_rootfs can't be exec simultaneously. +# Both exec "createrepo" on the same directory, and so one of them +# can failed (randomly). +addtask do_populate_sdk after do_rootfs diff --git a/meta-agl-core/conf/distro/include/aarch64-tune.inc b/meta-agl-core/conf/distro/include/aarch64-tune.inc index 320b4f1ac..4628fcaf2 100644 --- a/meta-agl-core/conf/distro/include/aarch64-tune.inc +++ b/meta-agl-core/conf/distro/include/aarch64-tune.inc @@ -4,7 +4,9 @@ # A double inclusion would produce a warning. This include line is just for reference # include conf/machine/include/arm/arch-armv8.inc -DEFAULTTUNE:poky-agl := "aarch64" +AGL_DEFAULTTUNE ?= "aarch64" +DEFAULTTUNE:agldefaulttune = "${AGL_DEFAULTTUNE}" + # not yet ready #QB_SYSTEM_NAME ?= "qemu-system-aarch" #QB_DEFAULT_KERNEL ?= "zImage" diff --git a/meta-agl-core/conf/distro/include/arm-tune.inc b/meta-agl-core/conf/distro/include/arm-tune.inc index fa68e05a7..b3ad64ad7 100644 --- a/meta-agl-core/conf/distro/include/arm-tune.inc +++ b/meta-agl-core/conf/distro/include/arm-tune.inc @@ -7,14 +7,16 @@ # include conf/machine/include/arch/arm-armv7-a.inc # Standard target for 32bit ARM (newer than cortex-a15) -AGLDEFAULTTUNE = "armv7vethf-neon-vfpv4" +ARM_DEFAULTTUNE = "armv7vethf-neon-vfpv4" # for cortex-a8, cortex-a9, cortex-a7 (=rpi 2/3) -AGLDEFAULTTUNE := "${@bb.utils.contains('DISTRO_FEATURES', 'agl-medium-arm-compiler', 'armv7athf-neon', '${AGLDEFAULTTUNE}', d)}" +ARM_DEFAULTTUNE := "${@bb.utils.contains('DISTRO_FEATURES', 'agl-medium-arm-compiler', 'armv7athf-neon', '${ARM_DEFAULTTUNE}', d)}" # for armv6 (=rpi0/1) -AGLDEFAULTTUNE := "${@bb.utils.contains('DISTRO_FEATURES', 'agl-low-arm-compiler', 'arm1176jzfshf', '${AGLDEFAULTTUNE}', d)}" -DEFAULTTUNE := "${AGLDEFAULTTUNE}" +ARM_DEFAULTTUNE := "${@bb.utils.contains('DISTRO_FEATURES', 'agl-low-arm-compiler', 'arm1176jzfshf', '${ARM_DEFAULTTUNE}', d)}" + +AGL_DEFAULTTUNE ?= "${ARM_DEFAULTTUNE}" +DEFAULTTUNE:agldefaulttune := "${AGL_DEFAULTTUNE}" QB_SYSTEM_NAME ?= "qemu-system-arm" QB_DEFAULT_KERNEL ?= "zImage" diff --git a/meta-agl-core/conf/distro/include/riscv64-tune.inc b/meta-agl-core/conf/distro/include/riscv64-tune.inc index f8118dec3..981fc4283 100644 --- a/meta-agl-core/conf/distro/include/riscv64-tune.inc +++ b/meta-agl-core/conf/distro/include/riscv64-tune.inc @@ -4,4 +4,5 @@ # A double inclusion would produce a warning. This include line is just for reference # include conf/machine/include/arm/arch-armv8.inc -DEFAULTTUNE = "riscv64" +AGL_DEFAULTTUNE ?= "riscv64" +DEFAULTTUNE:agldefaulttune = "${AGL_DEFAULTTUNE}" diff --git a/meta-agl-core/conf/distro/include/x86_64-tune.inc b/meta-agl-core/conf/distro/include/x86_64-tune.inc index 4e5bb9fda..541b729b6 100644 --- a/meta-agl-core/conf/distro/include/x86_64-tune.inc +++ b/meta-agl-core/conf/distro/include/x86_64-tune.inc @@ -3,7 +3,8 @@ # We should not need the tuning include below as the BSP should include the right set already. # A double inclusion would produce a warning. This include line is just for reference #include conf/machine/include/tune-corei7.inc -DEFAULTTUNE = "corei7-64" +AGL_DEFAULTTUNE ?= "corei7-64" +DEFAULTTUNE:agldefaulttune = "${AGL_DEFAULTTUNE}" # shortened copy of tune-corei7.inc due to bug in inclusion for tune-core2.inc # TUNE_ARCH is using .= x86-64 , if done twice, you get x86-64x86-64 as TUNE_ARCH :/ diff --git a/meta-agl-core/conf/distro/poky-agl.conf b/meta-agl-core/conf/distro/poky-agl.conf index e13ce6f04..266a06d70 100644 --- a/meta-agl-core/conf/distro/poky-agl.conf +++ b/meta-agl-core/conf/distro/poky-agl.conf @@ -1,35 +1,36 @@ require conf/distro/poky.conf +# Insert overrides "agldefaulttune" and "forcedefaulttune" before forcevariable +OVERRIDES = "${TARGET_OS}:${TRANSLATED_TARGET_ARCH}:pn-${PN}:${MACHINEOVERRIDES}:${DISTROOVERRIDES}:${CLASSOVERRIDE}${LIBCOVERRIDE}:agldefaulttune:forcedefaulttune:forcevariable" + # AGL specific derivations DISTRO = "poky-agl" DISTRO_NAME = "Automotive Grade Linux" # Release flags -DISTRO_CODENAME = "needlefish" +DISTRO_CODENAME = "ricefish" AGL_BRANCH = "master" -AGLVERSION = "13.90.0" +AGLVERSION = "17.90.0" + # switch devel/release -AGLRELEASETYPE ?= "agldevelopment" -#AGLRELEASETYPE ?= "aglrelease" +#AGLRELEASETYPE ?= "agldevelopment" +AGLRELEASETYPE := "aglrelease" + OVERRIDES .= ":${AGLRELEASETYPE}" -# #for development DISTRO_VERSION:agldevelopment := "${AGLVERSION}+snapshot-${METADATA_REVISION}" -AGL_APP_REVISION:agldevelopment = "${AUTOREV}" -AGL_DEFAULT_REVISION:agldevelopment = "${AUTOREV}" #for release DISTRO_VERSION:aglrelease := "${AGLVERSION}" DISTRO_BRANCH_VERSION_TAG = "${DISTRO_CODENAME}/${@'${DISTRO_VERSION}'.replace('+snapshot-${METADATA_REVISION}','')}" -AGL_APP_REVISION:aglrelease := "refs/tags/${DISTRO_BRANCH_VERSION_TAG}" -AGL_DEFAULT_REVISION:aglrelease := "refs/tags/${DISTRO_BRANCH_VERSION_TAG}" # reproducible builds: # Set the desired timestamps -export SOURCE_DATE_EPOCH = "1593400000" -REPRODUCIBLE_TIMESTAMP_ROOTFS = "1593400000" +# E.g. update for (major) releases +export SOURCE_DATE_EPOCH = "1706800000" +REPRODUCIBLE_TIMESTAMP_ROOTFS = "1706800000" # SDK @@ -105,11 +106,6 @@ CONNECTIVITY_CHECK_URIS ?= "" # Not yet upstreamed; should be submitted. SECURITY_CFLAGS:pn-qtwebengine = "${SECURITY_NO_PIE_CFLAGS}" -#Redefined USER_CLASSES -#Disable prelink. It is unmaintained and likely will go away. -#default: USER_CLASSES ?= "buildstats image-prelink" -USER_CLASSES = "buildstats" - # AGL uses 4 optimization levels # 2 for ARM 32bit # - a high and a medium setting for the CCARGS @@ -136,8 +132,8 @@ AGL_EXTRA_INITRAMFS_FSTYPES ??= "" # # Default IMAGE FSTYPES wic.xz AGL_DEFAULT_IMAGE_FSTYPES ?= "wic.xz wic.bmap wic.xz.sha256sum" -AGL_DEFAULT_IMAGE_FSTYPES:qemuall ?= "${@bb.utils.contains('DISTRO_FEATURES', 'AGLCI', 'ext4.xz', 'ext4', d)}" -AGL_DEFAULT_IMAGE_FSTYPES:append:netboot = " ${@bb.utils.contains('DISTRO_FEATURES', 'AGLCI', 'ext4.xz', 'ext4', d)}" +AGL_DEFAULT_IMAGE_FSTYPES:qemuall ?= "${@bb.utils.contains('AGL_FEATURES', 'AGLCI', 'ext4.xz', 'ext4', d)}" +AGL_DEFAULT_IMAGE_FSTYPES:append:netboot = " ${@bb.utils.contains('AGL_FEATURES', 'AGLCI', 'ext4.xz', 'ext4', d)}" AGL_DEFAULT_INITRAMFS_FSTYPES ?= "ext4.gz" # DEFAULT IMAGE_FSTYPES for AGL (no - BSPs should not set this) @@ -145,13 +141,3 @@ AGL_DEFAULT_INITRAMFS_FSTYPES ?= "ext4.gz" IMAGE_FSTYPES = "${AGL_DEFAULT_IMAGE_FSTYPES} ${AGL_EXTRA_IMAGE_FSTYPES}" INITRAMFS_FSTYPES = "${AGL_DEFAULT_INITRAMFS_FSTYPES} ${AGL_EXTRA_INITRAMFS_FSTYPES}" # - -# Fix for rpm metadata clash between nativesdk-cmake and nativesdk-qtbase-tools -# (revalidate after 2017-10-15, 2018-06-12: still required) -DIRFILES:pn-nativesdk-cmake = "1" - -# For https://jira.automotivelinux.org/browse/SPEC-1629 : -# We exclude the conflicting vars from the sstate task hash. -# This needs to be verified. -do_package_write_rpm[vardepsexclude] += "ARCHIVER_TOPDIR PF" - diff --git a/meta-agl-core/conf/include/agl-create-spdx.inc b/meta-agl-core/conf/include/agl-create-spdx.inc new file mode 100644 index 000000000..8d71013e3 --- /dev/null +++ b/meta-agl-core/conf/include/agl-create-spdx.inc @@ -0,0 +1 @@ +INHERIT += " create-spdx " diff --git a/meta-agl-core/conf/include/agl-devel.inc b/meta-agl-core/conf/include/agl-devel.inc index afc284480..055fa61e3 100644 --- a/meta-agl-core/conf/include/agl-devel.inc +++ b/meta-agl-core/conf/include/agl-devel.inc @@ -12,5 +12,5 @@ IMAGE_INSTALL:append = "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', ' lib SDKIMAGE_FEATURES="dev-pkgs" # allows insertion of code or items specific to developement -OVERRIDES .= ":agl-devel" +OVERRIDES:append = ":agl-devel" DISTRO_FEATURES:append = " agl-devel" diff --git a/meta-agl-core/conf/include/agl-gplv2.inc b/meta-agl-core/conf/include/agl-gplv2.inc deleted file mode 100644 index fc9a4072b..000000000 --- a/meta-agl-core/conf/include/agl-gplv2.inc +++ /dev/null @@ -1,8 +0,0 @@ -# GPLv3 Compliance -PREFERRED_VERSION_bash = "3.2.%" -PREFERRED_VERSION_gawk = "3.1.%" -PREFERRED_VERSION_gdbm = "1.8.%" -PREFERRED_VERSION_gnupg = "1.4.7" -PREFERRED_VERSION_gnutls = "3.3.%" -PREFERRED_VERSION_mc = "4.7.5.%" -PREFERRED_VERSION_readline = "5.2" diff --git a/meta-agl-core/conf/include/agl-selinux.inc b/meta-agl-core/conf/include/agl-selinux.inc new file mode 100644 index 000000000..aeb26e33d --- /dev/null +++ b/meta-agl-core/conf/include/agl-selinux.inc @@ -0,0 +1,20 @@ +DISTRO_FEATURES:append = " acl xattr selinux" + +# Reiterate the upstream default of targeted policy since that +# is the mostly widely used model, and it will likely be easier +# to pull policy from other distributions for it. +# Having an explicit setting here seems useful for documentation +# purposes, and it is still possible that using one of the other +# refpolicy package options as the AGL default desirable, and it +# would be set here. +PREFERRED_PROVIDER_virtual/refpolicy ?= "refpolicy-targeted" + +# Default to permissive mode +DEFAULT_ENFORCING ?= "permissive" + +# Override the base image class to get the SELinux labeling hook +AGL_BASE_IMAGE ?= "selinux-image" + +# Mask out meta-selinux's linux-yocto kernel config bbappend to +# avoid collision with AGL's own more universal scheme. +BBMASK += "meta-selinux/recipes-kernel/linux/"
\ No newline at end of file diff --git a/meta-agl-core/conf/layer.conf b/meta-agl-core/conf/layer.conf index d2e973d98..8047df519 100644 --- a/meta-agl-core/conf/layer.conf +++ b/meta-agl-core/conf/layer.conf @@ -10,11 +10,17 @@ BBFILE_PATTERN_aglcore = "^${LAYERDIR}/" BBFILE_PRIORITY_aglcore = "60" BBFILES_DYNAMIC += " \ + openembedded-layer:${LAYERDIR}/dynamic-layers/meta-oe/*/*/*.bb \ + openembedded-layer:${LAYERDIR}/dynamic-layers/meta-oe/*/*/*.bbappend \ + \ + selinux:${LAYERDIR}/dynamic-layers/meta-selinux/*/*/*.bb \ + selinux:${LAYERDIR}/dynamic-layers/meta-selinux/*/*/*.bbappend \ + \ qt5-layer:${LAYERDIR}/dynamic-layers/meta-qt5/*/*/*.bb \ qt5-layer:${LAYERDIR}/dynamic-layers/meta-qt5/*/*/*.bbappend \ " -LAYERSERIES_COMPAT_aglcore = "kirkstone" +LAYERSERIES_COMPAT_aglcore = "scarthgap" LAYERDEPENDS_aglcore = "core" # Sanity check for meta-virtualization layer. diff --git a/meta-agl-core/conf/local.conf.sample b/meta-agl-core/conf/local.conf.sample index ecc9b141a..4cfae4ceb 100644 --- a/meta-agl-core/conf/local.conf.sample +++ b/meta-agl-core/conf/local.conf.sample @@ -148,11 +148,7 @@ EXTRA_IMAGE_FEATURES ?= "debug-tweaks" # enable extra features. Some available options which can be included in this variable # are: # - 'buildstats' collect build statistics -# - 'image-mklibs' to reduce shared library files size for an image -# - 'image-prelink' in order to prelink the filesystem image -# NOTE: if listing mklibs & prelink both, then make sure mklibs is before prelink -# NOTE: mklibs also needs to be explicitly enabled for a given image, see local.conf.extended -USER_CLASSES ?= "buildstats image-prelink" +USER_CLASSES ?= "buildstats" # # Runtime testing of images diff --git a/meta-agl-core/conf/templates/base/bblayers.conf.sample b/meta-agl-core/conf/templates/base/bblayers.conf.sample new file mode 100644 index 000000000..c6a37a0b0 --- /dev/null +++ b/meta-agl-core/conf/templates/base/bblayers.conf.sample @@ -0,0 +1,73 @@ +# LAYER_CONF_VERSION is increased each time build/conf/bblayers.conf +# changes incompatibly +LCONF_VERSION = "6" + +BBPATH = "${TOPDIR}" +BBFILES ?= "" + +# Convenience variables usable in various configuration fragments +#---------------------------------- +BCONFDIR := "${@os.path.abspath(os.path.dirname(d.getVar('FILE', True)))}" +METADIR := "${@os.path.abspath('##OEROOT##/../..')}" + +# These are the core OE + YP Layers +#---------------------------------- +YOCTO_LAYERS = " \ + ${METADIR}/external/poky/meta \ + ${METADIR}/external/poky/meta-poky \ + " +# this is added for the boards where necessary, not globally +# ${METADIR}/external/poky/meta-yocto-bsp \ +# +# These are the AGL CORE Layers that make up the basis +# - they create a minimal bootable filesystem +# with some automotive tools/libraries +#----------------------------------------------------- +AGL_CORE_LAYERS = " \ + ${METADIR}/meta-agl/meta-agl-core \ + ${METADIR}/meta-agl/meta-agl-bsp \ + " + +# These are the direct dependencies of the AGL CORE Layers +#--------------------------------------------------------- +AGL_CORE_DEPENDENCY_LAYERS = " \ + ${METADIR}/external/meta-openembedded/meta-oe \ + " + +# Indirection to avoid duplicate inclusions of the same folder into BBLAYERS +# the evaluation is in the bblayers.conf.sample in meta-agl/meta-agl-core/conf/templates/base +AGL_META_NETWORKING ?= "" +AGL_META_PYTHON ?= "" +AGL_META_FILESYSTEMS ?= "" +AGL_META_MULTIMEDIA ?= "" +AGL_META_VIRTUALIZATION ?= "" +AGL_META_CLANG ?= "" +AGL_META_QT5 ?= "" + +AGL_OTHER_DEPENDENCY_LAYERS = " \ + ${AGL_META_NETWORKING} \ + ${AGL_META_PYTHON} \ + ${AGL_META_FILESYSTEMS} \ + ${AGL_META_MULTIMEDIA} \ + ${AGL_META_VIRTUALIZATION} \ + ${AGL_META_CLANG} \ + ${AGL_META_QT5} \ + " + +#################### +# Combine the layers +BBLAYERS ?= " \ + ${AGL_OTHER_DEPENDENCY_LAYERS} \ + ${AGL_CORE_DEPENDENCY_LAYERS} \ + ${AGL_CORE_LAYERS} \ + ${YOCTO_LAYERS} \ + " + +BBLAYERS_NON_REMOVABLE ?= " \ + ${METADIR}/external/poky/meta \ + ${METADIR}/external/poky/meta-poky \ + ${METADIR}/meta-agl/meta-agl-core \ + " + + + diff --git a/meta-agl-core/conf/templates/base/conf-notes.txt b/meta-agl-core/conf/templates/base/conf-notes.txt new file mode 100644 index 000000000..09ae72647 --- /dev/null +++ b/meta-agl-core/conf/templates/base/conf-notes.txt @@ -0,0 +1,35 @@ +Common targets are: +- meta-agl layer: + - included by default + * agl-image-boot (just enough to boot) + * agl-image-minimal (minimal filesystem with APIs) + * agl-image-minimal-crosssdk (crosssdk for ^^) + + * agl-image-weston (minimal filesystem with weston) + +- meta-agl-demo: (IVI demo with UI) + - with 'agl-demo' + * agl-image-ivi (base for IVI targets) + * agl-image-ivi-crosssdk (sdk for ^^) + + * agl-image-graphical-qt5 (weston plus qt5 framework libs) + * agl-image-graphical-qt5-crosssdk (sdk for ^^) + + * agl-image-graphical-html5 (weston plus chromium for html5) + + * agl-image-cluster (minimal image with APIs for cluster) + * agl-image-cluster-qt5 (image with QT5 and APIs for cluster) + + * agl-image-telematics (image with APIs for telematics) + + * agl-demo-platform (* default IVI demo target *) + * agl-demo-platform-crosssdk (sdk for ^^) + + * agl-cluster-demo-platform (cluster demo image) + * agl-cluster-demo-platform-crosssdk (sdk for ^^) + * agl-cluster-demo-qtcompositor (cluster demo using own compositor) + + * agl-telematics-demo-platform (telematics demo image) + * agl-telematics-demo-platform-crosssdk (sdk for ^^) + + diff --git a/meta-agl-core/conf/templates/base/local.conf.sample b/meta-agl-core/conf/templates/base/local.conf.sample new file mode 100644 index 000000000..be49ed00d --- /dev/null +++ b/meta-agl-core/conf/templates/base/local.conf.sample @@ -0,0 +1,339 @@ +# +# This file is your local configuration file and is where all local user settings +# are placed. The comments in this file give some guide to the options a new user +# to the system might want to change but pretty much any configuration option can +# be set in this file. More adventurous users can look at local.conf.extended +# which contains other examples of configuration which can be placed in this file +# but new users likely won't need any of them initially. +# +# Lines starting with the '#' character are commented out and in some cases the +# default values are provided as comments to show people example syntax. Enabling +# the option is a question of removing the # character and making any change to the +# variable as required. + +# +# Machine Selection +# +# You need to select a specific machine to target the build with. There are a selection +# of emulated machines available which can boot and run in the QEMU emulator: +# +#MACHINE ?= "qemuarm" +#MACHINE ?= "qemuarm64" +#MACHINE ?= "qemumips" +#MACHINE ?= "qemumips64" +#MACHINE ?= "qemuppc" +#MACHINE ?= "qemux86" +#MACHINE ?= "qemux86-64" +# +# There are also the following hardware board target machines included for +# demonstration purposes: +# +#MACHINE ?= "beaglebone-yocto" +#MACHINE ?= "genericx86" +#MACHINE ?= "genericx86-64" +#MACHINE ?= "mpc8315e-rdb" +#MACHINE ?= "edgerouter" +# +# This sets the default machine to be qemux86-64 if no other machine is selected: +MACHINE ??= "qemux86-64" + +# +# Where to place downloads +# +# During a first build the system will download many different source code tarballs +# from various upstream projects. This can take a while, particularly if your network +# connection is slow. These are all stored in DL_DIR. When wiping and rebuilding you +# can preserve this directory to speed up this part of subsequent builds. This directory +# is safe to share between multiple builds on the same machine too. +# +# The default is a downloads directory under TOPDIR which is the build directory. +# +#DL_DIR ?= "${TOPDIR}/downloads" + +# +# Where to place shared-state files +# +# BitBake has the capability to accelerate builds based on previously built output. +# This is done using "shared state" files which can be thought of as cache objects +# and this option determines where those files are placed. +# +# You can wipe out TMPDIR leaving this directory intact and the build would regenerate +# from these files if no changes were made to the configuration. If changes were made +# to the configuration, only shared state files where the state was still valid would +# be used (done using checksums). +# +# The default is a sstate-cache directory under TOPDIR. +# +#SSTATE_DIR ?= "${TOPDIR}/sstate-cache" + +# +# Where to place the build output +# +# This option specifies where the bulk of the building work should be done and +# where BitBake should place its temporary files and output. Keep in mind that +# this includes the extraction and compilation of many applications and the toolchain +# which can use Gigabytes of hard disk space. +# +# The default is a tmp directory under TOPDIR. +# +#TMPDIR = "${TOPDIR}/tmp" + +# +# Default policy config +# +# The distribution setting controls which policy settings are used as defaults. +# The default value is fine for general Yocto project use, at least initially. +# Ultimately when creating custom policy, people will likely end up subclassing +# these defaults. +# +DISTRO ?= "poky" +# As an example of a subclass there is a "bleeding" edge policy configuration +# where many versions are set to the absolute latest code from the upstream +# source control systems. This is just mentioned here as an example, its not +# useful to most new users. +# DISTRO ?= "poky-bleeding" + +# +# Package Management configuration +# +# This variable lists which packaging formats to enable. Multiple package backends +# can be enabled at once and the first item listed in the variable will be used +# to generate the root filesystems. +# Options are: +# - 'package_deb' for debian style deb files +# - 'package_ipk' for ipk files are used by opkg (a debian style embedded package manager) +# - 'package_rpm' for rpm style packages +# E.g.: PACKAGE_CLASSES ?= "package_rpm package_deb package_ipk" +# We default to rpm: +PACKAGE_CLASSES ?= "package_rpm" + +# +# SDK target architecture +# +# This variable specifies the architecture to build SDK items for and means +# you can build the SDK packages for architectures other than the machine you are +# running the build on (i.e. building i686 packages on an x86_64 host). +# Supported values are i686 and x86_64 +#SDKMACHINE ?= "i686" + +# +# Extra image configuration defaults +# +# The EXTRA_IMAGE_FEATURES variable allows extra packages to be added to the generated +# images. Some of these options are added to certain image types automatically. The +# variable can contain the following options: +# "dbg-pkgs" - add -dbg packages for all installed packages +# (adds symbol information for debugging/profiling) +# "src-pkgs" - add -src packages for all installed packages +# (adds source code for debugging) +# "dev-pkgs" - add -dev packages for all installed packages +# (useful if you want to develop against libs in the image) +# "ptest-pkgs" - add -ptest packages for all ptest-enabled packages +# (useful if you want to run the package test suites) +# "tools-sdk" - add development tools (gcc, make, pkgconfig etc.) +# "tools-debug" - add debugging tools (gdb, strace) +# "eclipse-debug" - add Eclipse remote debugging support +# "tools-profile" - add profiling tools (oprofile, lttng, valgrind) +# "tools-testapps" - add useful testing tools (ts_print, aplay, arecord etc.) +# "debug-tweaks" - make an image suitable for development +# e.g. ssh root access has a blank password +# There are other application targets that can be used here too, see +# meta/classes/image.bbclass and meta/classes/core-image.bbclass for more details. +# We default to enabling the debugging tweaks. +EXTRA_IMAGE_FEATURES ?= "debug-tweaks" + +# +# Additional image features +# +# The following is a list of additional classes to use when building images which +# enable extra features. Some available options which can be included in this variable +# are: +# - 'buildstats' collect build statistics +USER_CLASSES ?= "buildstats" + +# +# Runtime testing of images +# +# The build system can test booting virtual machine images under qemu (an emulator) +# after any root filesystems are created and run tests against those images. It can also +# run tests against any SDK that are built. To enable this uncomment these lines. +# See classes/test{image,sdk}.bbclass for further details. +#IMAGE_CLASSES += "testimage testsdk" +#TESTIMAGE_AUTO:qemuall = "1" + +# +# Interactive shell configuration +# +# Under certain circumstances the system may need input from you and to do this it +# can launch an interactive shell. It needs to do this since the build is +# multithreaded and needs to be able to handle the case where more than one parallel +# process may require the user's attention. The default is iterate over the available +# terminal types to find one that works. +# +# Examples of the occasions this may happen are when resolving patches which cannot +# be applied, to use the devshell or the kernel menuconfig +# +# Supported values are auto, gnome, xfce, rxvt, screen, konsole (KDE 3.x only), none +# Note: currently, Konsole support only works for KDE 3.x due to the way +# newer Konsole versions behave +#OE_TERMINAL = "auto" +# By default disable interactive patch resolution (tasks will just fail instead): +PATCHRESOLVE = "noop" + +# +# Disk Space Monitoring during the build +# +# Monitor the disk space during the build. If there is less that 1GB of space or less +# than 100K inodes in any key build location (TMPDIR, DL_DIR, SSTATE_DIR), gracefully +# shutdown the build. If there is less that 100MB or 1K inodes, perform a hard halt +# of the build. The reason for this is that running completely out of space can corrupt +# files and damages the build in ways which may not be easily recoverable. +# It's necesary to monitor /tmp, if there is no space left the build will fail +# with very exotic errors. +BB_DISKMON_DIRS ??= "\ + STOPTASKS,${TMPDIR},1G,100K \ + STOPTASKS,${DL_DIR},1G,100K \ + STOPTASKS,${SSTATE_DIR},1G,100K \ + STOPTASKS,/tmp,100M,100K \ + HALT,${TMPDIR},100M,1K \ + HALT,${DL_DIR},100M,1K \ + HALT,${SSTATE_DIR},100M,1K \ + HALT,/tmp,10M,1K" + +# +# Shared-state files from other locations +# +# As mentioned above, shared state files are prebuilt cache data objects which can +# used to accelerate build time. This variable can be used to configure the system +# to search other mirror locations for these objects before it builds the data itself. +# +# This can be a filesystem directory, or a remote url such as http or ftp. These +# would contain the sstate-cache results from previous builds (possibly from other +# machines). This variable works like fetcher MIRRORS/PREMIRRORS and points to the +# cache locations to check for the shared objects. +# NOTE: if the mirror uses the same structure as SSTATE_DIR, you need to add PATH +# at the end as shown in the examples below. This will be substituted with the +# correct path within the directory structure. +#SSTATE_MIRRORS ?= "\ +#file://.* http://someserver.tld/share/sstate/PATH;downloadfilename=PATH \n \ +#file://.* file:///some/local/dir/sstate/PATH" + +# +# AGL Project SState Mirror +# +# The AGL Project has prebuilt artefacts available for its releases, you can enable +# use of these by uncommenting the following line. This will mean the build uses +# the network to check for artefacts at the start of builds, which does slow it down +# equally, it will also speed up the builds by not having to build things if they are +# present in the cache. It assumes you can download something faster than you can build it +# which will depend on your network. +# +#SSTATE_MIRRORS ?= "file://.* http://sstate.yoctoproject.org/2.5/PATH;downloadfilename=PATH" +# For AGL: +#SSTATE_MIRRORS += "file://.* http://download.automotivelinux.org/sstate-mirror/${AGL_BRANCH}/${DEFAULTTUNE}/PATH;downloadfilename=PATH" + +# +# Qemu configuration +# +# By default native qemu will build with a builtin VNC server where graphical output can be +# seen. The line below enables the SDL UI frontend too. +PACKAGECONFIG:append:pn-qemu-system-native = " sdl" +# By default libsdl2-native will be built, if you want to use your host's libSDL instead of +# the minimal libsdl built by libsdl2-native then uncomment the ASSUME_PROVIDED line below. +#ASSUME_PROVIDED += "libsdl2-native" + +# You can also enable the Gtk UI frontend, which takes somewhat longer to build, but adds +# a handy set of menus for controlling the emulator. +#PACKAGECONFIG:append:pn-qemu-system-native = " gtk+" + +# +# Parallelism Options +# +# These two options control how much parallelism BitBake should use. The first +# option determines how many tasks bitbake should run in parallel: +# +#BB_NUMBER_THREADS ?= "4" +# +# Default to setting automatically based on cpu count +#BB_NUMBER_THREADS ?= "${@oe.utils.cpu_count()}" +# +# The second option controls how many processes make should run in parallel when +# running compile tasks: +# +#PARALLEL_MAKE ?= "-j 4" +# +# Default to setting automatically based on cpu count +#PARALLEL_MAKE ?= "-j ${@oe.utils.cpu_count()}" +# +# For a quad-core machine, BB_NUMBER_THREADS = "4", PARALLEL_MAKE = "-j 4" would +# be appropriate for example. + +# +# Hash Equivalence +# +# Enable support for automatically running a local hash equivalence server and +# instruct bitbake to use a hash equivalence aware signature generator. Hash +# equivalence improves reuse of sstate by detecting when a given sstate +# artifact can be reused as equivalent, even if the current task hash doesn't +# match the one that generated the artifact. +# +# A shared hash equivalent server can be set with "<HOSTNAME>:<PORT>" format +# +#BB_HASHSERVE = "auto" +#BB_SIGNATURE_HANDLER = "OEEquivHash" + + +# The network based PR service host and port +# Uncomment the following lines to enable PRservice. +# Set PRSERV_HOST to 'localhost:0' to automatically +# start local PRService. +# Set to other values to use remote PRService. +#PRSERV_HOST = "localhost:0" + + +# Archive the source and put them to ${DEPLOY_DIR}/sources/. +# +#INHERIT += "archiver" +# +# The tarball for the patched source will be created by default, and you +# can configure the archiver as follow: +# +# Create archive for: +# 1) original (or unpacked) source: +#ARCHIVER_MODE[src] = "original" +# 2) patched source: (default) +#ARCHIVER_MODE[src] = "patched" +# 3) configured source: +#ARCHIVER_MODE[src] = "configured" +# +# 4) the patches between do_unpack and do_patch: +#ARCHIVER_MODE[diff] = "1" +# set the files that you'd like to exclude from the diff: +#ARCHIVER_MODE[diff-exclude] ?= ".pc autom4te.cache patches" +# +# 5) the environment data, similar to 'bitbake -e recipe': +#ARCHIVER_MODE[dumpdata] = "1" +# +# 6) the recipe (.bb and .inc): +#ARCHIVER_MODE[recipe] = "1" +# +# 7) Whether output the .src.rpm package: +#ARCHIVER_MODE[srpm] = "1" +# +# 8) Filter the license, the recipe whose license in +# COPYLEFT_LICENSE_INCLUDE will be included, and in +# COPYLEFT_LICENSE_EXCLUDE will be excluded. +#COPYLEFT_LICENSE_INCLUDE = 'GPL* LGPL*' +#COPYLEFT_LICENSE_EXCLUDE = 'CLOSED Proprietary' +# +# 9) Config the recipe type that will be archived, the type can be +# target, native, nativesdk, cross, crosssdk and cross-canadian, +# you can set one or more types. Archive all types by default. +#COPYLEFT_RECIPE_TYPES = 'target' +# + + +# CONF_VERSION is increased each time build/conf/ changes incompatibly and is used to +# track the version of this file when it was generated. This can safely be ignored if +# this doesn't mean anything to you. +CONF_VERSION = "2" diff --git a/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-compositor-init.bbappend b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-compositor-init.bbappend new file mode 100644 index 000000000..4b6deffdf --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-compositor-init.bbappend @@ -0,0 +1 @@ +require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'agl-compositor-init_aglcore.inc', '', d)} diff --git a/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-compositor-init_aglcore.inc b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-compositor-init_aglcore.inc new file mode 100644 index 000000000..b7d346d39 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-compositor-init_aglcore.inc @@ -0,0 +1 @@ +require common-init.inc diff --git a/meta-agl-core/recipes-graphics/wayland/agl-shell-activator_git.bb b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-shell-activator_git.bb index c55683e99..38725c1bd 100644 --- a/meta-agl-core/recipes-graphics/wayland/agl-shell-activator_git.bb +++ b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/agl-shell-activator_git.bb @@ -8,10 +8,10 @@ SECTION = "x11" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://COPYING;md5=e978448a0d41d826d73890d9c22caf75" -DEPENDS = "wayland wayland-protocols wayland-native agl-compositor" +DEPENDS = "wayland wayland-protocols wayland-native agl-compositor grpc grpc-native" SRC_URI = "git://gerrit.automotivelinux.org/gerrit/src/agl-shell-activator.git;protocol=https;branch=${AGL_BRANCH}" -SRCREV = "b1006c97511b6e6ed3b92bacab61c42be13f458b" +SRCREV = "027d6f814f3d1f2e6b4b4071365b28dadec34109" PV = "0.0.10+git${SRCPV}" S = "${WORKDIR}/git" diff --git a/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/common-init.inc b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/common-init.inc new file mode 100644 index 000000000..47f7d8b1d --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/common-init.inc @@ -0,0 +1,6 @@ +# If weston's PACKAGECONFIG contains systemd + pam + polkit, polkit +# ends up a hard requirement for start up due to the pam + systemd +# configuration that is being installed. For now, keep things simple +# and assume that polkit should be a dependency if it is in +# DISTRO_FEATURES. +RDEPENDS:${PN} += "${@bb.utils.filter('DISTRO_FEATURES', 'polkit', d)}" diff --git a/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/weston-init.bbappend b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/weston-init.bbappend new file mode 100644 index 000000000..c09d7ccd3 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/weston-init.bbappend @@ -0,0 +1 @@ +require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'weston-init_aglcore.inc', '', d)} diff --git a/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/weston-init_aglcore.inc b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/weston-init_aglcore.inc new file mode 100644 index 000000000..b7d346d39 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-oe/recipes-graphics/wayland/weston-init_aglcore.inc @@ -0,0 +1 @@ +require common-init.inc diff --git a/meta-agl-core/dynamic-layers/meta-oe/recipes-platform/images/agl-image-compositor.bbappend b/meta-agl-core/dynamic-layers/meta-oe/recipes-platform/images/agl-image-compositor.bbappend new file mode 100644 index 000000000..1e0e66f01 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-oe/recipes-platform/images/agl-image-compositor.bbappend @@ -0,0 +1,3 @@ +IMAGE_INSTALL += " \ + ${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'agl-shell-activator', '', d)} \ +" diff --git a/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtbase_aglcore.inc b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtbase_aglcore.inc index 54a6311fb..581f5de99 100644 --- a/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtbase_aglcore.inc +++ b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtbase_aglcore.inc @@ -1,3 +1,5 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/qtbase:" + PACKAGECONFIG_WAYLAND = "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland', '', d)}" PACKAGECONFIG_GL = "${@bb.utils.contains('DISTRO_FEATURES', 'opengl', 'gles2', '', d)}" diff --git a/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation/0001-mapbox-update-API-url-to-match-new-schema.patch b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation/0001-mapbox-update-API-url-to-match-new-schema.patch new file mode 100644 index 000000000..ba8a991ed --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation/0001-mapbox-update-API-url-to-match-new-schema.patch @@ -0,0 +1,47 @@ +From 58197439eade86e7efc6fe98116c0092ea429d29 Mon Sep 17 00:00:00 2001 +From: Matt Ranostay <matt.ranostay@konsulko.com> +Date: Tue, 10 Mar 2020 13:59:58 -0700 +Subject: [PATCH] mapbox: update API url to match new schema + +--- + src/plugins/geoservices/mapbox/qgeotilefetchermapbox.cpp | 7 ++++--- + src/plugins/geoservices/mapbox/qmapboxcommon.h | 2 +- + 2 files changed, 5 insertions(+), 4 deletions(-) + +diff --git a/src/plugins/geoservices/mapbox/qgeotilefetchermapbox.cpp b/src/plugins/geoservices/mapbox/qgeotilefetchermapbox.cpp +index 0b128556..bd2be6b6 100644 +--- a/src/plugins/geoservices/mapbox/qgeotilefetchermapbox.cpp ++++ b/src/plugins/geoservices/mapbox/qgeotilefetchermapbox.cpp +@@ -88,12 +88,13 @@ QGeoTiledMapReply *QGeoTileFetcherMapbox::getTileImage(const QGeoTileSpec &spec) + request.setRawHeader("User-Agent", m_userAgent); + + request.setUrl(QUrl(mapboxTilesApiPath + +- ((spec.mapId() >= m_mapIds.size()) ? QStringLiteral("mapbox.streets") : m_mapIds[spec.mapId() - 1]) + QLatin1Char('/') + ++ m_mapIds[m_mapIds.size() - 1] + ++ QStringLiteral("/tiles/256/") + + QString::number(spec.zoom()) + QLatin1Char('/') + + QString::number(spec.x()) + QLatin1Char('/') + + QString::number(spec.y()) + +- ((m_scaleFactor > 1) ? (QLatin1Char('@') + QString::number(m_scaleFactor) + QLatin1String("x.")) : QLatin1String(".")) + +- m_format + QLatin1Char('?') + ++ ((m_scaleFactor > 1) ? (QLatin1Char('@') + QString::number(m_scaleFactor) + QLatin1String("x")) : QLatin1String("")) + ++ QLatin1Char('?') + + QStringLiteral("access_token=") + m_accessToken)); + + QNetworkReply *reply = m_networkManager->get(request); +diff --git a/src/plugins/geoservices/mapbox/qmapboxcommon.h b/src/plugins/geoservices/mapbox/qmapboxcommon.h +index e60c4e83..4b2ea98d 100644 +--- a/src/plugins/geoservices/mapbox/qmapboxcommon.h ++++ b/src/plugins/geoservices/mapbox/qmapboxcommon.h +@@ -46,7 +46,7 @@ + + QT_BEGIN_NAMESPACE + +-static const QString mapboxTilesApiPath = QStringLiteral("http://api.tiles.mapbox.com/v4/"); ++static const QString mapboxTilesApiPath = QStringLiteral("https://api.mapbox.com/"); + + // https://www.mapbox.com/api-documentation/#geocoding + static const QString mapboxGeocodingApiPath = QStringLiteral("https://api.mapbox.com/geocoding/v5/mapbox.places/"); +-- +2.25.0 + diff --git a/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation_%.bbappend b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation_%.bbappend new file mode 100644 index 000000000..a0d80075a --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation_%.bbappend @@ -0,0 +1 @@ +require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'qtlocation_aglcore.inc', '', d)} diff --git a/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation_aglcore.inc b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation_aglcore.inc new file mode 100644 index 000000000..60867aef0 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-qt5/recipes-qt/qt5/qtlocation_aglcore.inc @@ -0,0 +1,14 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/qtlocation:" + +SRC_URI += "\ + file://0001-mapbox-update-API-url-to-match-new-schema.patch \ + " + +# Need to explicitly enable the various plugins +PACKAGECONFIG += " \ + geoservices_osm \ + geoservices_here \ + geoservices_itemsoverlay \ + geoservices_mapbox \ + geoservices_mapboxgl \ +" diff --git a/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/files/systemd-selinux-relabel.service b/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/files/systemd-selinux-relabel.service new file mode 100644 index 000000000..b8d394068 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/files/systemd-selinux-relabel.service @@ -0,0 +1,12 @@ +[Unit] +Description=Generated file SELinux relabeling +DefaultDependencies=no +After=local-fs.target systemd-machine-id-commit.service +Before=sysinit.target + +[Service] +Type=oneshot +ExecStart=/usr/sbin/systemd-selinux-relabel.sh + +[Install] +WantedBy=sysinit.target diff --git a/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/files/systemd-selinux-relabel.sh b/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/files/systemd-selinux-relabel.sh new file mode 100644 index 000000000..b2557a8d6 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/files/systemd-selinux-relabel.sh @@ -0,0 +1,12 @@ +#!/bin/sh + +# Update labels on files generated on first boot. +/usr/sbin/restorecon -FRi /etc/systemd /etc/machine-id +if [ $? -eq 0 ]; then + # Disable parent service + # NOTE: The service does not use the first boot functionality + # in systemd as /etc/machine-id is not writeable until + # after it is complete. + systemctl disable systemd-selinux-relabel.service +fi +exit 0 diff --git a/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/systemd-selinux-relabel_1.0.bb b/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/systemd-selinux-relabel_1.0.bb new file mode 100644 index 000000000..7e4f9783c --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-selinux/recipes-core/systemd/systemd-selinux-relabel_1.0.bb @@ -0,0 +1,25 @@ +SUMMARY = "System unit to relabel systemd generated files" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302" + +SRC_URI = "file://systemd-selinux-relabel.service \ + file://systemd-selinux-relabel.sh \ +" + +inherit systemd allarch features_check + +SYSTEMD_SERVICE:${PN} = "${BPN}.service" + +REQUIRED_DISTRO_FEATURES = "systemd" + +do_configure[noexec] = "1" +do_compile[noexec] = "1" + +do_install() { + install -d ${D}${systemd_system_unitdir} + install -m 0644 ${WORKDIR}/systemd-selinux-relabel.service ${D}${systemd_system_unitdir}/ + install -d ${D}${sbindir} + install -m 0755 ${WORKDIR}/systemd-selinux-relabel.sh ${D}${sbindir}/ +} + +FILES:${PN} += "${systemd_system_unitdir}" diff --git a/meta-agl-core/dynamic-layers/meta-selinux/recipes-platform/packagegroups/packagegroup-agl-core-selinux.bb b/meta-agl-core/dynamic-layers/meta-selinux/recipes-platform/packagegroups/packagegroup-agl-core-selinux.bb new file mode 100644 index 000000000..493a46f25 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-selinux/recipes-platform/packagegroups/packagegroup-agl-core-selinux.bb @@ -0,0 +1,57 @@ +SUMMARY = "SELinux packages" +DESCRIPTION = "SELinux packages required for AGL" +LICENSE = "MIT" + +inherit packagegroup features_check + +REQUIRED_DISTRO_FEATURES = "selinux" + +PACKAGES = " \ + packagegroup-agl-core-selinux \ + packagegroup-agl-core-selinux-devel \ +" + +# +# meta-selinux's packagegroup-core-selinux includes a lot of +# policy development tools with its inclusion of the layer's +# packagegroup-selinux-policycoreutils, which is not really +# desirable for a production image. Create our own base +# packagegroup and an accompanying devel packagegroup that +# agl-devel can trigger pulling in. +# +# NOTES: +# - It seems likely we will always want auditd, so include +# it in the base packagegroup. +# - selinux-autorelabel seems required to handle both the +# edge case of builds done on non-xattr capable filesystems, +# and to allow driving relabeling after potential package +# installation during runtime. +# - packagegroup-selinux-policycoreutils includes a lot of +# things that seem not useful in a lot of systems (e.g. +# the gtk dependent selinux-gui), so for now the devel +# packagegroup aims to include a more minimal set of tools +# aimed at enabling checkpolicy and audit2allow use. +# - Some thought needs to go into whether the relabeling +# fixup packages should be handled separately, as they +# ideally should not go into images using read-only or +# stateless rootfs, but those are image features so we +# cannot check for them here. +# + +RDEPENDS:${PN} = " \ + packagegroup-selinux-minimal \ + auditd \ + selinux-autorelabel \ + systemd-selinux-relabel \ +" + +RDEPENDS:${PN}-devel = " \ + ${BPN} \ + libsepol-bin \ + checkpolicy \ + policycoreutils-loadpolicy \ + policycoreutils-setsebool \ + policycoreutils-hll \ + semodule-utils-semodule-package \ + selinux-python-audit2allow \ +" diff --git a/meta-agl-core/dynamic-layers/meta-selinux/recipes-security/selinux-scripts/selinux-autorelabel_0.1.bbappend b/meta-agl-core/dynamic-layers/meta-selinux/recipes-security/selinux-scripts/selinux-autorelabel_0.1.bbappend new file mode 100644 index 000000000..793b049e5 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-selinux/recipes-security/selinux-scripts/selinux-autorelabel_0.1.bbappend @@ -0,0 +1 @@ +require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'selinux-autorelabel_aglcore.inc', '', d)} diff --git a/meta-agl-core/dynamic-layers/meta-selinux/recipes-security/selinux-scripts/selinux-autorelabel_aglcore.inc b/meta-agl-core/dynamic-layers/meta-selinux/recipes-security/selinux-scripts/selinux-autorelabel_aglcore.inc new file mode 100644 index 000000000..67d3843f4 --- /dev/null +++ b/meta-agl-core/dynamic-layers/meta-selinux/recipes-security/selinux-scripts/selinux-autorelabel_aglcore.inc @@ -0,0 +1,4 @@ +do_install:append() { + # Do not force auto relabeling just from the package getting installed + rm -f ${D}/.autorelabel +} diff --git a/meta-agl-core/files/group b/meta-agl-core/files/group index b04ff377b..a7e0cd17f 100644 --- a/meta-agl-core/files/group +++ b/meta-agl-core/files/group @@ -89,7 +89,14 @@ wayland::201: display::202: agl-driver::1001: agl-passenger::1002: +applaunchd::1003: systemd-network::1005: systemd-resolve::1006: mosquitto::1007: pipewire::1008: +render::1009: +sgx::1010: +kuksa::900: +qemu::901: +kvm::902: +ptest::2001: diff --git a/meta-agl-core/files/passwd b/meta-agl-core/files/passwd index 4bbd6f878..ea54d06e4 100644 --- a/meta-agl-core/files/passwd +++ b/meta-agl-core/files/passwd @@ -23,6 +23,7 @@ sshd::996:996::: systemd-bus-proxy::995:995::: agl-driver::1001:1001::: agl-passenger::1002:1002::: +applaunchd::1003:1003::: messagebus::994:994::: afm::992:992::: systemd-timesync::988:988::: @@ -61,3 +62,7 @@ systemd-network::1005:1005::: systemd-resolve::1006:1006::: mosquitto::1007:1007::: pipewire::1008:1008::: +kuksa::900:900::: +qemu::901:901::: +user::1004:100::: +ptest::2001:2001::: diff --git a/meta-agl-core/recipes-config/agl-users/agl-users.inc b/meta-agl-core/recipes-config/agl-users/agl-users.inc new file mode 100644 index 000000000..428af3806 --- /dev/null +++ b/meta-agl-core/recipes-config/agl-users/agl-users.inc @@ -0,0 +1,14 @@ +inherit useradd + +USERADD_PACKAGES = "${PN}" +USERADDEXTENSION = "useradd-staticids" + +GROUPADD_PARAM:${PN} = "\ + --system video ; \ + --system pipewire ; \ + -g 1001 agl-driver ; \ +" + +USERADD_PARAM:${PN} = "\ + -g 1001 -u 1001 -G video,pipewire -o -d /home/agl-driver -m -K PASS_MAX_DAYS=-1 agl-driver ; \ +" diff --git a/meta-agl-core/recipes-config/agl-users/agl-users_1.0.bb b/meta-agl-core/recipes-config/agl-users/agl-users_1.0.bb new file mode 100644 index 000000000..18f25e4be --- /dev/null +++ b/meta-agl-core/recipes-config/agl-users/agl-users_1.0.bb @@ -0,0 +1,9 @@ +SUMMARY = "AGL Users" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" + +inherit allarch + +require agl-users.inc + +ALLOW_EMPTY:${PN} = "1" diff --git a/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses/0001-Do-not-overwrite-CFLAGS.patch b/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses/0001-Do-not-overwrite-CFLAGS.patch new file mode 100644 index 000000000..4a86e6c57 --- /dev/null +++ b/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses/0001-Do-not-overwrite-CFLAGS.patch @@ -0,0 +1,37 @@ +From 50ca6e010c3ca3f7cb06dfdf5dbdfaacd4f4749a Mon Sep 17 00:00:00 2001 +From: Jan-Simon Moeller <jsmoeller@linuxfoundation.org> +Date: Tue, 19 Jul 2022 23:28:21 +0200 +Subject: [PATCH] Do not overwrite CFLAGS + +Signed-off-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org> +--- + configure.ac | 16 ++++++++-------- + 1 file changed, 8 insertions(+), 8 deletions(-) + +diff --git a/configure.ac b/configure.ac +index 7e3307f..c385bc0 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -24,14 +24,14 @@ AC_PROG_CC + AC_PROG_CC_C99 + AM_PROG_CC_C_O + +-CFLAGS="" +- +-AC_ARG_ENABLE(optimization, AC_HELP_STRING([--disable-optimization], +- [disable code optimization through compiler]), [ +- if (test "${enableval}" = "no"); then +- CFLAGS="$CFLAGS -O0 -U_FORTIFY_SOURCE" +- fi +-]) ++#CFLAGS="" ++# ++#AC_ARG_ENABLE(optimization, AC_HELP_STRING([--disable-optimization], ++# [disable code optimization through compiler]), [ ++# if (test "${enableval}" = "no"); then ++# CFLAGS="$CFLAGS -O0 -U_FORTIFY_SOURCE" ++# fi ++#]) + + AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug], + [enable compiling with debugging information]), [ diff --git a/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses/0001-Initialize-variables.patch b/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses/0001-Initialize-variables.patch new file mode 100644 index 000000000..9a1078426 --- /dev/null +++ b/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses/0001-Initialize-variables.patch @@ -0,0 +1,39 @@ +From 0389a80796d3ae31d8f60659f0638660a00157b2 Mon Sep 17 00:00:00 2001 +From: Jan-Simon Moeller <jsmoeller@linuxfoundation.org> +Date: Tue, 19 Jul 2022 23:58:05 +0200 +Subject: [PATCH] Initialize variables + +This fixes compiler warnings. + +Signed-off-by: Jan-Simon Moeller <jsmoeller@linuxfoundation.org> +--- + main.c | 2 +- + renderers.c | 2 +- + 2 files changed, 2 insertions(+), 2 deletions(-) + +diff --git a/main.c b/main.c +index f0354f9..1fa9ab1 100644 +--- a/main.c ++++ b/main.c +@@ -159,7 +159,7 @@ static void report_error() + */ + static void get_help_window() + { +- char *msg; ++ char *msg = ""; + + if (win_help) + return; +diff --git a/renderers.c b/renderers.c +index c531a1e..d9d0414 100644 +--- a/renderers.c ++++ b/renderers.c +@@ -153,7 +153,7 @@ static void renderers_technologies(struct json_object *jobj) + int i; + char *desc_base = "%-20s Powered %-5s Connected %-5s"; + char desc_base_sub[30]; +- const char *k_name, *k_type, *k_powered, *k_connected; ++ const char *k_name = "" , *k_type = "" , *k_powered = "", *k_connected = ""; + char *desc, *tech_short_name; + struct json_object *sub_array, *dbus_tech_name, *tech_dict; + struct userptr_data *data; diff --git a/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses_git.bb b/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses_git.bb index 0d1983db2..7b6d50531 100644 --- a/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses_git.bb +++ b/meta-agl-core/recipes-connectivity/connman-ncurses/connman-ncurses_git.bb @@ -10,13 +10,15 @@ LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://LICENSE;md5=8c16666ae6c159876a0ba63099614381" SRC_URI = "git://gitlab.com/iotbzh/connman-json-client.git;protocol=https;branch=master \ - file://stdbool-fixes.patch" + file://stdbool-fixes.patch \ + file://0001-Do-not-overwrite-CFLAGS.patch \ + file://0001-Initialize-variables.patch \ + " SRCREV = "2b0f93ec9518c978c04807fe52e95315d6d80e6b" inherit autotools pkgconfig -EXTRA_AUTORECONF += " -i" -EXTRA_OECONF += " --disable-optimization --enable-debug" +EXTRA_AUTORECONF += " -vfi" S = "${WORKDIR}/git" diff --git a/meta-agl-core/recipes-connectivity/connman/connman-conf/main.conf b/meta-agl-core/recipes-connectivity/connman/connman-conf/main.conf index 4dba25b70..be9fd0ed2 100644 --- a/meta-agl-core/recipes-connectivity/connman/connman-conf/main.conf +++ b/meta-agl-core/recipes-connectivity/connman/connman-conf/main.conf @@ -1,3 +1,3 @@ [General] FallbackTimeservers=pool.ntp.org -NetworkInterfaceBlacklist=vmnet,vboxnet,virbr,ifb,meth +NetworkInterfaceBlacklist=vmnet,vboxnet,virbr,tap,ifb,meth diff --git a/meta-agl-core/recipes-connectivity/connman/connman-conf_aglcore.inc b/meta-agl-core/recipes-connectivity/connman/connman-conf_aglcore.inc index 4505ab779..30a250e1e 100644 --- a/meta-agl-core/recipes-connectivity/connman/connman-conf_aglcore.inc +++ b/meta-agl-core/recipes-connectivity/connman/connman-conf_aglcore.inc @@ -1,2 +1,9 @@ # Pick up our version of main.conf FILESEXTRAPATHS:prepend := "${THISDIR}/connman-conf:" + +# Upstream connman-conf only installs configuration for qemu targets +# but we need it in all our BSP +do_install:append() { + mkdir -p ${D}${sysconfdir}/connman + cp ${S}/main.conf ${D}${sysconfdir}/connman/main.conf +} diff --git a/meta-agl-core/recipes-connectivity/connman/connman/0001-disable-when-booting-over-nfs.patch b/meta-agl-core/recipes-connectivity/connman/connman/0001-disable-when-booting-over-nfs.patch index f129a6580..7cc92e2c4 100644 --- a/meta-agl-core/recipes-connectivity/connman/connman/0001-disable-when-booting-over-nfs.patch +++ b/meta-agl-core/recipes-connectivity/connman/connman/0001-disable-when-booting-over-nfs.patch @@ -1,3 +1,7 @@ +Exempt when nfs is in use. + +Upstream-Status: Pending + --- connman-1.36.orig/src/connman.service.in 2019-02-18 18:02:07.034947373 -0500 +++ connman-1.36/src/connman.service.in 2019-02-18 18:07:24.689959219 -0500 @@ -7,6 +7,7 @@ diff --git a/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can-fd.network b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can-fd.network new file mode 100644 index 000000000..86042bd90 --- /dev/null +++ b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can-fd.network @@ -0,0 +1,12 @@ +[Match] +Name=can* + +[CAN] +BitRate=500K +SamplePoint=75% +DataBitRate=4M +DataSamplePoint=80% +FDMode=yes + +[Link] +ActivationPolicy=up diff --git a/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can.link b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can.link new file mode 100644 index 000000000..61fb4d575 --- /dev/null +++ b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can.link @@ -0,0 +1,11 @@ +[Match] +Type=can +OriginalName=can* + +[Link] +TransmitQueueLength=1000 +# Need to duplicate default configuration here, since only first +# matching .link is applied +NamePolicy=keep kernel database onboard slot path +AlternativeNamesPolicy=database onboard slot path +MACAddressPolicy=persistent diff --git a/meta-agl-core/recipes-core/systemd/systemd/canbus-can.network b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can.network index ae5514bca..ae5514bca 100644 --- a/meta-agl-core/recipes-core/systemd/systemd/canbus-can.network +++ b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-can.network diff --git a/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-virtio.network b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-virtio.network new file mode 100644 index 000000000..cc33d86d6 --- /dev/null +++ b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus/canbus-virtio.network @@ -0,0 +1,5 @@ +[Match] +Name=can* + +[CAN] +RestartSec=0.1 diff --git a/meta-agl-core/recipes-core/systemd/systemd-conf-canbus_1.0.bb b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus_1.0.bb new file mode 100644 index 000000000..a23cd839a --- /dev/null +++ b/meta-agl-core/recipes-core/systemd/systemd-conf-canbus_1.0.bb @@ -0,0 +1,32 @@ +SUMMARY = "Systemd canbus configuration" +DESCRIPTION = "Systemd may require slightly different configuration for \ +different machines. This injects configuration for the CAN bus." +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" + +PE = "1" + +SRC_URI = "\ + file://canbus-can.network \ + file://canbus-can-fd.network \ + file://canbus-virtio.network \ + file://canbus-can.link \ +" + +CANBUS_NETWORK_CONFIG ??= "canbus-can.network" +CANBUS_NETWORK_CONFIG:virtio-all ?= "canbus-virtio.network" + +do_install() { + # Install CAN bus network configuration + install -d ${D}${nonarch_base_libdir}/systemd/network/ + install -m 0644 ${WORKDIR}/${CANBUS_NETWORK_CONFIG} ${D}${nonarch_base_libdir}/systemd/network/60-canbus-can.network + + # Install link configuration to bump queue size on physical CAN bus devices + install -m 0644 ${WORKDIR}/canbus-can.link ${D}${nonarch_base_libdir}/systemd/network/60-canbus-can.link +} + +PACKAGE_ARCH = "${MACHINE_ARCH}" + +FILES:${PN} = " \ + ${nonarch_base_libdir}/systemd/network/ \ +" diff --git a/meta-agl-core/recipes-core/systemd/systemd/wait-disable.conf b/meta-agl-core/recipes-core/systemd/systemd/wait-disable.conf new file mode 100644 index 000000000..e5d4f4b28 --- /dev/null +++ b/meta-agl-core/recipes-core/systemd/systemd/wait-disable.conf @@ -0,0 +1,3 @@ +[Service] +ExecStart= +ExecStart=/usr/bin/true diff --git a/meta-agl-core/recipes-core/systemd/systemd/wired.network b/meta-agl-core/recipes-core/systemd/systemd/wired.network index 3559b0155..425610a3f 100644 --- a/meta-agl-core/recipes-core/systemd/systemd/wired.network +++ b/meta-agl-core/recipes-core/systemd/systemd/wired.network @@ -1,5 +1,8 @@ [Match] Name=eth* en* +KernelCommandLine=!nbdroot +KernelCommandLine=!nfsroot +KernelCommandLine=!ip [Network] DHCP=yes diff --git a/meta-agl-core/recipes-core/systemd/systemd_aglcore.inc b/meta-agl-core/recipes-core/systemd/systemd_aglcore.inc index 6dd6698fc..9681329be 100644 --- a/meta-agl-core/recipes-core/systemd/systemd_aglcore.inc +++ b/meta-agl-core/recipes-core/systemd/systemd_aglcore.inc @@ -2,32 +2,35 @@ FILESEXTRAPATHS:prepend := "${THISDIR}/systemd:" SRC_URI += "\ file://e2fsck.conf \ - file://canbus-can.network \ - ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','systemd','file://wired.network','',d)} \ + file://wait-disable.conf \ + file://wired.network \ " -# enable networkd/resolved support -PACKAGECONFIG:append:pn-systemd = " \ +# Enable networkd/resolved support if using systemd for network management +PACKAGECONFIG:append = " \ ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','systemd','networkd resolved','',d)} \ + iptc \ " +# SPEC-737: connmand also has a NTP client which races with systemd-timesyncd +PACKAGECONFIG:remove = "timesyncd" + +# Enable systemd-coredump when agl-devel is set on +PACKAGECONFIG:append:agl-devel = " coredump" + do_install:append() { # Install /etc/e2fsck.conf to avoid boot stuck by wrong clock time install -m 644 -p -D ${WORKDIR}/e2fsck.conf ${D}${sysconfdir}/e2fsck.conf - # Install canbus network script - install -m 0644 ${WORKDIR}/canbus-can.network ${D}${nonarch_base_libdir}/systemd/network/60-canbus-can.network - - if ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','systemd','true','false',d)}; then + if [ "${VIRTUAL-RUNTIME_net_manager}" = "systemd" ]; then # Install DHCP configuration for Ethernet adapters install -m 644 ${WORKDIR}/wired.network ${D}${sysconfdir}/systemd/network + elif [ "${VIRTUAL-RUNTIME_net_manager}" = "connman" ]; then + # Disable systemd-networkd-wait-online by default + install -d ${D}${systemd_system_unitdir}/systemd-networkd-wait-online.service.d + install -m 0644 ${WORKDIR}/wait-disable.conf ${D}${systemd_system_unitdir}/systemd-networkd-wait-online.service.d/ fi } FILES:${PN} += "${sysconfdir}/e2fsck.conf " -# SPEC-737: connmand also has a NTP client which races with systemd-timesyncd -PACKAGECONFIG:remove = "timesyncd" - -# Enable systemd-coredump when agl-devel is set on -PACKAGECONFIG:append:agl-devel = " coredump" diff --git a/meta-agl-core/recipes-devtools/cmake/cmake_aglcore.inc b/meta-agl-core/recipes-devtools/cmake/cmake_aglcore.inc deleted file mode 100644 index 2d50a1f24..000000000 --- a/meta-agl-core/recipes-devtools/cmake/cmake_aglcore.inc +++ /dev/null @@ -1,9 +0,0 @@ -FILESEXTRAPATHS:append := ":${THISDIR}/files" - -SRC_URI:append:class-nativesdk = " \ - file://environment.d-cmake-agl.sh \ -" - -do_install:append:class-nativesdk() { - install -m 644 ${WORKDIR}/environment.d-cmake-agl.sh ${D}${SDKPATHNATIVE}/environment-setup.d/cmake-agl.sh -} diff --git a/meta-agl-core/recipes-devtools/cmake/files/environment.d-cmake-agl.sh b/meta-agl-core/recipes-devtools/cmake/files/environment.d-cmake-agl.sh deleted file mode 100644 index 64b6cf3c6..000000000 --- a/meta-agl-core/recipes-devtools/cmake/files/environment.d-cmake-agl.sh +++ /dev/null @@ -1 +0,0 @@ -export OE_CMAKE_TOOLCHAIN_FILE="$OECORE_NATIVE_SYSROOT/usr/share/cmake/OEToolchainConfig.cmake" diff --git a/meta-agl-core/recipes-devtools/cmake/cmake_%.bbappend b/meta-agl-core/recipes-devtools/qemu/qemu_%.bbappend index 980783236..980783236 100644 --- a/meta-agl-core/recipes-devtools/cmake/cmake_%.bbappend +++ b/meta-agl-core/recipes-devtools/qemu/qemu_%.bbappend diff --git a/meta-agl-core/recipes-devtools/qemu/qemu_aglcore.inc b/meta-agl-core/recipes-devtools/qemu/qemu_aglcore.inc new file mode 100644 index 000000000..77d461a7f --- /dev/null +++ b/meta-agl-core/recipes-devtools/qemu/qemu_aglcore.inc @@ -0,0 +1,5 @@ +PACKAGECONFIG:append = " \ + aio \ + libusb \ + ${@bb.utils.filter('DISTRO_FEATURES', 'selinux', d)} \ +" diff --git a/meta-agl-core/recipes-extended/gperf/.appends.core b/meta-agl-core/recipes-extended/gperf/.appends.core deleted file mode 100644 index e69de29bb..000000000 --- a/meta-agl-core/recipes-extended/gperf/.appends.core +++ /dev/null diff --git a/meta-agl-core/recipes-extended/gperf/gperf_%.bbappend b/meta-agl-core/recipes-extended/gperf/gperf_%.bbappend deleted file mode 100644 index 980783236..000000000 --- a/meta-agl-core/recipes-extended/gperf/gperf_%.bbappend +++ /dev/null @@ -1 +0,0 @@ -require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', '${BPN}_aglcore.inc', '', d)} diff --git a/meta-agl-core/recipes-extended/gperf/gperf_aglcore.inc b/meta-agl-core/recipes-extended/gperf/gperf_aglcore.inc deleted file mode 100644 index 2a590838b..000000000 --- a/meta-agl-core/recipes-extended/gperf/gperf_aglcore.inc +++ /dev/null @@ -1 +0,0 @@ -BBCLASSEXTEND += "nativesdk" diff --git a/meta-agl-core/recipes-graphics/libsdl2/libsdl2_%.bbappend b/meta-agl-core/recipes-graphics/libsdl2/libsdl2_%.bbappend new file mode 100644 index 000000000..48e50788e --- /dev/null +++ b/meta-agl-core/recipes-graphics/libsdl2/libsdl2_%.bbappend @@ -0,0 +1 @@ +require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'libsdl2_aglcore.inc', '', d)} diff --git a/meta-agl-core/recipes-graphics/libsdl2/libsdl2_aglcore.inc b/meta-agl-core/recipes-graphics/libsdl2/libsdl2_aglcore.inc new file mode 100644 index 000000000..7652e1843 --- /dev/null +++ b/meta-agl-core/recipes-graphics/libsdl2/libsdl2_aglcore.inc @@ -0,0 +1,3 @@ +# Make sure opengl is disabled, as using wayland implies gles2 in the +# libsdl2 PACKAGECONFIG definitions. +PACKAGECONFIG:remove = "opengl" diff --git a/meta-agl-core/recipes-graphics/wayland/agl-compositor-init.bb b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init.bb index 0cdf4d5d6..d8baf91f9 100644 --- a/meta-agl-core/recipes-graphics/wayland/agl-compositor-init.bb +++ b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init.bb @@ -1,10 +1,19 @@ -SUMMARY = "Startup systemd unit drop-in file for the AGL Wayland compositor" +SUMMARY = "Startup systemd unit for the AGL Wayland compositor" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420" +inherit systemd + +# Reuse include file from upstream weston since we have the same requirements +require recipes-graphics/wayland/required-distro-features.inc + PACKAGE_ARCH = "${MACHINE_ARCH}" -SRC_URI = "file://agl-compositor.conf.in" +SRC_URI = "file://agl-compositor.service \ + file://agl-compositor.socket \ + file://agl-compositor-autologin \ + file://agl-compositor.conf.in \ +" S = "${WORKDIR}" @@ -15,7 +24,14 @@ AGL_COMPOSITOR_ARGS:append = " ${@bb.utils.contains("DISTRO_FEATURES", "agl-deve AGL_COMPOSITOR_ARGS:append = " ${@bb.utils.contains("WESTON_USE_PIXMAN", "1", " --use-pixman", "",d)}" do_install() { - # Process ".in" files + # Install systemd service + install -D -p -m0644 ${WORKDIR}/agl-compositor.service ${D}${systemd_system_unitdir}/agl-compositor.service + install -D -p -m0644 ${WORKDIR}/agl-compositor.socket ${D}${systemd_system_unitdir}/agl-compositor.socket + if [ "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)}" ]; then + install -D -p -m0644 ${WORKDIR}/agl-compositor-autologin ${D}${sysconfdir}/pam.d/agl-compositor-autologin + fi + + # Install systemd service drop-in with extra configuration files=agl-compositor.conf.in for f in ${files}; do g=${f%.in} @@ -24,17 +40,22 @@ do_install() { ${WORKDIR}/${f} > ${WORKDIR}/${g} fi done - - # Install Weston systemd service drop-in - install -d ${D}${systemd_system_unitdir}/weston.service.d - install -m644 ${WORKDIR}/agl-compositor.conf ${D}/${systemd_system_unitdir}/weston.service.d/agl-compositor.conf + install -d ${D}${systemd_system_unitdir}/agl-compositor.service.d + install -m644 ${WORKDIR}/agl-compositor.conf ${D}/${systemd_system_unitdir}/agl-compositor.service.d/agl-compositor.conf } FILES:${PN} += "\ - ${systemd_system_unitdir}/weston.service.d \ + ${systemd_system_unitdir}/agl-compositor.service \ + ${systemd_system_unitdir}/agl-compositor.socket \ + ${systemd_system_unitdir}/agl-compositor.service.d \ + ${sysconfdir}/default/agl-compositor \ + ${sysconfdir}/pam.d/ \ " -RDEPENDS:${PN} = " \ - agl-compositor \ - weston-init \ -" +CONFFILES:${PN} += "${sysconfdir}/default/agl-compositor" + +RDEPENDS:${PN} = "agl-users agl-compositor weston-ini" + +RCONFLICTS:${PN} = "weston-init" + +SYSTEMD_SERVICE:${PN} = "agl-compositor.service agl-compositor.socket" diff --git a/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor-autologin b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor-autologin new file mode 100644 index 000000000..f6e6d106d --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor-autologin @@ -0,0 +1,11 @@ +auth required pam_nologin.so +auth required pam_unix.so try_first_pass nullok + +account required pam_nologin.so +account required pam_unix.so + +session required pam_env.so +session required pam_unix.so +-session optional pam_systemd.so type=wayland class=user desktop=weston +-session optional pam_loginuid.so + diff --git a/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor.service b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor.service new file mode 100644 index 000000000..4ee14de27 --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor.service @@ -0,0 +1,72 @@ +# This is a system unit for launching AGL compositor with auto-login as the +# user configured here. +# +# AGL compositor and Weston must be built with systemd support, and your +# weston.ini must load the plugin systemd-notify.so. +# +# Attention: +# If you will add new tty dependency setting, you need to update +# agl-compositor-guest.conf. +[Unit] +Description=AGL compositor +Documentation=man:weston(1) man:weston.ini(5) +Documentation=http://wayland.freedesktop.org/ + +# Make sure we are started after logins are permitted. +Requires=systemd-user-sessions.service +After=systemd-user-sessions.service + +# D-Bus is necessary for contacting logind. Logind is required. +Wants=dbus.socket +After=dbus.socket + +# Ensure the socket is present +Requires=agl-compositor.socket + +# Since we are part of the graphical session, make sure we are started before +# it is complete. +Before=graphical.target + +# Prevent starting on systems without virtual consoles, Weston requires one +# for now. +ConditionPathExists=/dev/tty0 + +[Service] +# Requires systemd-notify.so Weston plugin. +Type=notify +EnvironmentFile=-/etc/default/agl-compositor +ExecStart=/usr/bin/agl-compositor --modules=systemd-notify.so + +# Watchdog setup +TimeoutStartSec=60 +WatchdogSec=20 + +# The user to run as. +User=agl-driver +Group=agl-driver + +# Make sure the working directory is the users home directory +WorkingDirectory=/home/agl-driver + +# Set up a full user session for the user +PAMName=agl-compositor-autologin + +# A virtual terminal is needed. +TTYPath=/dev/tty7 +TTYReset=yes +TTYVHangup=yes +TTYVTDisallocate=yes + +# Fail to start if not controlling the tty. +StandardInput=tty-fail +StandardOutput=journal +StandardError=journal + +# Log this user with utmp, letting it show up with commands 'w' and 'who'. +UtmpIdentifier=tty7 +UtmpMode=user + +[Install] +# Note: If you only want weston to start on-demand, remove this line with a +# service drop file +WantedBy=graphical.target diff --git a/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor.socket b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor.socket new file mode 100644 index 000000000..ef9769ff7 --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/agl-compositor-init/agl-compositor.socket @@ -0,0 +1,10 @@ +# +# Weston must be built with systemd support, and your weston.ini must load +# the plugin systemd-notify.so. + +[Unit] +Description=agl-compositor, a Wayland compositor, as a systemd user service +Documentation=https://docs.automotivelinux.org/en/master/#5_Component_Documentation/1_agl-compositor/ + +[Socket] +ListenStream=%t/wayland-0 diff --git a/meta-agl-core/recipes-graphics/wayland/agl-compositor_git.bb b/meta-agl-core/recipes-graphics/wayland/agl-compositor_git.bb index 4ecc81f60..41240309b 100644 --- a/meta-agl-core/recipes-graphics/wayland/agl-compositor_git.bb +++ b/meta-agl-core/recipes-graphics/wayland/agl-compositor_git.bb @@ -8,33 +8,46 @@ SECTION = "x11" LICENSE = "MIT" LIC_FILES_CHKSUM = "file://COPYING;md5=fac6abe0003c4d142ff8fa1f18316df0" -DEPENDS = "wayland wayland-protocols wayland-native weston \ - ${@bb.utils.contains('AGL_FEATURES', 'waltham-remoting', 'waltham waltham-transmitter-plugin', '', d)}" +DEPENDS = "wayland wayland-protocols wayland-native weston" SRC_URI = "git://gerrit.automotivelinux.org/gerrit/src/agl-compositor.git;protocol=https;branch=${AGL_BRANCH}" -SRCREV = "a02c5606aa6621c9d3e0cc968180e7993201e2da" +SRCREV = "18e93caca8ad397d504215d673765871b2c88f25" AGL_BRANCH:aglnext = "next" SRCREV:aglnext = "${AUTOREV}" -PV = "0.0.10+git${SRCPV}" +AGL_COMPOSITOR_VERSION = "0.0.24" + +PV = "${AGL_COMPOSITOR_VERSION}+git${SRCPV}" S = "${WORKDIR}/git" PACKAGECONFIG ?= "" PACKAGECONFIG[policy-rba] = "-Dpolicy-default=rba,,librba,librba rba-config" PACKAGECONFIG[policy-deny-all] = "-Dpolicy-default=deny-all,," +PACKAGECONFIG[grpc-proxy] = "-Dgrpc-proxy=true,-Dgrpc-proxy=false,grpc grpc-native,grpc agl-shell-grpc-server" inherit meson pkgconfig python3native +# Reuse include file from upstream weston since we have the same requirements +require recipes-graphics/wayland/required-distro-features.inc + +PACKAGES =+ "agl-shell-grpc-server" + +LDFLAGS:append:riscv64 = " -Wl,--no-as-needed -latomic -Wl,--as-needed" + FILES:${PN} = " \ ${bindir}/agl-compositor \ ${bindir}/agl-screenshooter \ ${libdir}/agl-compositor/libexec_compositor.so.0 \ - ${libdir}/agl-compositor/libexec_compositor.so.0.0.0 \ + ${libdir}/agl-compositor/libexec_compositor.so.${AGL_COMPOSITOR_VERSION} \ +" + +FILES:agl-shell-grpc-server = " \ + ${libdir}/agl-compositor/agl-shell-grpc-server \ " RDEPENDS:${PN} += " \ agl-compositor-init \ - ${@bb.utils.contains('AGL_FEATURES', 'waltham-remoting', 'waltham waltham-transmitter-plugin', '', d)} \ + xkeyboard-config \ " FILES:${PN}-dev += " \ diff --git a/meta-agl-core/recipes-graphics/wayland/native-shell-client_git.bb b/meta-agl-core/recipes-graphics/wayland/native-shell-client_git.bb new file mode 100644 index 000000000..c0c31e029 --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/native-shell-client_git.bb @@ -0,0 +1,16 @@ +SUMMARY = "Minimal agl-shell Wayland protocol client" + +HOMEPAGE = "https://gerrit.automotivelinux.org/gerrit/q/project:src%252Fnative-shell-client" +SECTION = "x11" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://COPYING;md5=3b90ee643ce04400848a8f0deb492a4a" + +DEPENDS = "wayland wayland-protocols wayland-native agl-compositor" + +SRC_URI = "git://gerrit.automotivelinux.org/gerrit/src/native-shell-client.git;protocol=https;branch=${AGL_BRANCH}" +SRCREV = "099e06f532eff7c56bf00eb58420f14c95a8e554" + +PV = "0.0.1+git${SRCPV}" +S = "${WORKDIR}/git" + +inherit meson pkgconfig diff --git a/meta-agl-core/recipes-graphics/wayland/waltham-transmitter-plugin.bb b/meta-agl-core/recipes-graphics/wayland/waltham-transmitter-plugin.bb deleted file mode 100644 index 734fadf6f..000000000 --- a/meta-agl-core/recipes-graphics/wayland/waltham-transmitter-plugin.bb +++ /dev/null @@ -1,19 +0,0 @@ -DESCRIPTION = "Waltham transmitter is a libweston plug-in that adds support for receiving input events from a surface streamed on a remote output" -HOMEPAGE = "https://gerrit.automotivelinux.org/gerrit/src/waltham-transmitter-plugin.git" - -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://COPYING;md5=f21c9af4de068fb53b83f0b37d262ec3" - -DEPENDS += "wayland wayland-native waltham weston" - -SRC_URI = "git://gerrit.automotivelinux.org/gerrit/src/waltham-transmitter-plugin.git;protocol=https;branch=${AGL_BRANCH}" -AGL_BRANCH:aglnext = "next" -SRCREV = "d64b99a999fcc17322393782fe802122fd963ced" -SRCREV:aglnext = "${AUTOREV}" - -S = "${WORKDIR}/git" - -inherit meson pkgconfig python3native - -FILES:${PN} += "${libdir}/*" -FILES:${PN} += "${bindir}/*" diff --git a/meta-agl-core/recipes-graphics/wayland/waltham/0001-Use-python3-instead-of-2.patch b/meta-agl-core/recipes-graphics/wayland/waltham/0001-Use-python3-instead-of-2.patch deleted file mode 100644 index 32c2df3c4..000000000 --- a/meta-agl-core/recipes-graphics/wayland/waltham/0001-Use-python3-instead-of-2.patch +++ /dev/null @@ -1,51 +0,0 @@ -From 6ecdf10a10929164f3cbdb754ae91d27576e5036 Mon Sep 17 00:00:00 2001 -From: Marius Vlad <marius.vlad@collabora.com> -Date: Fri, 16 Oct 2020 18:57:38 +0300 -Subject: [PATCH] Use python3 instead of 2 - -Signed-off-by: Marius Vlad <marius.vlad@collabora.com> ---- - configure.ac | 2 +- - tools/gen.py | 6 +++--- - 2 files changed, 4 insertions(+), 4 deletions(-) - -diff --git a/configure.ac b/configure.ac -index 5f65a6b..94b8644 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -32,7 +32,7 @@ AC_SUBST(VERSION_INFO) - # Check for programs - AC_PROG_CC - AC_PROG_CC_STDC --AC_CHECK_PROGS([PYTHON2], [python2 python]) -+AC_CHECK_PROGS([PYTHON3], [python3 python]) - PKG_PROG_PKG_CONFIG() - - AC_ARG_ENABLE(gprof, -diff --git a/tools/gen.py b/tools/gen.py -index 19e8baa..64c5870 100755 ---- a/tools/gen.py -+++ b/tools/gen.py -@@ -1,4 +1,4 @@ --#!/usr/bin/env python2 -+#!/usr/bin/env python3 - # -*- coding: utf-8 -*- - - # Copyright © 2013-2014 Collabora, Ltd. -@@ -562,11 +562,11 @@ try: - opts, args = getopt.getopt(sys.argv[1:], "hp:i:o:t:m:", - ["preamble=", "input=", "output=", "type=", "mode="]) - except getopt.GetoptError: -- print 'gen.py -p <preamblefile> -i <inputfile> -o <outputfile> -t <type> -m <mode>' -+ print('gen.py -p <preamblefile> -i <inputfile> -o <outputfile> -t <type> -m <mode>') - sys.exit(2) - for opt, arg in opts: - if opt == '-h': -- print 'gen.py -p <preamblefile> -i <inputfile> -o <outputfile> -t <type> -m <mode>' -+ print('gen.py -p <preamblefile> -i <inputfile> -o <outputfile> -t <type> -m <mode>') - sys.exit() - elif opt in ("-p", "--preamble"): - preamble_files.append(arg) --- -2.28.0 - diff --git a/meta-agl-core/recipes-graphics/wayland/waltham/0001-waltham-Fix-compile-build-error.patch b/meta-agl-core/recipes-graphics/wayland/waltham/0001-waltham-Fix-compile-build-error.patch deleted file mode 100644 index 354bcbc15..000000000 --- a/meta-agl-core/recipes-graphics/wayland/waltham/0001-waltham-Fix-compile-build-error.patch +++ /dev/null @@ -1,55 +0,0 @@ -From cc87dddc2cdc0c20b053e3da1197efd671b4f50c Mon Sep 17 00:00:00 2001 -From: Marius Vlad <marius.vlad@collabora.com> -Date: Wed, 23 Sep 2020 22:33:50 +0300 -Subject: [PATCH 1/2] waltham: Fix compile build error - -Newer compilers will complain about the fact debug_message is declared -multiple times: - -multiple definition of `debug_message'; -.libs/marshaller.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35: -first defined here multiple definition of `debug_message'; -.libs/marshaller.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35: -first defined here /usr/bin/ld: -.libs/client-serialice.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35: -multiple definition of `debug_message'; -.libs/marshaller.o:/home/mvlad/src/native-agl-weston8/waltham/waltham/src/waltham/marshaller_log.h:35: -first defined here - -Bug-AGL: SPEC-3649 - -Signed-off-by: Marius Vlad <marius.vlad@collabora.com> ---- - src/waltham/marshaller_log.h | 2 +- - src/waltham/waltham-util.c | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - -diff --git a/src/waltham/marshaller_log.h b/src/waltham/marshaller_log.h -index 8254914..ffa87c1 100644 ---- a/src/waltham/marshaller_log.h -+++ b/src/waltham/marshaller_log.h -@@ -32,7 +32,7 @@ - /* Comment/uncomment to disable/enable debugging log */ - #define DEBUG - //#define PROFILE --int debug_message; -+extern int debug_message; - - #ifdef DEBUG - static inline void DEBUG_STAMP (void) { -diff --git a/src/waltham/waltham-util.c b/src/waltham/waltham-util.c -index 410b114..8f898f8 100644 ---- a/src/waltham/waltham-util.c -+++ b/src/waltham/waltham-util.c -@@ -34,7 +34,7 @@ - #include "waltham-connection.h" - #include "waltham-private.h" - --int debug_message; -+extern int debug_message; - - static void - wth_pfx_print(const char *pfx, const char *fmt, va_list argp) --- -2.28.0 - diff --git a/meta-agl-core/recipes-graphics/wayland/waltham/0002-commandxml-Add-support-wthp_app_id-interface.patch b/meta-agl-core/recipes-graphics/wayland/waltham/0002-commandxml-Add-support-wthp_app_id-interface.patch deleted file mode 100644 index 5aefb922b..000000000 --- a/meta-agl-core/recipes-graphics/wayland/waltham/0002-commandxml-Add-support-wthp_app_id-interface.patch +++ /dev/null @@ -1,70 +0,0 @@ -From d30005429fe92daa14151c2a6175d5cf19506cac Mon Sep 17 00:00:00 2001 -From: Marius Vlad <marius.vlad@collabora.com> -Date: Wed, 7 Oct 2020 16:36:38 +0300 -Subject: [PATCH 2/2] commandxml: Add support wthp_app_id interface - -With it, we hang off the app_id which we can use to pass it to the -receiver side. - -Bug-AGL: SPEC-3601 - -Signed-off-by: Marius Vlad <marius.vlad@collabora.com> ---- - data/command.xml | 29 +++++++++++++++++++++++++++++ - src/waltham/header-preamble.txt | 1 + - 2 files changed, 30 insertions(+) - -diff --git a/data/command.xml b/data/command.xml -index a03082b..cb53f75 100644 ---- a/data/command.xml -+++ b/data/command.xml -@@ -1814,6 +1814,35 @@ - - </interface> - -+ <interface name="wthp_ivi_app_id" version="1"> -+ <description summary="create ivi-style surfaces"> -+ This interface is exposed as a global singleton. -+ This interface is implemented by servers that provide IVI-style user interfaces. -+ It allows clients to associate an ivi_surface with wthp_surface. -+ </description> -+ -+ <enum name="error"> -+ <entry name="role" value="0" summary="given wthp_surface has another role"/> -+ </enum> -+ -+ <request name="surface_create"> -+ <description summary="create ivi_surface with app_id in ivi compositor"> -+ This request gives the wthp_surface the role of an IVI Surface. Creating more than -+ one ivi_surface for a wthp_surface is not allowed. Note, that this still allows the -+ following example: -+ -+ 1. create a wthp_surface -+ 2. create ivi_surface for the wthp_surface -+ 3. destroy the ivi_surface -+ -+ </description> -+ <arg name="app_id" type="string"/> -+ <arg name="surface" type="object" interface="wthp_surface"/> -+ <arg name="id" type="new_id" interface="wthp_ivi_surface"/> -+ </request> -+ -+ </interface> -+ - <interface name="dummy" version="1"> - <request name="dummy_request"> - </request> -diff --git a/src/waltham/header-preamble.txt b/src/waltham/header-preamble.txt -index df765cc..2409859 100644 ---- a/src/waltham/header-preamble.txt -+++ b/src/waltham/header-preamble.txt -@@ -50,5 +50,6 @@ struct wthp_touch; - - struct wthp_ivi_surface; - struct wthp_ivi_application; -+struct wthp_ivi_app_id; - - struct dummy; --- -2.28.0 - diff --git a/meta-agl-core/recipes-graphics/wayland/waltham_%.bbappend b/meta-agl-core/recipes-graphics/wayland/waltham_%.bbappend deleted file mode 100644 index 302eba4d2..000000000 --- a/meta-agl-core/recipes-graphics/wayland/waltham_%.bbappend +++ /dev/null @@ -1,7 +0,0 @@ -FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" - -SRC_URI:append = "\ - file://0001-waltham-Fix-compile-build-error.patch \ - file://0002-commandxml-Add-support-wthp_app_id-interface.patch \ - file://0001-Use-python3-instead-of-2.patch \ - " diff --git a/meta-agl-core/recipes-graphics/wayland/waltham_git.bb b/meta-agl-core/recipes-graphics/wayland/waltham_git.bb deleted file mode 100644 index da092a5e7..000000000 --- a/meta-agl-core/recipes-graphics/wayland/waltham_git.bb +++ /dev/null @@ -1,16 +0,0 @@ -DESCRIPTION = "Waltham is a network IPC library designed to resemble Wayland both protocol and protocol-API wise" -HOMEPAGE = "https://github.com/waltham/waltham" - -LICENSE = "MIT" -LIC_FILES_CHKSUM = " \ - file://LICENSE;md5=e8ad01a5182f2c1b3a2640e9ea268264 \ -" -SRCREV = "1de58c3ff746ddaba7584d760c5454243723d3ca" -SRC_URI = "git://github.com/wmizuno/waltham.git;branch=master;protocol=https \ - " -S = "${WORKDIR}/git" - -inherit autotools pkgconfig - -DEPENDS += "libdrm virtual/kernel wayland" -RDEPENDS:${PN} += "libdrm"
\ No newline at end of file diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bb b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bb index c04ff6568..0611ec5b4 100644 --- a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bb +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bb @@ -9,12 +9,16 @@ SRC_URI = " \ file://hdmi-a-1-90.cfg \ file://hdmi-a-1-180.cfg \ file://hdmi-a-1-270.cfg \ - file://remote-output.cfg \ - file://transmitter-output.cfg.in \ + file://hdmi-a-2-0.cfg \ + file://hdmi-a-2-90.cfg \ + file://hdmi-a-2-180.cfg \ + file://hdmi-a-2-270.cfg \ + file://remote-output.cfg.in \ file://virtual-0.cfg \ file://virtual-90.cfg \ file://virtual-180.cfg \ file://virtual-270.cfg \ + file://grpc-proxy.cfg \ " S = "${WORKDIR}" @@ -27,22 +31,21 @@ WESTON_DISPLAYS ?= "hdmi-a-1-90" # Configuration fragments to use in weston.ini.* # Note that some may be replaced/removed when building the landscape # configuration. -WESTON_FRAGMENTS = "core shell ${WESTON_DISPLAYS}" +WESTON_FRAGMENTS = "core shell grpc-proxy ${WESTON_DISPLAYS}" # On-target weston.ini directory weston_ini_dir = "${sysconfdir}/xdg/weston" # Options for the user to change in local.conf -# e.g. TRANSMITTER_OUTPUT_MODE = "1080x1488" -TRANSMITTER_OUTPUT_MODE ??= "640x720@30" -TRANSMITTER_OUTPUT_HOST ??= "192.168.20.99" -TRANSMITTER_OUTPUT_PORT ??= "5005" +# e.g. REMOTING_OUTPUT_MODE = "1080x1488" +REMOTING_OUTPUT_MODE ??= "640x720@30" +REMOTING_OUTPUT_HOST ??= "192.168.10.3" +REMOTING_OUTPUT_PORT ??= "5005" do_configure() { - sed -e "s#mode=.*#mode=${TRANSMITTER_OUTPUT_MODE}#" \ - -e "s#host=.*#host=${TRANSMITTER_OUTPUT_HOST}#" \ - -e "s#port=.*#port=${TRANSMITTER_OUTPUT_PORT}#" \ - ${WORKDIR}/transmitter-output.cfg.in > ${WORKDIR}/transmitter-output.cfg + sed -e "s#host=.*#host=${REMOTING_OUTPUT_HOST}#" \ + -e "s#port=.*#port=${REMOTING_OUTPUT_PORT}#" \ + ${WORKDIR}/remote-output.cfg.in > ${WORKDIR}/remote-output.cfg } do_compile() { @@ -55,15 +58,21 @@ do_compile() { done sed -i -e '$ d' ${WORKDIR}/weston.ini.default + cat ${WORKDIR}/weston.ini.default > ${WORKDIR}/weston.ini.default-no-activate + # Do it again, but filter fragments to configure for landscape # and a corresponding landscape-inverted that is 180 degrees # rotated. rm -f ${WORKDIR}/weston.ini.landscape + rm -f ${WORKDIR}/weston.ini.landscape-inverted for F in ${WESTON_FRAGMENTS}; do INVF=$F if echo $F | grep '^hdmi-a-1-\(90\|270\)$'; then F="hdmi-a-1-0" INVF="hdmi-a-1-180" + elif echo $F | grep '^hdmi-a-2-\(90\|270\)$'; then + F="hdmi-a-2-0" + INVF="hdmi-a-2-180" elif echo $F | grep '^virtual-90$'; then F="virtual-0" INVF="virtual-180" @@ -75,11 +84,15 @@ do_compile() { done sed -i -e '$ d' ${WORKDIR}/weston.ini.landscape sed -i -e '$ d' ${WORKDIR}/weston.ini.landscape-inverted + + cat ${WORKDIR}/weston.ini.landscape > ${WORKDIR}/weston.ini.landscape-no-activate } do_install:append() { install -d ${D}${weston_ini_dir} install -m 0644 ${WORKDIR}/weston.ini.default ${D}${weston_ini_dir}/ + install -m 0644 ${WORKDIR}/weston.ini.default-no-activate ${D}${weston_ini_dir}/ + install -m 0644 ${WORKDIR}/weston.ini.landscape-no-activate ${D}${weston_ini_dir}/ install -m 0644 ${WORKDIR}/weston.ini.landscape ${D}${weston_ini_dir}/ install -m 0644 ${WORKDIR}/weston.ini.landscape-inverted ${D}${weston_ini_dir}/ } @@ -95,7 +108,6 @@ PACKAGE_ARCH = "${MACHINE_ARCH}" ALTERNATIVE_LINK_NAME[weston.ini] = "${weston_ini_dir}/weston.ini" -RDEPENDS:${PN} = "weston-init" RPROVIDES:${PN} = "weston-ini" RCONFLICTS:${PN} = "${PN}-landscape" ALTERNATIVE:${PN} = "weston.ini" @@ -105,7 +117,6 @@ PACKAGE_BEFORE_PN += "${PN}-landscape" FILES:${PN}-landscape = "${weston_ini_dir}/weston.ini.landscape" -RDEPENDS:${PN}-landscape = "weston-init" RPROVIDES:${PN}-landscape = "weston-ini" RCONFLICTS:${PN}-landscape = "${PN}" ALTERNATIVE:${PN}-landscape = "weston.ini" @@ -115,8 +126,31 @@ PACKAGE_BEFORE_PN += "${PN}-landscape-inverted" FILES:${PN}-landscape-inverted = "${weston_ini_dir}/weston.ini.landscape-inverted" -RDEPENDS:${PN}-landscape-inverted = "weston-init" RPROVIDES:${PN}-landscape-inverted = "weston-ini" RCONFLICTS:${PN}-landscape-inverted = "${PN}" ALTERNATIVE:${PN}-landscape-inverted = "weston.ini" ALTERNATIVE_TARGET_${PN}-landscape-inverted = "${weston_ini_dir}/weston.ini.landscape-inverted" + +# no activation by default +PACKAGE_BEFORE_PN += "${PN}-no-activate" + +FILES:${PN}-no-activate = "${weston_ini_dir}/weston.ini.default-no-activate" + +RPROVIDES:${PN}-no-activate = "weston-ini" +RCONFLICTS:${PN}-no-activate = "${PN}" +ALTERNATIVE:${PN}-no-activate = "weston.ini" +ALTERNATIVE_TARGET_${PN}-no-activate = "${weston_ini_dir}/weston.ini.default-no-activate" + +# landscape, no activation by default +PACKAGE_BEFORE_PN += "${PN}-landscape-no-activate" + +FILES:${PN}-landscape-no-activate = "${weston_ini_dir}/weston.ini.landscape-no-activate" + +RPROVIDES:${PN}-landscape-no-activate = "weston-ini" +RCONFLICTS:${PN}-landscape-no-activate = "${PN}" +ALTERNATIVE:${PN}-landscape-no-activate = "weston.ini" +ALTERNATIVE_TARGET_${PN}-landscape-no-activate = "${weston_ini_dir}/weston.ini.landscape-no-activate" + +# This is a settings-only package, we do not need a development package +# (and its fixed dependency to ${PN} being installed) +PACKAGES:remove = "${PN}-dev ${PN}-staticdev" diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bbappend b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bbappend index d441d6577..746bde339 100644 --- a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bbappend +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf.bbappend @@ -3,10 +3,10 @@ FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" PACKAGE_ARCH = "${MACHINE_ARCH}" WESTON_DISPLAYS:append = "${@bb.utils.contains("DISTRO_FEATURES", "weston-remoting", " remote-output", "", d)}" -WESTON_DISPLAYS:append = "${@bb.utils.contains("AGL_FEATURES", "waltham-remoting", " transmitter-output", "", d)}" # For virtual machines and intel-corei7-64 we want to support both the HDMI-A-1 # and Virtual-1 outputs. This allows us to run virtual images on real hardware # and vice versa. WESTON_DISPLAYS:append:qemuall = " virtual-90" WESTON_DISPLAYS:append:intel-corei7-64 = " virtual-90" +WESTON_DISPLAYS:append:virtio-aarch64 = " virtual-90" diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/core.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/core.cfg index 90774ed79..28f90752d 100644 --- a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/core.cfg +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/core.cfg @@ -1,4 +1,6 @@ [core] backend=drm-backend.so require-input=false +idle-time=0 modules=systemd-notify.so +activate-by-default=false diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/grpc-proxy.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/grpc-proxy.cfg new file mode 100644 index 000000000..14805b969 --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/grpc-proxy.cfg @@ -0,0 +1,4 @@ + +[shell-client-ext] +command=/usr/lib/agl-compositor/agl-shell-grpc-server + diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-0.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-0.cfg new file mode 100644 index 000000000..4d5d51c03 --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-0.cfg @@ -0,0 +1,5 @@ +# A display is connected to HDMI-A-1 and needs to be rotated 90 degrees +# to have a proper orientation of the homescreen. For example, the 'eGalax' +# display used in some instances. +[output] +name=HDMI-A-2 diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-180.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-180.cfg new file mode 100644 index 000000000..ffdc5fe60 --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-180.cfg @@ -0,0 +1,6 @@ +# A display is connected to HDMI-A-1 and needs to be rotated 90 degrees +# to have a proper orientation of the homescreen. For example, the 'eGalax' +# display used in some instances. +[output] +name=HDMI-A-2 +transform=rotate-180 diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-270.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-270.cfg new file mode 100644 index 000000000..76fc77acd --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-270.cfg @@ -0,0 +1,6 @@ +# A display is connected to HDMI-A-1 and needs to be rotated 90 degrees +# to have a proper orientation of the homescreen. For example, the 'eGalax' +# display used in some instances. +[output] +name=HDMI-A-2 +transform=rotate-270 diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-90.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-90.cfg new file mode 100644 index 000000000..9172a1c6a --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/hdmi-a-2-90.cfg @@ -0,0 +1,6 @@ +# A display is connected to HDMI-A-1 and needs to be rotated 90 degrees +# to have a proper orientation of the homescreen. For example, the 'eGalax' +# display used in some instances. +[output] +name=HDMI-A-2 +transform=rotate-90 diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/remote-output.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/remote-output.cfg.in index f69a2e096..940cbdd0c 100644 --- a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/remote-output.cfg +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/remote-output.cfg.in @@ -1,5 +1,5 @@ [remote-output] name=remote-1 mode=640x720@30 -host=192.168.20.99 +host=192.168.10.3 port=5005 diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/shell.cfg b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/shell.cfg index 975e539e6..8d16ba5d7 100644 --- a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/shell.cfg +++ b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/shell.cfg @@ -1,3 +1,3 @@ [shell] -locking=true +locking=false panel-position=none diff --git a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/transmitter-output.cfg.in b/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/transmitter-output.cfg.in deleted file mode 100644 index e77f74ec0..000000000 --- a/meta-agl-core/recipes-graphics/wayland/weston-ini-conf/transmitter-output.cfg.in +++ /dev/null @@ -1,5 +0,0 @@ -[transmitter-output] -name=transmitter-1 -mode=640x720@30 -host=192.168.20.99 -port=5005 diff --git a/meta-agl-core/recipes-graphics/wayland/weston/0001-clients-Handle-missing-pointer_surface-is-there-s-no.patch b/meta-agl-core/recipes-graphics/wayland/weston/0001-clients-Handle-missing-pointer_surface-is-there-s-no.patch new file mode 100644 index 000000000..202333a5e --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston/0001-clients-Handle-missing-pointer_surface-is-there-s-no.patch @@ -0,0 +1,30 @@ +From 6a847464de9e773f6d1490916d0df48a0f90eeba Mon Sep 17 00:00:00 2001 +From: Marius Vlad <marius.vlad@collabora.com> +Date: Thu, 5 Oct 2023 16:27:34 +0300 +Subject: [PATCH] clients: Handle missing pointer_surface is there's no pointer + event + +Upstream-Status: Pending + +Bug-AGL: SPEC-4916 +Signed-off-by: Marius Vlad <marius.vlad@collabora.com> +--- + clients/window.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/clients/window.c b/clients/window.c +index 30f6410..882e9d5 100644 +--- a/clients/window.c ++++ b/clients/window.c +@@ -3818,7 +3818,7 @@ pointer_surface_frame_callback(void *data, struct wl_callback *callback, + force_frame = false; + } + +- if (!input->pointer) ++ if (!input->pointer || !input->pointer_surface) + return; + + if (input_set_pointer_special(input)) +-- +2.35.1 + diff --git a/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-Add-paint-node-destruction-into-weston_lay.patch b/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-Add-paint-node-destruction-into-weston_lay.patch new file mode 100644 index 000000000..19eadcf7f --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-Add-paint-node-destruction-into-weston_lay.patch @@ -0,0 +1,60 @@ +From cfde02d47a503cbfd0629bbfe0cb776686af8a91 Mon Sep 17 00:00:00 2001 +From: Marius Vlad <marius.vlad@collabora.com> +Date: Tue, 9 Apr 2024 18:34:22 +0300 +Subject: [PATCH] libweston: Add paint node destruction into + weston_layer_entry_remove() + +This prevents a potential crash where users of +weston_layer_entry_insert/layer_entry_remove() would see when moving +views into a NULL layer (effectively unmapping the surface/view). + +Users that have migrated to the weston_view_move_to_layer() are immune +to this issue because that takes care paint node destruction. + +Signed-off-by: Marius Vlad <marius.vlad@collabora.com> +--- + libweston/compositor.c | 17 ++++++++++------- + 1 file changed, 10 insertions(+), 7 deletions(-) + +diff --git a/libweston/compositor.c b/libweston/compositor.c +index bb29b83b5..ea257bb90 100644 +--- a/libweston/compositor.c ++++ b/libweston/compositor.c +@@ -3980,17 +3980,10 @@ weston_view_move_to_layer(struct weston_view *view, + struct weston_layer_entry *layer) + { + bool was_mapped = view->is_mapped; +- struct weston_paint_node *pnode, *pntmp; + + if (layer == &view->layer_link) + return; + +- /* Remove all paint nodes because we have no idea what a layer change +- * does to view visibility on any output. +- */ +- wl_list_for_each_safe(pnode, pntmp, &view->paint_node_list, view_link) +- weston_paint_node_destroy(pnode); +- + view->surface->compositor->view_list_needs_rebuild = true; + + /* Damage the view's old region, and remove it from the layer. */ +@@ -4020,6 +4013,16 @@ weston_view_move_to_layer(struct weston_view *view, + WL_EXPORT void + weston_layer_entry_remove(struct weston_layer_entry *entry) + { ++ struct weston_paint_node *pnode, *pntmp; ++ struct weston_view *view; ++ ++ /* Remove all paint nodes because we have no idea what a layer change ++ * does to view visibility on any output. ++ */ ++ view = container_of(entry, struct weston_view, layer_link); ++ wl_list_for_each_safe(pnode, pntmp, &view->paint_node_list, view_link) ++ weston_paint_node_destroy(pnode); ++ + wl_list_remove(&entry->link); + wl_list_init(&entry->link); + entry->layer = NULL; +-- +2.43.0 + diff --git a/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-Migrate-weston_seat_init-release-to-public.patch b/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-Migrate-weston_seat_init-release-to-public.patch deleted file mode 100644 index 02af7cbaf..000000000 --- a/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-Migrate-weston_seat_init-release-to-public.patch +++ /dev/null @@ -1,106 +0,0 @@ -From 4534fcab54409b08faf4445ed6780136b58afb63 Mon Sep 17 00:00:00 2001 -From: Marius Vlad <marius.vlad@collabora.com> -Date: Mon, 28 Sep 2020 22:51:00 +0300 -Subject: [PATCH 1/2] libweston: Migrate weston_seat_init/release to public - headers - -weston_seat_init/release needed for creating weston plug-ins that want -manage seat/input on their own. - -Signed-off-by: Marius Vlad <marius.vlad@collabora.com> ---- - include/libweston/libweston.h | 25 +++++++++++++++++++++++++ - libweston/libweston-internal.h | 31 +++---------------------------- - 2 files changed, 28 insertions(+), 28 deletions(-) - -diff --git a/include/libweston/libweston.h b/include/libweston/libweston.h -index 54ea008..59541f2 100644 ---- a/include/libweston/libweston.h -+++ b/include/libweston/libweston.h -@@ -2053,6 +2053,31 @@ void - weston_timeline_refresh_subscription_objects(struct weston_compositor *wc, - void *object); - -+/* input, seat */ -+void -+weston_seat_init(struct weston_seat *seat, struct weston_compositor *ec, -+ const char *seat_name); -+void -+weston_seat_release(struct weston_seat *seat); -+ -+void -+weston_seat_init_pointer(struct weston_seat *seat); -+ -+int -+weston_seat_init_keyboard(struct weston_seat *seat, struct xkb_keymap *keymap); -+ -+void -+weston_seat_init_touch(struct weston_seat *seat); -+ -+void -+weston_seat_release_keyboard(struct weston_seat *seat); -+ -+void -+weston_seat_release_pointer(struct weston_seat *seat); -+ -+void -+weston_seat_release_touch(struct weston_seat *seat); -+ - #ifdef __cplusplus - } - #endif -diff --git a/libweston/libweston-internal.h b/libweston/libweston-internal.h -index 66c38e8..f5c4c2c 100644 ---- a/libweston/libweston-internal.h -+++ b/libweston/libweston-internal.h -@@ -168,44 +168,19 @@ weston_plane_init(struct weston_plane *plane, - void - weston_plane_release(struct weston_plane *plane); - --/* weston_seat */ -- - struct clipboard * - clipboard_create(struct weston_seat *seat); - --void --weston_seat_init(struct weston_seat *seat, struct weston_compositor *ec, -- const char *seat_name); -- --void --weston_seat_repick(struct weston_seat *seat); -+/* weston_seat */ - - void --weston_seat_release(struct weston_seat *seat); -+weston_seat_update_keymap(struct weston_seat *seat, struct xkb_keymap *keymap); - - void - weston_seat_send_selection(struct weston_seat *seat, struct wl_client *client); - - void --weston_seat_init_pointer(struct weston_seat *seat); -- --int --weston_seat_init_keyboard(struct weston_seat *seat, struct xkb_keymap *keymap); -- --void --weston_seat_init_touch(struct weston_seat *seat); -- --void --weston_seat_release_keyboard(struct weston_seat *seat); -- --void --weston_seat_release_pointer(struct weston_seat *seat); -- --void --weston_seat_release_touch(struct weston_seat *seat); -- --void --weston_seat_update_keymap(struct weston_seat *seat, struct xkb_keymap *keymap); -+weston_seat_repick(struct weston_seat *seat); - - void - wl_data_device_set_keyboard_focus(struct weston_seat *seat); --- -2.28.0 - diff --git a/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-add-weston_layer_fini.patch b/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-add-weston_layer_fini.patch deleted file mode 100644 index 5b4fd04c4..000000000 --- a/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-add-weston_layer_fini.patch +++ /dev/null @@ -1,82 +0,0 @@ -From 8740037a93c7c4400cc381ecf3009d1e4014be07 Mon Sep 17 00:00:00 2001 -From: Pekka Paalanen <pekka.paalanen@collabora.com> -Upstream-Status: Backport -Date: Fri, 14 May 2021 14:29:40 +0300 -Subject: [PATCH] libweston: add weston_layer_fini() - -Layers did not have a fini sequence before, which means the compositor -layer list might have stale pointers temporarily when shutting down. A -bigger problem might be having views linger after the destruction of the -layer. - -These problems were not observed yet, but if they exist, this patch -should help to find them and then fix them. - -The check in weston_compositor_shutdown() is not an assert yet, because -it will trigger until all components call weston_layer_fini() correctly. -Some components do not even have a tear-down function to call it from at -all, like fullscreen-shell. - -The same with the check in weston_layer_fini(). - -Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com> ---- - include/libweston/libweston.h | 2 ++ - libweston/compositor.c | 21 +++++++++++++++++++++ - 2 files changed, 23 insertions(+) - -diff --git a/include/libweston/libweston.h b/include/libweston/libweston.h -index 7e8e7a625..d9907de0d 100644 ---- a/include/libweston/libweston.h -+++ b/include/libweston/libweston.h -@@ -1637,6 +1637,8 @@ void - weston_layer_init(struct weston_layer *layer, - struct weston_compositor *compositor); - void -+weston_layer_fini(struct weston_layer *layer); -+void - weston_layer_set_position(struct weston_layer *layer, - enum weston_layer_position position); - void -diff --git a/libweston/compositor.c b/libweston/compositor.c -index dc6ecb2ce..c2da3a48c 100644 ---- a/libweston/compositor.c -+++ b/libweston/compositor.c -@@ -3243,6 +3243,21 @@ weston_layer_init(struct weston_layer *layer, - weston_layer_set_mask_infinite(layer); - } - -+/** Finalize the weston_layer struct. -+ * -+ * \param layer The layer to finalize. -+ */ -+WL_EXPORT void -+weston_layer_fini(struct weston_layer *layer) -+{ -+ wl_list_remove(&layer->link); -+ -+ if (!wl_list_empty(&layer->view_list.link)) -+ weston_log("BUG: finalizing a layer with views still on it.\n"); -+ -+ wl_list_remove(&layer->view_list.link); -+} -+ - /** Sets the position of the layer in the layer list. The layer will be placed - * below any layer with the same position value, if any. - * This function is safe to call if the layer is already on the list, but the -@@ -7738,6 +7753,12 @@ weston_compositor_shutdown(struct weston_compositor *ec) - weston_binding_list_destroy_all(&ec->debug_binding_list); - - weston_plane_release(&ec->primary_plane); -+ -+ weston_layer_fini(&ec->fade_layer); -+ weston_layer_fini(&ec->cursor_layer); -+ -+ if (!wl_list_empty(&ec->layer_list)) -+ weston_log("BUG: layer_list is not empty after shutdown. Calls to weston_layer_fini() are missing somwhere.\n"); - } - - /** weston_compositor_exit_with_code --- -GitLab - diff --git a/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-desktop-rename-weston_desktop_client_destr.patch b/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-desktop-rename-weston_desktop_client_destr.patch deleted file mode 100644 index 5332a89b0..000000000 --- a/meta-agl-core/recipes-graphics/wayland/weston/0001-libweston-desktop-rename-weston_desktop_client_destr.patch +++ /dev/null @@ -1,51 +0,0 @@ -From 5a6604a7a2e52e5cd84c1f53724b3f7c325b5dff Mon Sep 17 00:00:00 2001 -From: Pekka Paalanen <pekka.paalanen@collabora.com> -Upstream-Status: Backport -Date: Fri, 14 May 2021 15:54:56 +0300 -Subject: [PATCH] libweston-desktop: rename weston_desktop_client_destroy() - -This function here is a wl_resource destructor, but we will need another -function for externally triggered destroy when wl_resource does not -exist. - -Rename the existing function, because the old name fits better the new -function to be written. - -Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com> ---- - libweston-desktop/client.c | 9 ++++----- - 1 file changed, 4 insertions(+), 5 deletions(-) - -diff --git a/libweston-desktop/client.c b/libweston-desktop/client.c -index 56413f713..ba7bfbc46 100644 ---- a/libweston-desktop/client.c -+++ b/libweston-desktop/client.c -@@ -49,7 +49,7 @@ weston_desktop_client_add_destroy_listener(struct weston_desktop_client *client, - } - - static void --weston_desktop_client_destroy(struct wl_resource *resource) -+weston_desktop_client_handle_destroy(struct wl_resource *resource) - { - struct weston_desktop_client *client = - wl_resource_get_user_data(resource); -@@ -117,13 +117,12 @@ weston_desktop_client_create(struct weston_desktop *desktop, - - if (dispatcher != NULL) - wl_resource_set_dispatcher(client->resource, dispatcher, -- weston_desktop_client_destroy, client, -- weston_desktop_client_destroy); -+ weston_desktop_client_handle_destroy, client, -+ weston_desktop_client_handle_destroy); - else - wl_resource_set_implementation(client->resource, implementation, - client, -- weston_desktop_client_destroy); -- -+ weston_desktop_client_handle_destroy); - - display = wl_client_get_display(client->client); - loop = wl_display_get_event_loop(display); --- -GitLab - diff --git a/meta-agl-core/recipes-graphics/wayland/weston/0002-libweston-desktop-introduce-weston_desktop_client_de.patch b/meta-agl-core/recipes-graphics/wayland/weston/0002-libweston-desktop-introduce-weston_desktop_client_de.patch deleted file mode 100644 index 229c8506a..000000000 --- a/meta-agl-core/recipes-graphics/wayland/weston/0002-libweston-desktop-introduce-weston_desktop_client_de.patch +++ /dev/null @@ -1,88 +0,0 @@ -From f53c05d3c2c19c139c52e9bd621c2654dd3dac69 Mon Sep 17 00:00:00 2001 -From: Pekka Paalanen <pekka.paalanen@collabora.com> -Upstream-Status: Backport -Date: Fri, 14 May 2021 16:04:45 +0300 -Subject: [PATCH] libweston-desktop: introduce weston_desktop_client_destroy() - -This new function is callable explicitly, unlike the old function that -used to have the same name. - -This will be needed when tearing down what -weston_desktop_xwayland_init() puts up. - -Since calling weston_desktop_client_destroy() for an external client -(one that has a wl_resource for this) is a bug, add asserts to prevent -it. This will only be needed for the internal client: XWM. - -Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com> ---- - libweston-desktop/client.c | 21 +++++++++++++++++---- - libweston-desktop/internal.h | 2 ++ - 2 files changed, 19 insertions(+), 4 deletions(-) - -diff --git a/libweston-desktop/client.c b/libweston-desktop/client.c -index ba7bfbc46..44718e2db 100644 ---- a/libweston-desktop/client.c -+++ b/libweston-desktop/client.c -@@ -24,6 +24,7 @@ - #include "config.h" - - #include <wayland-server.h> -+#include <assert.h> - - #include <libweston/libweston.h> - #include <libweston/zalloc.h> -@@ -48,14 +49,14 @@ weston_desktop_client_add_destroy_listener(struct weston_desktop_client *client, - wl_signal_add(&client->destroy_signal, listener); - } - --static void --weston_desktop_client_handle_destroy(struct wl_resource *resource) -+void -+weston_desktop_client_destroy(struct weston_desktop_client *client) - { -- struct weston_desktop_client *client = -- wl_resource_get_user_data(resource); - struct wl_list *list = &client->surface_list; - struct wl_list *link, *tmp; - -+ assert(client->resource == NULL); -+ - wl_signal_emit(&client->destroy_signal, client); - - for (link = list->next, tmp = link->next; -@@ -71,6 +72,18 @@ weston_desktop_client_handle_destroy(struct wl_resource *resource) - free(client); - } - -+static void -+weston_desktop_client_handle_destroy(struct wl_resource *resource) -+{ -+ struct weston_desktop_client *client = -+ wl_resource_get_user_data(resource); -+ -+ assert(client->resource == resource); -+ client->resource = NULL; -+ -+ weston_desktop_client_destroy(client); -+} -+ - static int - weston_desktop_client_ping_timeout(void *user_data) - { -diff --git a/libweston-desktop/internal.h b/libweston-desktop/internal.h -index e4ab2701b..7a815bd87 100644 ---- a/libweston-desktop/internal.h -+++ b/libweston-desktop/internal.h -@@ -134,6 +134,8 @@ weston_desktop_client_create(struct weston_desktop *desktop, - const struct wl_interface *interface, - const void *implementation, uint32_t version, - uint32_t id); -+void -+weston_desktop_client_destroy(struct weston_desktop_client *client); - - void - weston_desktop_client_add_destroy_listener(struct weston_desktop_client *client, --- -GitLab - diff --git a/meta-agl-core/recipes-graphics/wayland/weston/0003-libweston-desktop-add-weston_desktop_xwayland_fini.patch b/meta-agl-core/recipes-graphics/wayland/weston/0003-libweston-desktop-add-weston_desktop_xwayland_fini.patch deleted file mode 100644 index 1bcf5c7b4..000000000 --- a/meta-agl-core/recipes-graphics/wayland/weston/0003-libweston-desktop-add-weston_desktop_xwayland_fini.patch +++ /dev/null @@ -1,99 +0,0 @@ -From e2583ca0844bd7a8ce4fc94da9ad67edf49ffd45 Mon Sep 17 00:00:00 2001 -From: Pekka Paalanen <pekka.paalanen@collabora.com> -Upstream-Status: Backport -Date: Fri, 14 May 2021 16:12:35 +0300 -Subject: [PATCH] libweston-desktop: add weston_desktop_xwayland_fini() - -This fixes the following leaks detected by ASan in -./tests/test-alpha-blending: - -Direct leak of 176 byte(s) in 2 object(s) allocated from: - #0 0x7fb447880518 in calloc (/lib/x86_64-linux-gnu/libasan.so.5+0xe9518) - #1 0x7fb4432c12d7 in zalloc ../../git/weston/include/libweston/zalloc.h:38 - #2 0x7fb4432c2ca6 in weston_desktop_xwayland_init ../../git/weston/libweston-desktop/xwayland.c:410 - #3 0x7fb4432baadf in weston_desktop_create ../../git/weston/libweston-desktop/libweston-desktop.c:87 - #4 0x7fb4432e1e1f in wet_shell_init ../../git/weston/tests/weston-test-desktop-shell.c:224 - #5 0x7fb44775fddd in wet_load_shell ../../git/weston/compositor/main.c:956 - #6 0x7fb447770db1 in wet_main ../../git/weston/compositor/main.c:3434 - #7 0x56172c599279 in execute_compositor ../../git/weston/tests/weston-test-fixture-compositor.c:432 - #8 0x56172c59cce5 in weston_test_harness_execute_as_client ../../git/weston/tests/weston-test-runner.c:528 - #9 0x56172c58dc8c in fixture_setup ../../git/weston/tests/alpha-blending-test.c:65 - #10 0x56172c58dd31 in fixture_setup_run_ ../../git/weston/tests/alpha-blending-test.c:67 - #11 0x56172c59d29a in main ../../git/weston/tests/weston-test-runner.c:661 - #12 0x7fb4473d509a in __libc_start_main ../csu/libc-start.c:308 - -Indirect leak of 144 byte(s) in 2 object(s) allocated from: - #0 0x7fb447880518 in calloc (/lib/x86_64-linux-gnu/libasan.so.5+0xe9518) - #1 0x7fb4432bb592 in zalloc ../../git/weston/include/libweston/zalloc.h:38 - #2 0x7fb4432bb882 in weston_desktop_client_create ../../git/weston/libweston-desktop/client.c:108 - #3 0x7fb4432c2d0e in weston_desktop_xwayland_init ../../git/weston/libweston-desktop/xwayland.c:415 - #4 0x7fb4432baadf in weston_desktop_create ../../git/weston/libweston-desktop/libweston-desktop.c:87 - #5 0x7fb4432e1e1f in wet_shell_init ../../git/weston/tests/weston-test-desktop-shell.c:224 - #6 0x7fb44775fddd in wet_load_shell ../../git/weston/compositor/main.c:956 - #7 0x7fb447770db1 in wet_main ../../git/weston/compositor/main.c:3434 - #8 0x56172c599279 in execute_compositor ../../git/weston/tests/weston-test-fixture-compositor.c:432 - #9 0x56172c59cce5 in weston_test_harness_execute_as_client ../../git/weston/tests/weston-test-runner.c:528 - #10 0x56172c58dc8c in fixture_setup ../../git/weston/tests/alpha-blending-test.c:65 - #11 0x56172c58dd31 in fixture_setup_run_ ../../git/weston/tests/alpha-blending-test.c:67 - #12 0x56172c59d29a in main ../../git/weston/tests/weston-test-runner.c:661 - #13 0x7fb4473d509a in __libc_start_main ../csu/libc-start.c:308 - -Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.com> ---- - libweston-desktop/internal.h | 2 ++ - libweston-desktop/libweston-desktop.c | 2 ++ - libweston-desktop/xwayland.c | 16 ++++++++++++++++ - 3 files changed, 20 insertions(+) - -diff --git a/libweston-desktop/internal.h b/libweston-desktop/internal.h -index 7a815bd87..2606d279b 100644 ---- a/libweston-desktop/internal.h -+++ b/libweston-desktop/internal.h -@@ -240,5 +240,7 @@ weston_desktop_wl_shell_create(struct weston_desktop *desktop, - - void - weston_desktop_xwayland_init(struct weston_desktop *desktop); -+void -+weston_desktop_xwayland_fini(struct weston_desktop *desktop); - - #endif /* WESTON_DESKTOP_INTERNAL_H */ -diff --git a/libweston-desktop/libweston-desktop.c b/libweston-desktop/libweston-desktop.c -index c1efd2012..2b42ac7e3 100644 ---- a/libweston-desktop/libweston-desktop.c -+++ b/libweston-desktop/libweston-desktop.c -@@ -95,6 +95,8 @@ weston_desktop_destroy(struct weston_desktop *desktop) - if (desktop == NULL) - return; - -+ weston_desktop_xwayland_fini(desktop); -+ - if (desktop->wl_shell != NULL) - wl_global_destroy(desktop->wl_shell); - if (desktop->xdg_shell_v6 != NULL) -diff --git a/libweston-desktop/xwayland.c b/libweston-desktop/xwayland.c -index 711c8a30c..c1c5fc4a7 100644 ---- a/libweston-desktop/xwayland.c -+++ b/libweston-desktop/xwayland.c -@@ -423,3 +423,19 @@ weston_desktop_xwayland_init(struct weston_desktop *desktop) - compositor->xwayland = xwayland; - compositor->xwayland_interface = &weston_desktop_xwayland_interface; - } -+ -+void -+weston_desktop_xwayland_fini(struct weston_desktop *desktop) -+{ -+ struct weston_compositor *compositor = weston_desktop_get_compositor(desktop); -+ struct weston_desktop_xwayland *xwayland; -+ -+ xwayland = compositor->xwayland; -+ -+ weston_desktop_client_destroy(xwayland->client); -+ weston_layer_fini(&xwayland->layer); -+ free(xwayland); -+ -+ compositor->xwayland = NULL; -+ compositor->xwayland_interface = NULL; -+} --- -GitLab - diff --git a/meta-agl-core/recipes-graphics/wayland/weston_10.0_aglcore.inc b/meta-agl-core/recipes-graphics/wayland/weston_10.0_aglcore.inc deleted file mode 100644 index 90ccbc8fa..000000000 --- a/meta-agl-core/recipes-graphics/wayland/weston_10.0_aglcore.inc +++ /dev/null @@ -1,10 +0,0 @@ -FILESEXTRAPATHS:append := ":${THISDIR}/weston" - -# Workaround for incorrect upstream definition -PACKAGECONFIG[remoting] = "-Dremoting=true,-Dremoting=false,gstreamer1.0 gstreamer1.0-plugins-base" -PACKAGECONFIG[headless] = "-Dbackend-headless=true" -PACKAGECONFIG:append = "${@bb.utils.contains('DISTRO_FEATURES', 'weston-remoting', ' remoting', '', d)}" -PACKAGECONFIG:append = "${@bb.utils.contains('AGL_FEATURES', 'waltham-remoting', ' remoting', '', d)}" - -# seat management is only for waltham-transmitter-plugin -SRC_URI:append = "${@bb.utils.contains('AGL_FEATURES', 'waltham-remoting', 'file://0001-libweston-Migrate-weston_seat_init-release-to-public.patch', '', d)}" diff --git a/meta-agl-core/recipes-graphics/wayland/weston_10.0.%.bbappend b/meta-agl-core/recipes-graphics/wayland/weston_13.0.%.bbappend index 685894116..87cad12a0 100644 --- a/meta-agl-core/recipes-graphics/wayland/weston_10.0.%.bbappend +++ b/meta-agl-core/recipes-graphics/wayland/weston_13.0.%.bbappend @@ -1 +1 @@ -require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'weston_10.0_aglcore.inc', '', d)} +require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'weston_13.0_aglcore.inc', '', d)} diff --git a/meta-agl-core/recipes-graphics/wayland/weston_13.0_aglcore.inc b/meta-agl-core/recipes-graphics/wayland/weston_13.0_aglcore.inc new file mode 100644 index 000000000..843a068b4 --- /dev/null +++ b/meta-agl-core/recipes-graphics/wayland/weston_13.0_aglcore.inc @@ -0,0 +1,29 @@ +FILESEXTRAPATHS:append := ":${THISDIR}/weston" + +PACKAGECONFIG:append = "${@bb.utils.contains('DISTRO_FEATURES', 'weston-remoting', ' remoting', '', d)}" + +SRC_URI:append = " \ + file://0001-clients-Handle-missing-pointer_surface-is-there-s-no.patch \ + file://0001-libweston-Add-paint-node-destruction-into-weston_lay.patch \ +" + + +# Split weston-terminal out of the main package to allow installing it +# separately for use with other compositors. The icons, etc. that end +# up in /usr/share/weston are also split out into a separate package +# since they are required for weston-terminal and some of the programs +# packaged in weston-examples in addition to ivi-shell in the main +# package. + +PACKAGE_BEFORE_PN += "${PN}-data ${PN}-terminal" + +FILES:${PN}-data = "${datadir}/weston" + +FILES:${PN}-terminal = "${bindir}/weston-terminal" +RDEPENDS:${PN}-terminal += "weston-data liberation-fonts" + +RDEPENDS:${PN}-examples += "weston-data" + +FILES:${PN}:remove = "weston-terminal" +RDEPENDS:${PN}:remove = "liberation-fonts" +RDEPENDS:${PN} += "weston-data weston-terminal" diff --git a/meta-agl-core/recipes-kernel/linux/linux-agl-config.inc b/meta-agl-core/recipes-kernel/linux/linux-agl-config.inc index 81cf0189d..4799a6180 100644 --- a/meta-agl-core/recipes-kernel/linux/linux-agl-config.inc +++ b/meta-agl-core/recipes-kernel/linux/linux-agl-config.inc @@ -39,6 +39,11 @@ AGL_KCONFIG_FRAGMENTS += " \ can-bus.cfg \ fanotify.cfg \ overlayfs.cfg \ + audit.cfg \ + ${@bb.utils.contains('DISTRO_FEATURES', 'selinux', 'selinux.cfg', '', d)} \ + ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd-required.cfg', '', d)} \ + ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'systemd-sandbox.cfg', '', d)} \ + lttng.cfg \ " AGL_KCONFIG_FRAGMENTS += " ${@bb.utils.contains('AGL_XEN_GUEST_WANTED','1','xen_domu.cfg','',d)}" @@ -48,7 +53,6 @@ AGL_KCONFIG_FRAGMENTS += "sound.cfg" # Enable support for SystemTap AGL_KCONFIG_FRAGMENTS += "${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'systemtap.cfg', '', d)}" -AGL_KCONFIG_FRAGMENTS:bbe += "disable-relay.cfg" # # Feature override and qemu specific appends: @@ -67,6 +71,10 @@ AGL_KCONFIG_FRAGMENTS:append:qemuall = " \ qemu-drm.cfg \ " +AGL_KCONFIG_FRAGMENTS:append:virtio-all = " \ + sound-hda.cfg \ +" + # Configuration for using the ARM virt machine (and not versatilepb) AGL_KCONFIG_FRAGMENTS:append:qemuarm = " qemuarm.cfg" @@ -74,7 +82,7 @@ AGL_KCONFIG_FRAGMENTS:append:qemuarm = " qemuarm.cfg" # OVERRIDES save us some c'n'p below ... OVERRIDES:prepend:qemux86 = "virtualmachine:" OVERRIDES:prepend:qemux86-64 = "virtualmachine:" -AGL_KCONFIG_FRAGMENTS:append_virtualmachine = " vbox-vmware-sata.cfg" +AGL_KCONFIG_FRAGMENTS:append:virtualmachine = " vbox-vmware-sata.cfg" # Extra configuration for using qemux86-64 image on physical hardware AGL_KCONFIG_FRAGMENTS:append:qemux86-64 = " \ diff --git a/meta-agl-core/recipes-kernel/linux/linux/audit.cfg b/meta-agl-core/recipes-kernel/linux/linux/audit.cfg new file mode 100644 index 000000000..7decc799c --- /dev/null +++ b/meta-agl-core/recipes-kernel/linux/linux/audit.cfg @@ -0,0 +1,2 @@ +CONFIG_AUDIT=y +CONFIG_AUDIT_GENERIC=y diff --git a/meta-agl-core/recipes-kernel/linux/linux/disable-relay.cfg b/meta-agl-core/recipes-kernel/linux/linux/disable-relay.cfg deleted file mode 100644 index 09a117919..000000000 --- a/meta-agl-core/recipes-kernel/linux/linux/disable-relay.cfg +++ /dev/null @@ -1 +0,0 @@ -# CONFIG_RELAY is not set diff --git a/meta-agl-core/recipes-kernel/linux/linux/lttng.cfg b/meta-agl-core/recipes-kernel/linux/linux/lttng.cfg new file mode 100644 index 000000000..e5f6b9c69 --- /dev/null +++ b/meta-agl-core/recipes-kernel/linux/linux/lttng.cfg @@ -0,0 +1 @@ +CONFIG_KALLSYMS_ALL=y diff --git a/meta-agl-core/recipes-kernel/linux/linux/selinux.cfg b/meta-agl-core/recipes-kernel/linux/linux/selinux.cfg new file mode 100644 index 000000000..d49283158 --- /dev/null +++ b/meta-agl-core/recipes-kernel/linux/linux/selinux.cfg @@ -0,0 +1,14 @@ +CONFIG_NETWORK_SECMARK=y +CONFIG_EXT2_FS_SECURITY=y +CONFIG_EXT3_FS_SECURITY=y +CONFIG_EXT4_FS_SECURITY=y +CONFIG_JFS_SECURITY=y +CONFIG_REISERFS_FS_SECURITY=y +CONFIG_JFFS2_FS_SECURITY=y +CONFIG_SECURITY=y +CONFIG_SECURITYFS=y +CONFIG_SECURITY_NETWORK=y +CONFIG_SECURITY_SELINUX=y +CONFIG_SECURITY_SELINUX_BOOTPARAM=y +CONFIG_SECURITY_SELINUX_DEVELOP=y +CONFIG_SECURITY_SELINUX_AVC_STATS=y diff --git a/meta-agl-core/recipes-kernel/linux/linux/systemd-required.cfg b/meta-agl-core/recipes-kernel/linux/linux/systemd-required.cfg new file mode 100644 index 000000000..3424c80b9 --- /dev/null +++ b/meta-agl-core/recipes-kernel/linux/linux/systemd-required.cfg @@ -0,0 +1,42 @@ +CONFIG_TMPFS=y +CONFIG_TMPFS_XATTR=y +CONFIG_TMPFS_POSIX_ACL=y +CONFIG_DEVTMPFS=y +CONFIG_DEVTMPFS_MOUNT=y +CONFIG_AUTOFS_FS=y +CONFIG_EXT4_FS_POSIX_ACL=y +CONFIG_BLK_DEV_BSG=y +CONFIG_BLK_CGROUP=y +CONFIG_CGROUPS=y +CONFIG_CGROUP_CPUACCT=y +CONFIG_CGROUP_DEVICE=y +CONFIG_CGROUP_FREEZER=y +CONFIG_CGROUP_PERF=y +CONFIG_CGROUP_PIDS=y +CONFIG_CGROUP_SCHED=y +CONFIG_RT_GROUP_SCHED=n +CONFIG_SCHED_DEBUG=y +CONFIG_SCHEDSTATS=y +CONFIG_FAIR_GROUP_SCHED=y +CONFIG_INOTIFY_USER=y +CONFIG_SIGNALFD=y +CONFIG_TIMERFD=y +CONFIG_EPOLL=y +CONFIG_NET=y +CONFIG_UNIX=y +CONFIG_PROC_FS=y +CONFIG_SYSFS=y +CONFIG_FHANDLE=y +CONFIG_CRYPTO_USER_API_HASH=y +CONFIG_CRYPTO_HMAC=y +CONFIG_CRYPTO_SHA256=y +CONFIG_UEVENT_HELPER_PATH="" +CONFIG_FW_LOADER_USER_HELPER=n +CONFIG_DMIID=y +CONFIG_NAMESPACES=y +CONFIG_NET_NS=y +CONFIG_USER_NS=y +CONFIG_SECCOMP=y +CONFIG_SECCOMP_FILTER=y +CONFIG_CHECKPOINT_RESTORE=y +CONFIG_CFS_BANDWIDTH=y diff --git a/meta-agl-core/recipes-kernel/linux/linux/systemd-sandbox.cfg b/meta-agl-core/recipes-kernel/linux/linux/systemd-sandbox.cfg new file mode 100644 index 000000000..d451d554c --- /dev/null +++ b/meta-agl-core/recipes-kernel/linux/linux/systemd-sandbox.cfg @@ -0,0 +1,9 @@ +CONFIG_BPF=y +CONFIG_BPF_SYSCALL=y +CONFIG_NET_CLS_BPF=m +CONFIG_NET_ACT_BPF=m +CONFIG_BPF_JIT=y +CONFIG_HAVE_EBPF_JIT=y +CONFIG_BPF_EVENTS=y +CONFIG_BPF_LSM=y +CONFIG_CGROUP_BPF=y diff --git a/meta-agl-core/recipes-kernel/linux/linux/vbox-vmware-sata.cfg b/meta-agl-core/recipes-kernel/linux/linux/vbox-vmware-sata.cfg index ce1eca1a7..a37f07d1f 100644 --- a/meta-agl-core/recipes-kernel/linux/linux/vbox-vmware-sata.cfg +++ b/meta-agl-core/recipes-kernel/linux/linux/vbox-vmware-sata.cfg @@ -12,7 +12,6 @@ CONFIG_BLK_DEV_SD=y CONFIG_FUSION=y CONFIG_FUSION_SPI=y CONFIG_DRM_VMWGFX=y -CONFIG_DRM_VMWGFX_FBCON=y CONFIG_VMWARE_BALLOON=m CONFIG_VMWARE_VMCI=m CONFIG_VMWARE_VMCI_VSOCKETS=m diff --git a/meta-agl-core/recipes-kernel/linux/linux/x86-extra-graphic-devices.cfg b/meta-agl-core/recipes-kernel/linux/linux/x86-extra-graphic-devices.cfg index 678ecac04..9c8e240e9 100644 --- a/meta-agl-core/recipes-kernel/linux/linux/x86-extra-graphic-devices.cfg +++ b/meta-agl-core/recipes-kernel/linux/linux/x86-extra-graphic-devices.cfg @@ -11,8 +11,7 @@ CONFIG_NOUVEAU_DEBUG=5 CONFIG_NOUVEAU_DEBUG_DEFAULT=3 CONFIG_DRM_NOUVEAU_BACKLIGHT=y CONFIG_DRM_VGEM=m -CONFIG_DRM_VMWGFX=m -CONFIG_DRM_VMWGFX_FBCON=y +CONFIG_DRM_VMWGFX=y CONFIG_DRM_GMA500=m CONFIG_DRM_UDL=m CONFIG_FB_DEFERRED_IO=y diff --git a/meta-agl-core/recipes-kernel/linux/linux/x86-usb-devices.cfg b/meta-agl-core/recipes-kernel/linux/linux/x86-usb-devices.cfg index 19c57796e..d74d4afd8 100644 --- a/meta-agl-core/recipes-kernel/linux/linux/x86-usb-devices.cfg +++ b/meta-agl-core/recipes-kernel/linux/linux/x86-usb-devices.cfg @@ -75,7 +75,6 @@ CONFIG_WL18XX=m CONFIG_WLCORE=m CONFIG_WLCORE_SPI=m CONFIG_WLCORE_SDIO=m -CONFIG_WILINK_PLATFORM_DATA=y CONFIG_ZD1211RW=m CONFIG_ZD1211RW_DEBUG=y CONFIG_MWIFIEX=m diff --git a/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/files/0001-Added-appid-and-title-support.patch b/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/files/0001-Added-appid-and-title-support.patch new file mode 100644 index 000000000..685f80c7b --- /dev/null +++ b/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/files/0001-Added-appid-and-title-support.patch @@ -0,0 +1,169 @@ +From b8bbab864a1367ac47bcc0998b4c07d20020965a Mon Sep 17 00:00:00 2001 +From: Marius Vlad <marius.vlad@collabora.com> +Date: Thu, 5 Oct 2023 18:23:52 +0300 +Subject: [PATCH] ext/wayland: Add title/appid support + +Upstream-Status: Pending + +Bug-AGL: SPEC-4870 +Signed-off-by: Marius Vlad <marius.vlad@collabora.com> +--- + ext/wayland/gstwaylandsink.c | 41 +++++++++++++++++++++++++++++- + ext/wayland/gstwaylandsink.h | 2 ++ + gst-libs/gst/wayland/gstwlwindow.c | 12 ++++++++- + gst-libs/gst/wayland/gstwlwindow.h | 3 ++- + 4 files changed, 55 insertions(+), 3 deletions(-) + +diff --git a/ext/wayland/gstwaylandsink.c b/ext/wayland/gstwaylandsink.c +index 2f116bf..69f4a00 100644 +--- a/ext/wayland/gstwaylandsink.c ++++ b/ext/wayland/gstwaylandsink.c +@@ -61,6 +61,8 @@ enum + PROP_DISPLAY, + PROP_FULLSCREEN, + PROP_ROTATE_METHOD, ++ PROP_APP_ID, ++ PROP_TITLE, + PROP_LAST + }; + +@@ -177,6 +179,16 @@ gst_wayland_sink_class_init (GstWaylandSinkClass * klass) + GST_TYPE_VIDEO_ORIENTATION_METHOD, GST_VIDEO_ORIENTATION_IDENTITY, + G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); + ++ g_object_class_install_property (gobject_class, PROP_APP_ID, ++ g_param_spec_string ("appid", "Top-level application id", "Wayland " ++ "appid, as xdg_shell::set_app_id", ++ NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); ++ ++ g_object_class_install_property (gobject_class, PROP_TITLE, ++ g_param_spec_string ("title", "Top-level title", "Wayland " ++ "title, xdg_shell::set_title", ++ NULL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS)); ++ + /** + * waylandsink:render-rectangle: + * +@@ -266,6 +278,16 @@ gst_wayland_sink_get_property (GObject * object, + g_value_set_enum (value, self->current_rotate_method); + GST_OBJECT_UNLOCK (self); + break; ++ case PROP_APP_ID: ++ GST_OBJECT_LOCK (self); ++ g_value_set_string (value, self->app_id); ++ GST_OBJECT_UNLOCK (self); ++ break; ++ case PROP_TITLE: ++ GST_OBJECT_LOCK (self); ++ g_value_set_string (value, self->title); ++ GST_OBJECT_UNLOCK (self); ++ break; + default: + G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); + break; +@@ -289,6 +311,16 @@ gst_wayland_sink_set_property (GObject * object, + gst_wayland_sink_set_fullscreen (self, g_value_get_boolean (value)); + GST_OBJECT_UNLOCK (self); + break; ++ case PROP_APP_ID: ++ GST_OBJECT_LOCK (self); ++ self->app_id = g_value_dup_string (value); ++ GST_OBJECT_UNLOCK (self); ++ break; ++ case PROP_TITLE: ++ GST_OBJECT_LOCK (self); ++ self->title = g_value_dup_string (value); ++ GST_OBJECT_UNLOCK (self); ++ break; + case PROP_ROTATE_METHOD: + gst_wayland_sink_set_rotate_method (self, g_value_get_enum (value), + FALSE); +@@ -310,12 +342,18 @@ gst_wayland_sink_finalize (GObject * object) + gst_buffer_unref (self->last_buffer); + if (self->display) + g_object_unref (self->display); ++ if (self->title) ++ g_object_unref (self->title); ++ if (self->app_id) ++ g_object_unref (self->app_id); + if (self->window) + g_object_unref (self->window); + if (self->pool) + gst_object_unref (self->pool); + + g_free (self->display_name); ++ g_free (self->title); ++ g_free (self->app_id); + + g_mutex_clear (&self->display_lock); + g_mutex_clear (&self->render_lock); +@@ -761,7 +799,8 @@ gst_wayland_sink_show_frame (GstVideoSink * vsink, GstBuffer * buffer) + if (!self->window) { + /* if we were not provided a window, create one ourselves */ + self->window = gst_wl_window_new_toplevel (self->display, +- &self->video_info, self->fullscreen, &self->render_lock); ++ &self->video_info, self->fullscreen, &self->app_id, &self->title, ++ &self->render_lock); + g_signal_connect_object (self->window, "closed", + G_CALLBACK (on_window_closed), self, 0); + gst_wl_window_set_rotate_method (self->window, +diff --git a/ext/wayland/gstwaylandsink.h b/ext/wayland/gstwaylandsink.h +index 3243d8c..6aee19d 100644 +--- a/ext/wayland/gstwaylandsink.h ++++ b/ext/wayland/gstwaylandsink.h +@@ -58,6 +58,8 @@ struct _GstWaylandSink + gboolean fullscreen; + + gchar *display_name; ++ gchar *app_id; ++ gchar *title; + + gboolean redraw_pending; + GMutex render_lock; +diff --git a/gst-libs/gst/wayland/gstwlwindow.c b/gst-libs/gst/wayland/gstwlwindow.c +index 6004993..de0a81e 100644 +--- a/gst-libs/gst/wayland/gstwlwindow.c ++++ b/gst-libs/gst/wayland/gstwlwindow.c +@@ -270,7 +270,7 @@ gst_wl_window_ensure_fullscreen (GstWlWindow * self, gboolean fullscreen) + + GstWlWindow * + gst_wl_window_new_toplevel (GstWlDisplay * display, const GstVideoInfo * info, +- gboolean fullscreen, GMutex * render_lock) ++ gboolean fullscreen, gchar *app_id, gchar *title, GMutex * render_lock) + { + GstWlWindow *self; + GstWlWindowPrivate *priv; +@@ -307,6 +307,16 @@ gst_wl_window_new_toplevel (GstWlDisplay * display, const GstVideoInfo * info, + + gst_wl_window_ensure_fullscreen (self, fullscreen); + ++ if (app_id) ++ xdg_toplevel_set_app_id (priv->xdg_toplevel, app_id); ++ else ++ xdg_toplevel_set_app_id (priv->xdg_toplevel, "ext.wayland.waylandsink"); ++ if (title) ++ xdg_toplevel_set_title (priv->xdg_toplevel, title); ++ else ++ xdg_toplevel_set_title (priv->xdg_toplevel, "ext.wayland.waylandsink"); ++ ++ + /* Finally, commit the xdg_surface state as toplevel */ + priv->configured = FALSE; + wl_surface_commit (priv->area_surface); +diff --git a/gst-libs/gst/wayland/gstwlwindow.h b/gst-libs/gst/wayland/gstwlwindow.h +index 06c4001..e102052 100644 +--- a/gst-libs/gst/wayland/gstwlwindow.h ++++ b/gst-libs/gst/wayland/gstwlwindow.h +@@ -39,7 +39,8 @@ void gst_wl_window_ensure_fullscreen (GstWlWindow * self, + + GST_WL_API + GstWlWindow *gst_wl_window_new_toplevel (GstWlDisplay * display, +- const GstVideoInfo * info, gboolean fullscreen, GMutex * render_lock); ++ const GstVideoInfo * info, gboolean fullscreen, gchar * app_id, ++ gchar *title, GMutex * render_lock); + + GST_WL_API + GstWlWindow *gst_wl_window_new_in_surface (GstWlDisplay * display, +-- +2.35.1 + diff --git a/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/gstreamer1.0-plugins-bad_%.bbappend b/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/gstreamer1.0-plugins-bad_%.bbappend new file mode 100644 index 000000000..96bbdc34b --- /dev/null +++ b/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/gstreamer1.0-plugins-bad_%.bbappend @@ -0,0 +1 @@ +require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'gstreamer1.0-plugins-bad_aglcore.inc', '', d)} diff --git a/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/gstreamer1.0-plugins-bad_aglcore.inc b/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/gstreamer1.0-plugins-bad_aglcore.inc new file mode 100644 index 000000000..97a0c1688 --- /dev/null +++ b/meta-agl-core/recipes-multimedia/gstreamer1.0-plugins-bad/gstreamer1.0-plugins-bad_aglcore.inc @@ -0,0 +1,9 @@ +FILESEXTRAPATHS:prepend := "${THISDIR}/files:" + +AGL_PATCHES = "file://0001-Added-appid-and-title-support.patch" + +# Above patch fails to apply against NXP's forked version, disable +# for now +AGL_PATCHES:use-nxp-bsp = "" + +SRC_URI:append = " ${AGL_PATCHES}" diff --git a/meta-agl-core/recipes-platform/images/agl-image-agl-compositor.bb b/meta-agl-core/recipes-platform/images/agl-image-agl-compositor.bb deleted file mode 100644 index 9ca70e041..000000000 --- a/meta-agl-core/recipes-platform/images/agl-image-agl-compositor.bb +++ /dev/null @@ -1,10 +0,0 @@ -SUMMARY = "A very basic Wayland image with agl-compositor" - -require agl-image-weston.inc - -LICENSE = "MIT" - -IMAGE_INSTALL:append = "\ - agl-compositor \ - packagegroup-agl-profile-graphical \ - " diff --git a/meta-agl-core/recipes-platform/images/agl-image-boot.bb b/meta-agl-core/recipes-platform/images/agl-image-boot.bb index 6e2b89324..dde6a18db 100644 --- a/meta-agl-core/recipes-platform/images/agl-image-boot.bb +++ b/meta-agl-core/recipes-platform/images/agl-image-boot.bb @@ -1,9 +1,5 @@ -SUMMARY = "An AGL small image just capable of allowing a device to boot." - -require agl-image-boot.inc - +SUMMARY = "A small image just capable of allowing a device to boot." LICENSE = "MIT" -IMAGE_INSTALL:append = "\ - packagegroup-agl-image-boot \ - " +inherit agl-core-image + diff --git a/meta-agl-core/recipes-platform/images/agl-image-boot.inc b/meta-agl-core/recipes-platform/images/agl-image-boot.inc deleted file mode 100644 index 60d671bca..000000000 --- a/meta-agl-core/recipes-platform/images/agl-image-boot.inc +++ /dev/null @@ -1,7 +0,0 @@ -IMAGE_LINGUAS = " " - -inherit core-image - -IMAGE_INSTALL = "packagegroup-agl-core-boot ${CORE_IMAGE_EXTRA_INSTALL}" - -IMAGE_ROOTFS_SIZE ?= "8192" diff --git a/meta-agl-core/recipes-platform/images/agl-image-compositor.bb b/meta-agl-core/recipes-platform/images/agl-image-compositor.bb new file mode 100644 index 000000000..b78536be8 --- /dev/null +++ b/meta-agl-core/recipes-platform/images/agl-image-compositor.bb @@ -0,0 +1,15 @@ +SUMMARY = "A very basic Wayland image with agl-compositor" +LICENSE = "MIT" + +require agl-image-minimal.bb + +inherit features_check + +REQUIRED_DISTRO_FEATURES = "wayland" + +SYSTEMD_DEFAULT_TARGET = "graphical.target" + +IMAGE_INSTALL += " \ + packagegroup-agl-graphical-compositor \ + ${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'weston-examples', '', d)} \ +" diff --git a/meta-agl-core/recipes-platform/images/agl-image-core-autobuilder.bb b/meta-agl-core/recipes-platform/images/agl-image-core-autobuilder.bb index 3a887a5c0..eec1cf54c 100644 --- a/meta-agl-core/recipes-platform/images/agl-image-core-autobuilder.bb +++ b/meta-agl-core/recipes-platform/images/agl-image-core-autobuilder.bb @@ -1,16 +1,14 @@ SUMMARY = "A very basic Wayland image with a terminal" +LICENSE = "MIT" -require agl-image-weston.inc +require agl-image-weston.bb -LICENSE = "MIT" +IMAGE_FEATURES += "splash" -IMAGE_INSTALL:append = "\ - packagegroup-agl-profile-graphical \ +IMAGE_INSTALL += " \ busybox \ - psplash \ gdb \ gperf \ - weston \ weston-examples \ curl \ ptest-runner \ diff --git a/meta-agl-core/recipes-platform/images/agl-image-minimal-crosssdk.bb b/meta-agl-core/recipes-platform/images/agl-image-minimal-crosssdk.bb index 8c5aae1bf..6aa308273 100644 --- a/meta-agl-core/recipes-platform/images/agl-image-minimal-crosssdk.bb +++ b/meta-agl-core/recipes-platform/images/agl-image-minimal-crosssdk.bb @@ -1,18 +1,9 @@ -SUMMARY = "Cross SDK of Full AGL Distribution for core profile" - -DESCRIPTION = "SDK image for full AGL Distribution for IVI profile. \ -It includes the full meta-toolchain, plus developement headers and libraries \ -to form a standalone cross SDK." - require agl-image-minimal.bb +SUMMARY = "Cross SDK of minimal AGL Distribution for core profile" +DESCRIPTION = "SDK image for AGL core distribution. \ +It includes the full toolchain, plus developement headers and libraries \ +to form a standalone cross SDK." LICENSE = "MIT" -require agl-image-minimal-crosssdk.inc - -inherit populate_sdk - -# Task do_populate_sdk and do_rootfs can't be exec simultaneously. -# Both exec "createrepo" on the same directory, and so one of them -# can failed (randomly). -addtask do_populate_sdk after do_rootfs +inherit agl-crosssdk diff --git a/meta-agl-core/recipes-platform/images/agl-image-minimal-crosssdk.inc b/meta-agl-core/recipes-platform/images/agl-image-minimal-crosssdk.inc deleted file mode 100644 index bab27eb98..000000000 --- a/meta-agl-core/recipes-platform/images/agl-image-minimal-crosssdk.inc +++ /dev/null @@ -1,2 +0,0 @@ -IMAGE_FEATURES:append = " dev-pkgs" -IMAGE_INSTALL:append = " kernel-dev kernel-devsrc" diff --git a/meta-agl-core/recipes-platform/images/agl-image-minimal.bb b/meta-agl-core/recipes-platform/images/agl-image-minimal.bb index 52cc06aeb..4e54e93ed 100644 --- a/meta-agl-core/recipes-platform/images/agl-image-minimal.bb +++ b/meta-agl-core/recipes-platform/images/agl-image-minimal.bb @@ -1,9 +1,9 @@ SUMMARY = "An AGL small image just capable of allowing a device to boot." +LICENSE = "MIT" -require agl-image-minimal.inc +inherit agl-core-image -LICENSE = "MIT" +IMAGE_INSTALL = "packagegroup-agl-image-minimal ${CORE_IMAGE_EXTRA_INSTALL}" -IMAGE_INSTALL:append = "\ - packagegroup-agl-image-minimal \ - " +IMAGE_ROOTFS_SIZE ?= "8192" +IMAGE_ROOTFS_EXTRA_SPACE:append = "${@bb.utils.contains("DISTRO_FEATURES", "systemd", " + 4096", "", d)}" diff --git a/meta-agl-core/recipes-platform/images/agl-image-minimal.inc b/meta-agl-core/recipes-platform/images/agl-image-minimal.inc deleted file mode 100644 index 50b6336de..000000000 --- a/meta-agl-core/recipes-platform/images/agl-image-minimal.inc +++ /dev/null @@ -1 +0,0 @@ -require agl-image-boot.inc diff --git a/meta-agl-core/recipes-platform/images/agl-image-weston.bb b/meta-agl-core/recipes-platform/images/agl-image-weston.bb index 7e9f8814e..d902020cc 100644 --- a/meta-agl-core/recipes-platform/images/agl-image-weston.bb +++ b/meta-agl-core/recipes-platform/images/agl-image-weston.bb @@ -1,9 +1,15 @@ SUMMARY = "A very basic Wayland image with a terminal" +LICENSE = "MIT" -require agl-image-weston.inc +require agl-image-minimal.bb -LICENSE = "MIT" +inherit features_check + +REQUIRED_DISTRO_FEATURES = "wayland" + +SYSTEMD_DEFAULT_TARGET = "graphical.target" -IMAGE_INSTALL:append = "\ - packagegroup-agl-profile-graphical \ - " +IMAGE_INSTALL += " \ + packagegroup-agl-graphical-weston \ + ${@bb.utils.contains('DISTRO_FEATURES', 'agl-devel', 'weston-examples', '', d)} \ +" diff --git a/meta-agl-core/recipes-platform/images/agl-image-weston.inc b/meta-agl-core/recipes-platform/images/agl-image-weston.inc deleted file mode 100644 index 00e36bc4e..000000000 --- a/meta-agl-core/recipes-platform/images/agl-image-weston.inc +++ /dev/null @@ -1,9 +0,0 @@ -require recipes-platform/images/agl-image-minimal.inc - -# NOTE: In hardknott or later this can be replaced by adding "weston" -# to IMAGE_FEATURES. -SYSTEMD_DEFAULT_TARGET = "graphical.target" - -inherit features_check - -REQUIRED_DISTRO_FEATURES = "wayland" diff --git a/meta-agl-core/recipes-platform/images/core-image-weston.bbappend b/meta-agl-core/recipes-platform/images/core-image-weston.bbappend deleted file mode 100644 index 082637b7e..000000000 --- a/meta-agl-core/recipes-platform/images/core-image-weston.bbappend +++ /dev/null @@ -1 +0,0 @@ -require ${@bb.utils.contains('AGL_FEATURES', 'aglcore', 'core-image-weston_aglcore.inc', '', d)} diff --git a/meta-agl-core/recipes-platform/images/core-image-weston_aglcore.inc b/meta-agl-core/recipes-platform/images/core-image-weston_aglcore.inc deleted file mode 100644 index 82e348587..000000000 --- a/meta-agl-core/recipes-platform/images/core-image-weston_aglcore.inc +++ /dev/null @@ -1,3 +0,0 @@ -# NOTE: In hardknott or later this can be replaced by adding "weston" -# to IMAGE_FEATURES. -SYSTEMD_DEFAULT_TARGET = "graphical.target" diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-boot.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-boot.bb index fe1ee7b8c..28a734548 100644 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-boot.bb +++ b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-boot.bb @@ -16,6 +16,7 @@ VIRTUAL-RUNTIME_rngd ?= "rng-tools" RDEPENDS:${PN} = "\ packagegroup-core-boot \ + packagegroup-machine-base \ ${VIRTUAL-RUNTIME_rngd} \ " diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-connectivity.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-connectivity.bb index 5dd274026..aeee0f8d3 100644 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-connectivity.bb +++ b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-connectivity.bb @@ -12,7 +12,8 @@ ALLOW_EMPTY:${PN} = "1" PKGGROUP_ZEROCONF = "${@bb.utils.contains('DISTRO_FEATURES', 'zeroconf', 'packagegroup-base-zeroconf', '', d)}" RDEPENDS:${PN} += "\ - ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','connman','connman connman-client connman-tests \ - connman-tools connman-ncurses' ,'',d)} \ + ${@bb.utils.contains('VIRTUAL-RUNTIME_net_manager','connman','connman connman-client connman-conf \ + connman-wait-online connman-tests connman-tools connman-ncurses' ,'',d)} \ ${@bb.utils.contains('AGL_FEATURES', 'agl-devel', '${PKGGROUP_ZEROCONF}', '', d)} \ + systemd-conf-canbus \ " diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-devel.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-devel.bb index f3e2a9eff..887604ec3 100644 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-devel.bb +++ b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-devel.bb @@ -10,20 +10,14 @@ RDEPENDS:${PN} = "\ vim \ lsof \ gdb \ - valgrind \ screen \ usbutils \ rsync \ pstree \ procps \ libxslt-bin \ - gcc-sanitizers \ pciutils \ - " + openssh-sftp-server \ + zstd \ +" -# needs meta-oe present -#RRECOMMENDS:${PN} = "\ -# jq \ -# htop \ -# tree \ -#" diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-os-commonlibs.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-os-commonlibs.bb deleted file mode 100644 index 0ee63e82a..000000000 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-os-commonlibs.bb +++ /dev/null @@ -1,14 +0,0 @@ -SUMMARY = "The packages of middlewares for AGL IVI profile" -DESCRIPTION = "The set of packages required by Operating System and Common libraries Subsystem" -LICENSE = "MIT" - -inherit packagegroup - -PACKAGES = "\ - packagegroup-agl-core-os-commonlibs \ - " - -ALLOW_EMPTY:${PN} = "1" - -RDEPENDS:${PN} += "\ - " diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-security.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-security.bb deleted file mode 100644 index 7532f4cd7..000000000 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-core-security.bb +++ /dev/null @@ -1,14 +0,0 @@ -SUMMARY = "The packages of middlewares for AGL IVI profile" -DESCRIPTION = "The set of packages required by Operating System and Common libraries Subsystem" -LICENSE = "MIT" - -inherit packagegroup - -PACKAGES = "\ - packagegroup-agl-core-security \ - " - -ALLOW_EMPTY:${PN} = "1" - -RDEPENDS:${PN} += "\ - " diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-compositor.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-compositor.bb new file mode 100644 index 000000000..b2c7d8ec8 --- /dev/null +++ b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-compositor.bb @@ -0,0 +1,9 @@ +DESCRIPTION = "The minimal set of packages required for the AGL compositor" +LICENSE = "MIT" + +inherit packagegroup + +RDEPENDS:${PN} += " \ + agl-compositor \ + agl-compositor-init \ +" diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-multimedia.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-multimedia.bb deleted file mode 100644 index f9903d942..000000000 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-multimedia.bb +++ /dev/null @@ -1,16 +0,0 @@ -SUMMARY = "The software for application framework of AGL IVI profile" -DESCRIPTION = "A set of packages belong to AGL application framework which required by \ -Multimedia Subsystem" - -LICENSE = "MIT" - -inherit packagegroup - -PACKAGES = "\ - packagegroup-agl-graphical-multimedia \ - " - -RDEPENDS:${PN} += "\ - alsa-utils \ - gstreamer1.0-meta-base \ - " diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-weston.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-weston.bb index 859303049..96f09d5ab 100644 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-weston.bb +++ b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-graphical-weston.bb @@ -1,17 +1,9 @@ -DESCRIPTION = "The minimal set of packages required for Wayland support" +DESCRIPTION = "The minimal set of packages required for the Weston compositor" LICENSE = "MIT" inherit packagegroup -PACKAGES = "\ - packagegroup-agl-graphical-weston \ - " - -ALLOW_EMPTY:${PN} = "1" - RDEPENDS:${PN} += " \ - weston \ - weston-init \ - weston-examples \ - " - + weston \ + weston-init \ +" diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-image-boot.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-image-boot.bb deleted file mode 100644 index 8b2cfbb31..000000000 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-image-boot.bb +++ /dev/null @@ -1,18 +0,0 @@ -DESCRIPTION = "The minimal set of packages required by AGL" -LICENSE = "MIT" - -inherit packagegroup - -PACKAGES = "\ - packagegroup-agl-image-boot \ - " - -ALLOW_EMPTY:${PN} = "1" - -RDEPENDS:${PN} += "\ - packagegroup-agl-core-boot \ - packagegroup-machine-base \ - " - -RDEPENDS:${PN} += "\ - " diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-image-minimal.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-image-minimal.bb index 1a51a9bf1..a60cbab21 100644 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-image-minimal.bb +++ b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-image-minimal.bb @@ -12,13 +12,7 @@ ALLOW_EMPTY:${PN} = "1" RDEPENDS:${PN} += "\ packagegroup-agl-core-boot \ - packagegroup-machine-base \ - " - -RDEPENDS:${PN} += "\ packagegroup-agl-core-connectivity \ - packagegroup-agl-core-os-commonlibs \ - packagegroup-agl-core-security \ " RDEPENDS:profile-agl-minimal = "${PN}" diff --git a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-profile-graphical.bb b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-profile-graphical.bb index 2b708603b..b92e760ae 100644 --- a/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-profile-graphical.bb +++ b/meta-agl-core/recipes-platform/packagegroups/packagegroup-agl-profile-graphical.bb @@ -1,5 +1,5 @@ SUMMARY = "The middleware for AGL IVI profile" -DESCRIPTION = "The set of packages required for AGL IVI Distribution" +DESCRIPTION = "The base set of packages required for a AGL IVI Distribution" LICENSE = "MIT" inherit packagegroup @@ -7,16 +7,11 @@ inherit packagegroup PACKAGES = "\ packagegroup-agl-profile-graphical \ profile-graphical \ - " - -ALLOW_EMPTY:${PN} = "1" +" RDEPENDS:${PN} += "\ packagegroup-agl-image-minimal \ - packagegroup-agl-graphical-weston \ - packagegroup-agl-graphical-multimedia \ + packagegroup-agl-graphical-compositor \ " -# FIXME: Removed due to issues building against weston 5.0.0: -# waltham-transmitter RDEPENDS:profile-graphical = "${PN}" diff --git a/meta-agl-core/recipes-support/ptest-runner/ptest-runner/0007-WIP-Initial-LAVA-support.patch b/meta-agl-core/recipes-support/ptest-runner/ptest-runner/0007-WIP-Initial-LAVA-support.patch index 3b7672df9..11c6fd27b 100644 --- a/meta-agl-core/recipes-support/ptest-runner/ptest-runner/0007-WIP-Initial-LAVA-support.patch +++ b/meta-agl-core/recipes-support/ptest-runner/ptest-runner/0007-WIP-Initial-LAVA-support.patch @@ -1,4 +1,4 @@ -From 552f06e025493f7e634ea9e27489861b88f45555 Mon Sep 17 00:00:00 2001 +From bdcbb0e78bbffe45719d0a27954544120f37442a Mon Sep 17 00:00:00 2001 From: Tim Orling <timothy.t.orling@linux.intel.com> Date: Mon, 15 Oct 2018 18:30:42 -0700 Subject: [PATCH] Initial LAVA support @@ -17,18 +17,19 @@ emitted to stdout: It is valid to have a measurement without units, but not units without a measurement. +Upstream-Status: Pending + Signed-off-by: Tim Orling <timothy.t.orling@linux.intel.com> [updated for ptest-runner 2.3.2] [updated for ptest-runner 2.4.1] [updated for ptest-runner 2.4.2] Signed-off-by: Scott Murray <scott.murray@konsulko.com> - --- flags.h | 10 ++++++++++ main.c | 9 ++++++++- - utils.c | 15 +++++++++++++++ + utils.c | 17 ++++++++++++++++- utils.h | 2 +- - 4 files changed, 34 insertions(+), 2 deletions(-) + 4 files changed, 35 insertions(+), 3 deletions(-) create mode 100644 flags.h diff --git a/flags.h b/flags.h @@ -83,7 +84,7 @@ index 31e4dd5..f12d6d6 100644 print_usage(stdout, argv[0]); exit(1); diff --git a/utils.c b/utils.c -index a67ac11..0c081ce 100644 +index 59b8b77..30423c4 100644 --- a/utils.c +++ b/utils.c @@ -49,6 +49,7 @@ @@ -94,28 +95,30 @@ index a67ac11..0c081ce 100644 #define GET_STIME_BUF_SIZE 1024 #define WAIT_CHILD_BUF_MAX_SIZE 1024 -@@ -483,6 +484,7 @@ run_ptests(struct ptest_list *head, const struct ptest_options opts, - fprintf(fp, "START: %s\n", progname); - PTEST_LIST_ITERATE_START(head, p) +@@ -425,6 +426,7 @@ run_ptests(struct ptest_list *head, const struct ptest_options opts, + } + char *ptest_dir = strdup(p->run_ptest); + char *ptest = strdup(p->ptest); if (ptest_dir == NULL) { rc = -1; break; -@@ -525,6 +527,9 @@ run_ptests(struct ptest_list *head, const struct ptest_options opts, +@@ -477,7 +479,10 @@ run_ptests(struct ptest_list *head, const struct ptest_options opts, fprintf(fp, "ERROR: setpgid() failed, %s\n", strerror(errno)); } +- time_t start_time= time(NULL); + if (opts.flags & LAVA_SIGNAL_ENABLE) { + fprintf(stdout, "<LAVA_SIGNAL_STARTTC %s>\n", ptest); + } - sttime = time(NULL); - fprintf(fp, "%s\n", get_stime(stime, GET_STIME_BUF_SIZE, sttime)); ++ time_t start_time = time(NULL); + fprintf(fp, "%s\n", get_stime(stime, GET_STIME_BUF_SIZE, start_time)); fprintf(fp, "BEGIN: %s\n", ptest_dir); -@@ -548,6 +553,16 @@ run_ptests(struct ptest_list *head, const struct ptest_options opts, + +@@ -594,6 +599,16 @@ run_ptests(struct ptest_list *head, const struct ptest_options opts, fprintf(fp, "END: %s\n", ptest_dir); - fprintf(fp, "%s\n", get_stime(stime, GET_STIME_BUF_SIZE, entime)); + fprintf(fp, "%s\n", get_stime(stime, GET_STIME_BUF_SIZE, end_time)); + if (opts.flags & LAVA_SIGNAL_ENABLE) { + char result[5]; // pass\0, fail\0, skip\0 + @@ -128,7 +131,7 @@ index a67ac11..0c081ce 100644 + } } free(ptest_dir); - PTEST_LIST_ITERATE_END + do_close(&pipefd_stdout[PIPE_READ]); diff --git a/utils.h b/utils.h index 04fc666..ad702d8 100644 --- a/utils.h @@ -144,3 +147,6 @@ index 04fc666..ad702d8 100644 extern void check_allocation1(void *, size_t, char *, int, int); extern struct ptest_list *get_available_ptests(const char *); extern int print_ptests(struct ptest_list *, FILE *); +-- +2.37.3 + diff --git a/meta-agl-core/scripts/run-yocto-check-layer-feature-enabled.sh b/meta-agl-core/scripts/run-yocto-check-layer-feature-enabled.sh deleted file mode 100755 index e0e9d17a4..000000000 --- a/meta-agl-core/scripts/run-yocto-check-layer-feature-enabled.sh +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/bash -set -x - -SCRIPTPATH="$( cd $(dirname $0) >/dev/null 2>&1 ; pwd -P )" -echo $SCRIPTPATH -AGLROOT="$SCRIPTPATH/../../.." -POKYDIR="$AGLROOT/external/poky" -TMPROOT=`mktemp -d` - -rm -rf ${TMPROOT}/testbuild-ycl || true -mkdir -p ${TMPROOT}/testbuild-ycl -cd ${TMPROOT}/testbuild-ycl - -source $POKYDIR/oe-init-build-env . - -cat << EOF >> conf/local.conf -# just define defaults -AGL_FEATURES ?= "" -AGL_EXTRA_IMAGE_FSTYPES ?= "" - -# important settings imported from poky-agl.conf -# we do not import -DISTRO_FEATURES:append = " systemd" -DISTRO_FEATURES_BACKFILL_CONSIDERED:append = " sysvinit" -VIRTUAL-RUNTIME_init_manager = "systemd" - -AGL_FEATURES += "aglcore" - -EOF - - -yocto-check-layer \ - --dependency \ - $AGLROOT/external/meta-openembedded/meta-oe \ - -- \ - $AGLROOT/meta-agl/meta-agl-core - - -[ $? = 0 ] && rm -rf ${TMPROOT}/testbuild-ycl - -exit 0 - - --dependency \ - $AGLROOT/external/meta-openembedded/meta-oe \ - $AGLROOT/external/meta-openembedded/meta-python \ - $AGLROOT/external/meta-openembedded/meta-networking \ diff --git a/meta-agl-core/scripts/run-yocto-check-layer.sh b/meta-agl-core/scripts/run-yocto-check-layer.sh index 3af61bc19..cd9364682 100755 --- a/meta-agl-core/scripts/run-yocto-check-layer.sh +++ b/meta-agl-core/scripts/run-yocto-check-layer.sh @@ -1,5 +1,5 @@ #!/bin/bash -set -x +#set -x SCRIPTPATH="$( cd $(dirname $0) >/dev/null 2>&1 ; pwd -P )" echo $SCRIPTPATH @@ -19,17 +19,18 @@ AGL_FEATURES ?= "" AGL_EXTRA_IMAGE_FSTYPES ?= "" # important settings imported from poky-agl.conf -# we do not import -DISTRO_FEATURES:append = " systemd" +# we cannot import the distro config right away +# as the initial values are poky only till the layer +# is added in +# no polkit ! +AGL_DEFAULT_DISTRO_FEATURES = "usrmerge largefile opengl wayland pam bluetooth bluez5 3g" +DISTRO_FEATURES:append = " systemd wayland pam \${AGL_DEFAULT_DISTRO_FEATURES}" DISTRO_FEATURES_BACKFILL_CONSIDERED:append = " sysvinit" VIRTUAL-RUNTIME_init_manager = "systemd" EOF - -yocto-check-layer \ - --dependency \ - $AGLROOT/external/meta-openembedded/meta-oe \ +yocto-check-layer --no-auto-dependency \ -- \ $AGLROOT/meta-agl/meta-agl-core @@ -37,8 +38,3 @@ yocto-check-layer \ [ $? = 0 ] && rm -rf ${TMPROOT}/testbuild-ycl exit 0 - - --dependency \ - $AGLROOT/external/meta-openembedded/meta-oe \ - $AGLROOT/external/meta-openembedded/meta-python \ - $AGLROOT/external/meta-openembedded/meta-networking \ |