aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.gitignore2
-rw-r--r--README.md14
-rw-r--r--conf/bblayers.conf.sample7
-rw-r--r--conf/conf-notes.txt11
-rw-r--r--conf/local.conf.sample323
-rw-r--r--meta-mel-support/README.md29
-rw-r--r--meta-mel-support/conf/layer.conf22
-rw-r--r--meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/110-arm-eabi-conf.patch24
-rw-r--r--meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch31
-rw-r--r--meta-mel-support/gplv2/recipes-devtools/binutils/binutils_2.17.50.0.12.bb70
-rwxr-xr-xmeta-mel-support/recipes-bsp/96boards-tools/96boards-tools/resize-helper.sh.in31
-rw-r--r--meta-mel-support/recipes-bsp/96boards-tools/96boards-tools_0.12.bb44
-rw-r--r--meta-mel-support/recipes-core/images/core-image-minimal-install-initramfs.bb6
-rw-r--r--meta-mel-support/recipes-core/images/development-image.bb13
-rw-r--r--meta-mel-support/recipes-core/images/mel-image.inc18
-rw-r--r--meta-mel-support/recipes-core/images/production-image.bb18
-rw-r--r--meta-mel-support/recipes-core/meta/archive-release.bb472
-rwxr-xr-xmeta-mel-support/recipes-core/meta/archive-release/runqemu.in24
-rw-r--r--meta-mel-support/recipes-core/packagegroups/packagegroup-tools-audio.bb13
-rw-r--r--meta-mel-support/recipes-core/packagegroups/packagegroup-tools-benchmark.bb21
-rw-r--r--meta-mel-support/recipes-kernel/linux/linux-yocto-rt_3.10.bb31
-rw-r--r--meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.10.bb26
-rw-r--r--meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.17.bb25
-rw-r--r--meta-mel-support/recipes-kernel/linux/linux-yocto_3.10.bb41
-rw-r--r--meta-mel-support/recipes-kernel/linux/linux-yocto_3.17.bb43
-rw-r--r--meta-mel-support/recipes-support/tofrodos/tofrodos-native/Make-OE-friendly.patch32
-rw-r--r--meta-mel-support/recipes-support/tofrodos/tofrodos-native_1.7.12a.bb25
-rw-r--r--meta-mel/README.md33
-rw-r--r--meta-mel/classes/codename_is_corename.bbclass13
-rw-r--r--meta-mel/conf/distro/include/gdbserver-gplv3.inc17
-rw-r--r--meta-mel/conf/distro/include/mel-arm-tuning.inc28
-rw-r--r--meta-mel/conf/distro/include/sourcery-version-check.inc29
-rw-r--r--meta-mel/conf/distro/include/wic-bmap.inc12
-rw-r--r--meta-mel/conf/distro/mel-lite.conf15
-rw-r--r--meta-mel/conf/distro/mel.conf397
-rw-r--r--meta-mel/conf/include/drop-toolchain-from-sdk.inc17
-rw-r--r--meta-mel/conf/layer.conf23
-rw-r--r--meta-mel/files/kgdb.cfg4
-rw-r--r--meta-mel/lib/bblayers/mel_utils.py315
-rw-r--r--meta-mel/lib/oeqa/selftest/cases/recipetool_mel.py108
-rw-r--r--meta-mel/lib/recipetool/kernel.py227
-rw-r--r--meta-mel/mel-support/recipes-core/meta/archive-release.bbappend463
-rw-r--r--meta-mel/meta-python/recipes-devtools/python/python3-unidiff_%.bbappend5
-rw-r--r--meta-mel/openembedded-layer/recipes-connectivity/libwebsockets/libwebsockets_4.2.2.bbappend2
-rw-r--r--meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init.bb30
-rw-r--r--meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init/init.sh196
-rw-r--r--meta-mel/openembedded-layer/recipes-support/lvm2/lvm2/lvm2-mel.service15
-rw-r--r--meta-mel/openembedded-layer/recipes-support/lvm2/lvm2_%.bbappend19
-rw-r--r--meta-mel/recipes-connectivity/connman/connman_%.bbappend9
-rw-r--r--meta-mel/recipes-core/base-files/base-files_3.0.14.bbappend10
-rw-r--r--meta-mel/recipes-core/base-files/mel/issue2
-rw-r--r--meta-mel/recipes-core/base-files/mel/issue.net2
-rw-r--r--meta-mel/recipes-core/busybox/busybox/beagleboard/hwclock-default2
-rw-r--r--meta-mel/recipes-core/busybox/busybox/fancy-head.cfg1
-rw-r--r--meta-mel/recipes-core/busybox/busybox/pidof.cfg2
-rw-r--r--meta-mel/recipes-core/busybox/busybox/setsid.cfg1
-rw-r--r--meta-mel/recipes-core/busybox/busybox/top.cfg5
-rw-r--r--meta-mel/recipes-core/busybox/busybox_%.bbappend14
-rw-r--r--meta-mel/recipes-core/images/console-image.bb20
-rw-r--r--meta-mel/recipes-core/images/mel-initramfs-image.bb37
-rw-r--r--meta-mel/recipes-core/initrdscripts/files/init-boot.sh21
-rw-r--r--meta-mel/recipes-core/initrdscripts/initramfs-boot_1.0.bbappend5
-rw-r--r--meta-mel/recipes-core/initrdscripts/initramfs-framework/lvm18
-rw-r--r--meta-mel/recipes-core/initrdscripts/initramfs-framework_%.bbappend8
-rw-r--r--meta-mel/recipes-core/kbd/kbd_2.5.0.bbappend13
-rw-r--r--meta-mel/recipes-core/meta/meta-environment.bbappend11
-rw-r--r--meta-mel/recipes-core/meta/sdk-env-kernelvars.bb21
-rw-r--r--meta-mel/recipes-core/os-release/os-release.bbappend12
-rw-r--r--meta-mel/recipes-core/packagegroups/packagegroup-base.bbappend7
-rw-r--r--meta-mel/recipes-core/packagegroups/packagegroup-core-boot.bbappend6
-rw-r--r--meta-mel/recipes-core/packagegroups/packagegroup-core-tools-profile.bbappend6
-rw-r--r--meta-mel/recipes-core/psplash/mel/0001-plash-colors.h-color-change.patch26
-rw-r--r--meta-mel/recipes-core/psplash/mel/0001-psplash-config-enable-fullscreen-image.patch24
-rw-r--r--meta-mel/recipes-core/psplash/mel/mel.pngbin169324 -> 0 bytes
-rw-r--r--meta-mel/recipes-core/psplash/mel/psplash-final.service12
-rwxr-xr-xmeta-mel/recipes-core/psplash/mel/psplash-quit.service12
-rwxr-xr-xmeta-mel/recipes-core/psplash/mel/psplash-start.service12
-rw-r--r--meta-mel/recipes-core/psplash/psplash_git.bbappend39
-rw-r--r--meta-mel/recipes-core/systemd/systemd/monotonic-timestamp.patch160
-rw-r--r--meta-mel/recipes-core/systemd/systemd_%.bbappend16
-rw-r--r--meta-mel/recipes-core/util-linux/util-linux_%.bbappend5
-rw-r--r--meta-mel/recipes-devtools/e2fsprogs/e2fsprogs_%.bbappend8
-rw-r--r--meta-mel/recipes-devtools/llvm/llvm_%.bbappend6
-rw-r--r--meta-mel/recipes-devtools/python/python3_%.bbappend54
-rw-r--r--meta-mel/recipes-graphics/images/weston-image.bb22
-rw-r--r--meta-mel/recipes-graphics/libsdl2/libsdl2_%.bbappend5
-rw-r--r--meta-mel/recipes-kernel/perf/perf.bbappend7
-rw-r--r--meta-mel/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend16
-rw-r--r--meta-mel/recipes-sato/images/core-image-sato.bbappend6
-rw-r--r--meta-mel/recipes-support/boost/boost_%.bbappend5
-rw-r--r--meta-mel/recipes-support/consolekit/consolekit/0001-Ensure-filesystems-are-still-mounted-when-consolekit.patch25
-rw-r--r--meta-mel/recipes-support/consolekit/consolekit_%.bbappend9
-rw-r--r--meta-mel/recipes-support/curl/curl_%.bbappend8
-rw-r--r--meta-mel/recipes-support/db/db_%.bbappend8
-rw-r--r--meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-2g.wks10
-rw-r--r--meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-4g.wks10
-rw-r--r--meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-8g.wks10
-rw-r--r--meta-mentor-common/COPYING.MIT17
-rw-r--r--meta-mentor-common/README41
-rw-r--r--meta-mentor-common/classes/archive-release-downloads.bbclass118
-rw-r--r--meta-mentor-common/classes/archive_sdk_downloads.bbclass12
-rw-r--r--meta-mentor-common/classes/cml1-config.bbclass102
-rw-r--r--meta-mentor-common/classes/copyleft_compliance_all.bbclass10
-rw-r--r--meta-mentor-common/classes/deploy-license-manifest.bbclass20
-rw-r--r--meta-mentor-common/classes/feature_overrides.bbclass32
-rw-r--r--meta-mentor-common/classes/image-root-password.bbclass45
-rw-r--r--meta-mentor-common/classes/image-sdk-multilib-variants.bbclass18
-rw-r--r--meta-mentor-common/classes/incompatible-packages-check.bbclass27
-rw-r--r--meta-mentor-common/classes/isolated-sstate-dir.bbclass75
-rw-r--r--meta-mentor-common/classes/layerdirs.bbclass21
-rw-r--r--meta-mentor-common/classes/mentor-updates-check.bbclass36
-rw-r--r--meta-mentor-common/classes/mirrors.bbclass25
-rw-r--r--meta-mentor-common/classes/required_toolchain_config.bbclass27
-rw-r--r--meta-mentor-common/classes/resize-rootfs-gplv3.bbclass29
-rw-r--r--meta-mentor-common/classes/sdk_latest_link.bbclass18
-rw-r--r--meta-mentor-common/classes/user_features.bbclass15
-rw-r--r--meta-mentor-common/conf/layer.conf13
-rw-r--r--meta-mentor-staging/README.md28
-rw-r--r--meta-mentor-staging/classes/cve-check-all.bbclass17
-rw-r--r--meta-mentor-staging/classes/distutils-base.bbclass8
-rw-r--r--meta-mentor-staging/classes/distutils.bbclass91
-rw-r--r--meta-mentor-staging/classes/python-dir.bbclass9
-rw-r--r--meta-mentor-staging/classes/pythonnative.bbclass30
-rw-r--r--meta-mentor-staging/classes/setuptools.bbclass7
-rw-r--r--meta-mentor-staging/classes/toolchain_ship_relocate_sdk.bbclass12
-rw-r--r--meta-mentor-staging/classes/win_sdk_cull.bbclass26
-rw-r--r--meta-mentor-staging/classes/xsctyaml.bbclass90
-rw-r--r--meta-mentor-staging/conf/layer.conf29
-rw-r--r--meta-mentor-staging/efibootguard/recipes-bsp/efibootguard/efibootguard_%.bbappend7
-rw-r--r--meta-mentor-staging/files/relocate_sdk.sh85
-rw-r--r--meta-mentor-staging/files/toolchain-shar-extract.sh265
-rw-r--r--meta-mentor-staging/files/toolchain-shar-relocate.sh5
-rw-r--r--meta-mentor-staging/fsl-bsp-release/recipes-bsp/imx-vpu/imx-vpu_%.bbappend15
-rw-r--r--meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync/rsyncd.conf19
-rw-r--r--meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync_2.6.9+git.bb28
-rw-r--r--meta-mentor-staging/lib/oe/__init__.py6
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch89
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0002-8184309-PR3596-Build-warnings-from-GCC-7.1-on-Fedora.patch55
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native_%.bbappend10
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/jamvm/jamvm_%.bbappend8
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-flags-to-compile-with-GCC-6.patch74
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-specify-overloaded-variant-of-fmod.patch28
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-7_%.bbappend26
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8-native_%.bbappend8
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch71
-rw-r--r--meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8_%.bbappend8
-rw-r--r--meta-mentor-staging/meta-python/recipes-devtools/python/python3-pyudev_%.bbappend7
-rw-r--r--meta-mentor-staging/openembedded-layer/recipes-extended/collectd/collectd_%.bbappend6
-rwxr-xr-xmeta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/local-tcp-test26
-rwxr-xr-xmeta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/run-ptest13
-rw-r--r--meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus_%.bbappend17
-rw-r--r--meta-mentor-staging/perl-layer/recipes-perl/libnet/libnet-ssleay-perl_1.85.bbappend7
-rw-r--r--meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase/Fix-note-alignment.patch32
-rw-r--r--meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase_%.bbappend6
-rw-r--r--meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtwebkit_%.bbappend5
-rw-r--r--meta-mentor-staging/recipes-connectivity/connman/connman_%.bbappend6
-rw-r--r--meta-mentor-staging/recipes-connectivity/connman/files/0001-connman-implement-network-interface-management-techn.patch31
-rw-r--r--meta-mentor-staging/recipes-core/glibc/glibc-locale_%.bbappend20
-rw-r--r--meta-mentor-staging/recipes-core/initrdscripts/files/0001-initramfs-framework-finish-move-mounts-to-rootfs-bef.patch51
-rw-r--r--meta-mentor-staging/recipes-core/initrdscripts/files/0001-initrdscripts-init-live.sh-Fixed-mounts-fail-to-move.patch65
-rw-r--r--meta-mentor-staging/recipes-core/initrdscripts/initramfs-framework_1.0.bbappend6
-rw-r--r--meta-mentor-staging/recipes-core/initrdscripts/initramfs-live-boot_1.0.bbappend7
-rw-r--r--meta-mentor-staging/recipes-core/meta/buildtools-tarball.bbappend10
-rw-r--r--meta-mentor-staging/recipes-core/meta/meta-environment.bbappend23
-rw-r--r--meta-mentor-staging/recipes-core/systemd/systemd-boot/0001-Use-an-array-for-efi-ld-to-allow-for-ld-arguments.patch48
-rw-r--r--meta-mentor-staging/recipes-core/systemd/systemd-boot_%.bbappend10
-rw-r--r--meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-add-LABELs-to-mountpoints.patch46
-rw-r--r--meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-ignore-lvm-in-automount.patch35
-rw-r--r--meta-mentor-staging/recipes-core/udev/udev-extraconf/0002-udev-extraconf-mount.sh-save-mount-name-in-our-tmp-f.patch32
-rw-r--r--meta-mentor-staging/recipes-core/udev/udev-extraconf/0003-udev-extraconf-mount.sh-only-mount-devices-on-hotplu.patch86
-rw-r--r--meta-mentor-staging/recipes-core/udev/udev-extraconf/systemd-udevd.service3
-rw-r--r--meta-mentor-staging/recipes-core/udev/udev-extraconf_%.bbappend22
-rw-r--r--meta-mentor-staging/recipes-graphics/libsdl2/libsdl2_2.%.bbappend5
-rw-r--r--meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/fix_dshare_status.patch21
-rw-r--r--meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/plug_fix_rate_converter_config.patch23
-rw-r--r--meta-mentor-staging/recipes-multimedia/alsa/alsa-lib_1.2.%.bbappend10
-rw-r--r--meta-mentor-staging/recipes-multimedia/alsa/alsa-utils/0001-alsa-utils-interrupt-streaming-via-signal.patch50
-rw-r--r--meta-mentor-staging/recipes-multimedia/alsa/alsa-utils_1.2%.bbappend8
-rw-r--r--meta-mentor-staging/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend9
-rw-r--r--meta-mentor-staging/recipes-support/curl/curl_%.bbappend7
-rw-r--r--meta-mentor-staging/security/recipes-ids/tripwire/tripwire_%.bbappend24
-rw-r--r--meta-mentor-staging/security/recipes-security/nikto/nikto_%.bbappend5
-rw-r--r--meta-mentor-staging/security/recipes-security/scapy/python3-scapy_%.bbappend7
-rw-r--r--meta-mentor-staging/selinux/recipes-security/selinux/libselinux-python_3.0.bbappend5
-rwxr-xr-xscripts/bb-determine-layers550
-rwxr-xr-xscripts/bb-print-layer-data129
-rw-r--r--scripts/build-setup-environment.in23
-rwxr-xr-xscripts/capdebuginfo292
-rwxr-xr-xscripts/list-recipes21
-rwxr-xr-xscripts/multi-machine111
-rwxr-xr-xscripts/patchinfo146
-rwxr-xr-xscripts/release/manifest-remove-existing86
-rwxr-xr-xscripts/release/mel-checkout334
-rw-r--r--scripts/release/setup-mel35
-rwxr-xr-xscripts/release/setup-workspace115
-rwxr-xr-xscripts/release/version-sort12
-rwxr-xr-xscripts/setup-debian54
-rwxr-xr-xscripts/setup-mel-builddir388
-rwxr-xr-xscripts/setup-rh42
-rwxr-xr-xscripts/setup-ubuntu48
-rw-r--r--setup-environment136
201 files changed, 3 insertions, 9300 deletions
diff --git a/.gitignore b/.gitignore
deleted file mode 100644
index 52e4e611..00000000
--- a/.gitignore
+++ /dev/null
@@ -1,2 +0,0 @@
-*.pyc
-*.pyo
diff --git a/README.md b/README.md
index 85bd021b..87bd8745 100644
--- a/README.md
+++ b/README.md
@@ -1,12 +1,4 @@
-OpenEmbedded/Yocto layers for Mentor Embedded Linux Flex OS
-===================================================
+# meta-mentor
-This repository holds the layers needed by our Yocto builds of Mentor Embedded
-Linux. At this time there are three such layers:
-
-- meta-mel: The Mentor Embedded Linux Flex OS distribution layer
-- meta-mel-support: Support files for MEL
-- meta-mentor-staging: Our staging area for bits which belong upstream
-
-See the individual layer readmes for additional detail and contribution
-information.
+This repository has been moved to:
+<https://github.com/MentorEmbedded/meta-sokol-flex>
diff --git a/conf/bblayers.conf.sample b/conf/bblayers.conf.sample
deleted file mode 100644
index fbe5fc9b..00000000
--- a/conf/bblayers.conf.sample
+++ /dev/null
@@ -1,7 +0,0 @@
-LCONF_VERSION = "7"
-
-TOPDIR := "${@os.path.dirname(os.path.dirname(FILE))}"
-BBPATH = "${TOPDIR}:${HOME}/.oe"
-BBFILES ?= ""
-
-BBLAYERS ?= ""
diff --git a/conf/conf-notes.txt b/conf/conf-notes.txt
deleted file mode 100644
index 5ed75922..00000000
--- a/conf/conf-notes.txt
+++ /dev/null
@@ -1,11 +0,0 @@
-Common targets are:
-
- core-image-base
- development-image
- production-image
-
-production-image requires that the ROOT_PASSWORD variable be set. See
-conf/local.conf for details.
-
-For qemu machines, you can also run the generated qemu images with a command
-like 'runqemu qemux86'.
diff --git a/conf/local.conf.sample b/conf/local.conf.sample
deleted file mode 100644
index ed044f2d..00000000
--- a/conf/local.conf.sample
+++ /dev/null
@@ -1,323 +0,0 @@
-# Distro is set to Mentor Embedded Linux Flex OS distro.
-DISTRO = 'mel'
-
-# 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:
-# qemuarm, qemumips, qemuppc, qemux86, qemux86-64.
-MACHINE ??= "qemux86"
-
-# The path to the installed sourcery toolchain. This defaults to using the one
-# from the CodeBench we're installed in.
-#EXTERNAL_TOOLCHAIN ?= "/path/to/toolchain"
-
-# Uncomment to use the oe/yocto-built toolchain rather than the external
-#TCMODE:mel = "default"
-
-# The CORE_IMAGE_EXTRA_INSTALL variable allows extra individual packages to be
-# added to any of the images inheriting core-image.bbclass, including the
-# "core" images (e.g. core-image-base, core-image-minimal) as well as
-# development-image and production-image..
-#CORE_IMAGE_EXTRA_INSTALL += "bash"
-
-# The EXTRA_IMAGE_FEATURES variable allows groups of 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:
-#
-# "graphics" - add a graphical environment, defaulting to wayland/weston
-# or x11 depending on vendor support.
-# "dbg-pkgs" - add -dbg packages for all installed packages
-# (adds symbol information for debugging/profiling)
-# "dev-pkgs" - add -dev packages for all installed packages
-# (useful if you want to develop against libs in the image)
-# "tools-sdk" - add development tools (gcc, make, pkgconfig etc.)
-# "tools-debug" - add debugging tools (gdb, strace)
-# "tools-profile" - add profiling tools (oprofile, exmap, lttng valgrind (x86 only))
-# "tools-benchmark" - add benchmarking tools (bonnie++, lmbench, etc)
-# "tools-testapps" - add useful testing tools (ts_print, aplay, arecord etc.)
-# "codebench-debug" - core debug tools for use with codebench. this is
-# a subset of tools-debug (gdbserver, strace, sftp server)
-# "debug-tweaks" - make an image suitable for development
-# e.g. ssh root access has a blank password
-# "splash" - include a splashscreen (default: psplash, but the
-# particular package can be set with the SPLASH variable)
-# "multimedia" - add gstreamer support for running multimedia files
-# "multilib-runtime" - basic runtime multilib libraries to enable execution
-# of third party executables and CodeBench development
-# on non-default archs (libgcc, libc, libstdc++, lttng)
-#
-# There are other options that can be used here, see
-# meta/classes/image.bbclass and meta/classes/core-image.bbclass for more
-# details.
-
-IMAGE_FEATURES_DEVELOPMENT ?= "debug-tweaks"
-IMAGE_FEATURES_DEVELOPMENT:append:feature-mel-bsp = " codebench-debug ssh-server-openssh tools-profile"
-EXTRA_IMAGE_FEATURES = "${IMAGE_FEATURES_DEVELOPMENT} multilib-runtime"
-
-# Image features for production-image
-IMAGE_FEATURES_PRODUCTION ?= ""
-IMAGE_FEATURES_DISABLED_PRODUCTION ?= "${IMAGE_FEATURES_DEVELOPMENT} ssh-server-dropbear"
-
-# Install tzdata with systemd when building read only images
-CORE_IMAGE_EXTRA_INSTALL += "${@bb.utils.contains('IMAGE_FEATURES', 'read-only-rootfs', 'tzdata' if d.getVar('VIRTUAL-RUNTIME_init_manager') == 'systemd' else '', '', d)}"
-
-# Uncomment to enable runtime testing with ptest
-#USER_FEATURES += "ptest"
-#EXTRA_IMAGE_FEATURES += "ptest-pkgs"
-
-# Example of how to add additional image types beyond the default. If the
-# machine doesn't define them, the default types are tar.bz2 and ext3.
-#IMAGE_FSTYPES:append = " jffs2"
-
-# Uncomment and alter to set the root password. Set to '0' to explicitly allow
-# the empty root password even in production-image. Set to '*' to explicitly
-# disable root login.
-#ROOT_PASSWORD = "0"
-IMAGE_CLASSES:append = " image-root-password"
-
-# User features lets you manipulate the distro features. To add a distro
-# feature, simply add it to USER_FEATURES. To remove, prefix it with ~.
-#
-# # Disable x11
-# USER_FEATURES += "~x11"
-#
-# Disable 3g by default, as most won't need it.
-USER_FEATURES += "~3g"
-
-# Disable near field communication support by default
-USER_FEATURES += "~nfc"
-
-# How many tasks bitbake should run in parallel
-BB_NUMBER_THREADS ?= "${@int(oe.utils.cpu_count() * 1.5)}"
-
-# How many jobs 'make' should run in parallel when compiling
-PARALLEL_MAKE ?= "-j ${@oe.utils.cpu_count() * 2}"
-
-# Uncomment to exclude GPLv3 software from the build
-#INCOMPATIBLE_LICENSE = "GPL-3.0* LGPL-3.0*"
-
-# Uncomment this to enable inclusion of gdbserver in the codebench-debug
-# packagegroup / image feature even when GPL-3.0 is in INCOMPATIBLE_LICENSE, or
-# using a distro which sets it that way (atp).
-#ALLOW_GPLV3_GDBSERVER = "1"
-
-# The gplv2 binutils does not support aarch64, so the gplv3 version is built and
-# installed with tools-profile on that architecture by default, even in a
-# non-gplv3 build. To disable this, you may comment this out, comment out line
-# which installs binutils, or remove tools-profile from EXTRA_IMAGE_FEATURES.
-INCOMPATIBLE_LICENSE_EXCEPTIONS:append:aarch64 = " ${BINUTILS_EXCEPTION}"
-BINUTILS_EXCEPTION = "${@'binutils:GPL-3.0-only' if d.getVar('PN') == 'binutils' or (bb.data.inherits_class('image', d) and bb.utils.filter('IMAGE_FEATURES', 'tools-profile', d) == 'tools-profile') else ''}"
-
-# Download files from a mirror
-# Uncomment this INHERIT, and define SOURCE_MIRROR_URL
-#
-#INHERIT += "own-mirrors"
-#SOURCE_MIRROR_URL = "file:///cache/downloads"
-#SOURCE_MIRROR_URL = "http://myserver/sources"
-
-# Our download directory / cache for the workspace
-DL_DIR ?= "${MELDIR}/downloads"
-
-# Continue to pull downloads from the build dir if available
-PREMIRRORS:prepend = "\
- .*://.*/.* file://${MELDIR}/${MACHINE}/downloads/ \n \
- .*://.*/.* file://${TOPDIR}/downloads/ \n \
-"
-
-# 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 variable determines where those files are placed.
-SSTATE_DIR ?= "${TOPDIR}/cached-binaries"
-
-# Continue to pull cached binaries from the MEL install
-SSTATE_MIRROR_SITES += "\
- file://${MELDIR}/${MACHINE}/cached-binaries \
- file://${MELDIR}/cached-binaries \
-"
-
-# Where to place the build output and temporary artifacts
-#
-# The default value follows:
-#TMPDIR = "${TOPDIR}/tmp"
-
-# When we're using an external toolchain, we don't want to ship a newly built
-# toolchain inside the Yocto SDK.
-include conf/include/drop-toolchain-from-sdk.inc
-
-#
-# 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.
-#
-# - '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
-#
-# We default to ipk:
-#PACKAGE_CLASSES ?= "package_ipk"
-
-# SDK/ADT target architecture
-#
-# Set to one of the mingw32 SDKMACHINEs to target Windows rather than Linux.
-# Warning: if you choose to add packages to TOOLCHAIN_HOST_TASK and target
-# Windows, then you must add the meta-mingw layer to your configuration.
-#
-# Valid values: i686, x86_64, i686-mingw32, x86_64-mingw32
-#SDKMACHINE ?= "x86_64"
-
-# Uncomment to make populate_sdk write a tar file rather than a .sh installer
-#SDK_PACKAGING_FUNC = ""
-
-# By default, only include the target sysroot in the SDK/ADE, not host tools.
-# Comment this line to change that. This packagegroup includes host tools like
-# autoconf, automake, etc. See the aforementioned warning about use of Windows
-# SDKMACHINE while setting TOOLCHAIN_HOST_TASK, if you're building a Windows
-# SDK/ADE.
-TOOLCHAIN_HOST_REMOVE ??= "nativesdk-packagegroup-sdk-host"
-TOOLCHAIN_HOST_TASK:remove = "${TOOLCHAIN_HOST_REMOVE}"
-
-# TOOLCHAIN_HOST_TASK is used to add host packages to the ADE/SDK, for
-# example, to add bash:
-#TOOLCHAIN_HOST_TASK_EXTRA += " nativesdk-bash"
-
-# TOOLCHAIN_TARGET_TASK is used to add target packages to the ADE/SDK, for
-# example, to add libncurses:
-#TOOLCHAIN_TARGET_TASK_EXTRA += " ncurses-libncurses"
-
-# Uncomment to set a site name (shown in CodeBench) for the ADE
-# Default: ADE for ${ADE_IDENTIFIER}
-#ADE_SITENAME ?= "My Company's ADE for ${ADE_IDENTIFIER}"
-
-# Uncomment to alter the identifier for the ADE. This mechanism is used to
-# support installation of multiple ADEs side-by-side. By default, every ADE
-# build gets its own identifier, so is self-contained already.
-# Default: ${SDKMACHINE}-${IMAGE_BASENAME}-${MACHINE}-${ADE_VERSION}
-#ADE_IDENTIFIER ?= "${SDKMACHINE}-${IMAGE_BASENAME}-${MACHINE}-${ADE_VERSION}.customized"
-
-# The following is a list of additional classes to use when building which
-# enable extra features. Some available options which can be included in this variable
-# are:
-# - 'buildstats' to collect build statistics (e.g. task times)
-USER_CLASSES ?= "buildstats"
-
-# 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"
-
-# Uncomment to automatically spawn a terminal if a patch fails to apply
-#PATCHRESOLVE = "user"
-
-# Archive the source and put them to ${DEPLOY_DIR}/sources/. This is
-# particularly useful for license compliance.
-#
-#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. These
-# variables affect both archiver and copyleft_compliance (similar to archiver,
-# but lighter and less flexible)
-COPYLEFT_LICENSE_INCLUDE = "GPL* LGPL*"
-COPYLEFT_LICENSE_EXCLUDE = "CLOSED Proprietary* Mentor Freescale EULA INTEL NetLogic"
-
-# Alternative to the above archiver class. Doesn't support srpm, patched or
-# configured source, diff generation, metadata, etc. Only emits original
-# pristine source from SRC_URI with patch series file. Upside is it symlinks,
-# so its tasks run very quickly, and it bypasses sstate (binary caching), so
-# we don't bloat up our SSTATE_DIR with source which already lives in DL_DIR.
-#INHERIT += "copyleft_compliance"
-
-# 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 than 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 necessary 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
-#
-# The SSTATE_MIRROR_SITES 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.
-#
-#SSTATE_MIRROR_SITES += "http://mymirror/sstate"
-#SSTATE_MIRROR_SITES += "\
-# http://someserver.tld/share/sstate \
-# file:///some/local/dir \
-#"
-
-# This may be used to abort the build when using an untested/unverified
-# version of the external toolchain.
-#SOURCERY_VERSION_REQUIRED = "2012.03"
-
-# The following options will build a companion 'debug filesystem' in addition
-# to the normal deployable filesystem. This companion system allows a
-# debugger to know the symbols and related sources. It can be used to
-# debug a remote 'production' system without having to add the debug symbols
-# and sources to remote system. If IMAGE_FSTYPES_DEBUGFS is not defined, it
-# defaults to IMAGE_FSTYPES.
-#IMAGE_GEN_DEBUGFS = "1"
-#IMAGE_FSTYPES_DEBUGFS = "tar.gz"
-#
-# Use this to add extra packages to the split-debug filesystem
-#EXTRA_DEBUG_PACKAGES = "ltrace strace"
-
-# 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-mel-support/README.md b/meta-mel-support/README.md
deleted file mode 100644
index d6c1e973..00000000
--- a/meta-mel-support/README.md
+++ /dev/null
@@ -1,29 +0,0 @@
-Mentor Embedded Linux Flex OS Support Layer for Yocto/OE
-================================================
-
-This layer holds the bits useful for Mentor Embedded Linux Flex OS, but which aren't
-appropriate for inclusion in the distro layer.
-
-This layer depends on:
-
-URI: git://git.openembedded.org/openembedded-core
-Branch: master
-
-It's most useful alongside meta-mel.
-
-
-Contributing
-------------
-
-Browse url: http://git.yoctoproject.org/cgit/cgit.cgi/meta-mentor
-Clone url: git://git.yoctoproject.org/meta-mentor.git
-
-To contribute to this layer you should submit the patches for review to the
-mailing list.
-
-Mailing list: meta-mentor@yoctoproject.org
-
-When sending single patches, please use something like
-'git send-email -1 --subject-prefix 'PATCH][meta-mel-support' --to meta-mentor@yoctoproject.org'
-
-When sending a series, please use oe-core/scripts/create-pull-request.
diff --git a/meta-mel-support/conf/layer.conf b/meta-mel-support/conf/layer.conf
deleted file mode 100644
index 8ffa4335..00000000
--- a/meta-mel-support/conf/layer.conf
+++ /dev/null
@@ -1,22 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-BBPATH .= ":${LAYERDIR}"
-BBFILES += "${LAYERDIR}/recipes-*/*/*.bb"
-BBFILES += "${LAYERDIR}/recipes-*/*/*.bbappend"
-
-# Let us add layer-specific files which are only applied when that
-# layer is included in our configuration
-BBFILES += "${@' '.join('${LAYERDIR}/%s/recipes*/*/*.bb' % layer \
- for layer in BBFILE_COLLECTIONS.split())}"
-
-LAYERDIR_RE ?= "${LAYERDIR}"
-BBFILE_COLLECTIONS += "mel-support"
-BBFILE_PRIORITY_mel-support = "4"
-BBFILE_PATTERN_mel-support = "^${LAYERDIR_RE}/"
-LAYERDEPENDS_mel-support = "core mentor-common"
-LAYERSERIES_COMPAT_mel-support = "kirkstone"
-
-PREFERRED_PROVIDER_virtual/nativesdk-update-alternatives ??= "nativesdk-opkg-utils"
-PREFERRED_PROVIDER_chkconfig-alternatives ??= "chkconfig-alternatives"
diff --git a/meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/110-arm-eabi-conf.patch b/meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/110-arm-eabi-conf.patch
deleted file mode 100644
index be85ceb1..00000000
--- a/meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/110-arm-eabi-conf.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-diff -urN binutils-2.16.91.0.7.orig/configure binutils-2.16.91.0.7/configure
---- binutils-2.16.91.0.7.orig/configure 2006-05-31 14:54:24.000000000 +0300
-+++ binutils-2.16.91.0.7/configure 2006-05-31 14:55:53.000000000 +0300
-@@ -1299,7 +1299,7 @@
- arm-*-elf* | strongarm-*-elf* | xscale-*-elf* | arm*-*-eabi* )
- noconfigdirs="$noconfigdirs target-libffi target-qthreads"
- ;;
-- arm*-*-linux-gnueabi)
-+ arm*-*-linux-gnueabi | arm*-*-linux-uclibcgnueabi)
- noconfigdirs="$noconfigdirs target-libffi target-qthreads"
- noconfigdirs="$noconfigdirs target-libjava target-libobjc"
- ;;
-diff -urN binutils-2.16.91.0.7.orig/configure.in binutils-2.16.91.0.7/configure.in
---- binutils-2.16.91.0.7.orig/configure.in 2006-05-31 14:54:24.000000000 +0300
-+++ binutils-2.16.91.0.7/configure.in 2006-05-31 14:55:53.000000000 +0300
-@@ -497,7 +497,7 @@
- arm-*-elf* | strongarm-*-elf* | xscale-*-elf* | arm*-*-eabi* )
- noconfigdirs="$noconfigdirs target-libffi target-qthreads"
- ;;
-- arm*-*-linux-gnueabi)
-+ arm*-*-linux-gnueabi | arm*-*-linux-uclibcgnueabi)
- noconfigdirs="$noconfigdirs target-libffi target-qthreads"
- noconfigdirs="$noconfigdirs target-libjava target-libobjc"
- ;;
diff --git a/meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch b/meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch
deleted file mode 100644
index 7a2c3fa5..00000000
--- a/meta-mel-support/gplv2/recipes-devtools/binutils/binutils-2.17.50.0.12/binutils-2.16.91.0.6-objcopy-rename-errorcode.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-# strip (and objcopy) fail to set the error code if there is no
-# output file name and the rename of the stripped (or copied) file
-# fails, yet the command fails to do anything. This fixes both
-# objcopy and strip.
-#
-# modification by bero: Ported to 2.16.91.0.6
-#
-#Signed-off-by: John Bowler <jbowler@acm.org>
-#Signed-off-by: Bernhard Rosenkraenzer <bero@arklinux.org>
---- binutils-2.16.91.0.6/binutils/objcopy.c.ark 2006-03-11 15:59:07.000000000 +0100
-+++ binutils-2.16.91.0.6/binutils/objcopy.c 2006-03-11 15:59:45.000000000 +0100
-@@ -2593,7 +2593,8 @@
- if (preserve_dates)
- set_times (tmpname, &statbuf);
- if (output_file == NULL)
-- smart_rename (tmpname, argv[i], preserve_dates);
-+ if(smart_rename (tmpname, argv[i], preserve_dates))
-+ hold_status = 1;
- status = hold_status;
- }
- else
-@@ -3184,7 +3185,8 @@
- {
- if (preserve_dates)
- set_times (tmpname, &statbuf);
-- smart_rename (tmpname, input_filename, preserve_dates);
-+ if (smart_rename (tmpname, input_filename, preserve_dates))
-+ status = 1;
- }
- else
- unlink (tmpname);
diff --git a/meta-mel-support/gplv2/recipes-devtools/binutils/binutils_2.17.50.0.12.bb b/meta-mel-support/gplv2/recipes-devtools/binutils/binutils_2.17.50.0.12.bb
deleted file mode 100644
index a20bfde6..00000000
--- a/meta-mel-support/gplv2/recipes-devtools/binutils/binutils_2.17.50.0.12.bb
+++ /dev/null
@@ -1,70 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-require recipes-devtools/binutils/binutils.inc
-
-DEFAULT_PREFERENCE = "-1"
-PR = "r1"
-
-LICENSE = "GPL-2.0-only & LGPL-2.0-only"
-LIC_FILES_CHKSUM = "\
- file://src-release;endline=17;md5=4830a9ef968f3b18dd5e9f2c00db2d35 \
- file://COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
- file://COPYING.LIB;md5=9f604d8a4f8e74f4f5140845a21b6674 \
- file://gas/COPYING;md5=77a30f8e524e777bf2078eb691ef3dd6 \
- file://include/COPYING;md5=59530bdf33659b29e73d4adb9f9f6552 \
- file://libiberty/COPYING.LIB;md5=a916467b91076e631dd8edb7424769c7 \
- file://bfd/COPYING;md5=77a30f8e524e777bf2078eb691ef3dd6 \
-"
-SRC_URI = "\
- ${KERNELORG_MIRROR}/linux/devel/binutils/binutils-${PV}.tar.bz2 \
- file://binutils-2.16.91.0.6-objcopy-rename-errorcode.patch \
- file://110-arm-eabi-conf.patch \
-"
-
-SRC_URI[md5sum] = "6f3e83399b965d70008860f697c50ec2"
-SRC_URI[sha256sum] = "7360808266f72aed6fda41735242fb9f1b6dd3307cd6e283a646932438eaa929"
-
-DEPENDS += "flex texinfo-native"
-
-#
-# we need chrpath > 0.14 and some distros like centos 7 still have older chrpath
-#
-DEPENDS:append:class-target = " chrpath-replacement-native"
-EXTRANATIVEPATH:append:class-target = " chrpath-native"
-
-EXTRA_OECONF += "\
- --with-sysroot=/ \
- --enable-install-libbfd \
- --enable-shared \
-"
-# FIXME: hack way to get it obeying LDFLAGS for GNU_HASH warnings
-TARGET_CC_ARCH += "${LDFLAGS}"
-
-# Disable texinfo usage due to incompatibilities with different versions
-EXTRA_OEMAKE += "'MAKEINFO=true'"
-
-do_configure () {
- oe_runconf
-}
-
-do_install:append () {
- rm -rf ${D}${prefix}/${TARGET_SYS}/lib
-}
-
-# Kill redundant rpaths
-do_install:append:class-target () {
- for i in ${D}${bindir}/*; do
- chrpath -d "$i"
- done
-}
-
-# This version doesn't provide these
-USE_ALTERNATIVES_FOR:remove = "ld.bfd elfedit ld.gold dwp"
-
-python () {
- '''This binutils version has no elfedit.'''
- compilefunc = d.getVar('do_compile', False).replace('chrpath -d ${B}/binutils/elfedit', '')
- d.setVar('do_compile', compilefunc)
-}
diff --git a/meta-mel-support/recipes-bsp/96boards-tools/96boards-tools/resize-helper.sh.in b/meta-mel-support/recipes-bsp/96boards-tools/96boards-tools/resize-helper.sh.in
deleted file mode 100755
index 8897ee97..00000000
--- a/meta-mel-support/recipes-bsp/96boards-tools/96boards-tools/resize-helper.sh.in
+++ /dev/null
@@ -1,31 +0,0 @@
-#! /bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0-or-later
-# ---------------------------------------------------------------------------------------------------------------------
-
-### BEGIN INIT INFO
-# Provides: Resize root filesystem to fit available disk space
-# Description: Start resize helper, then remove own init from runlevels,
-# as it is required only for first boot. run settle to provide partition
-# table details.
-### END INIT INFO
-
-DESC="resize helper"
-
-case $1 in
- start)
- echo "Starting $DESC"
- @bindir@/udevadm settle
- @sbindir@/resize-helper
- @sbindir@/update-rc.d remove resize-helper.sh
- ;;
- *)
- echo "Usage: @sysconfdir@/init.d/resize-helper.sh {start}" >&2
- exit 1
- ;;
-esac
-
-exit 0
-
-# vim:noet
diff --git a/meta-mel-support/recipes-bsp/96boards-tools/96boards-tools_0.12.bb b/meta-mel-support/recipes-bsp/96boards-tools/96boards-tools_0.12.bb
deleted file mode 100644
index 53ec6fc2..00000000
--- a/meta-mel-support/recipes-bsp/96boards-tools/96boards-tools_0.12.bb
+++ /dev/null
@@ -1,44 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SUMMARY = "Useful bits an pieces to make 96Boards more standard across the board"
-HOMEPAGE = "https://github.com/96boards/96boards-tools"
-SECTION = "devel"
-
-LICENSE = "GPL-2.0-or-later"
-LIC_FILES_CHKSUM = "file://${COREBASE}/meta/files/common-licenses/GPL-2.0;md5=801f80980d171dd6425610833a22dbe6"
-
-SRCREV = "a999d655417bb19ce8a476ff8c811e957748b661"
-SRC_URI = "git://github.com/96boards/96boards-tools;branch=master;protocol=https\
- file://resize-helper.sh.in"
-
-S = "${WORKDIR}/git"
-
-inherit systemd allarch update-rc.d
-
-do_install () {
- install -d ${D}${sysconfdir}/udev/rules.d
- install -m 0755 ${S}/*.rules ${D}${sysconfdir}/udev/rules.d/
-
- install -d ${D}${sbindir}
- install -m 0755 ${S}/resize-helper ${D}${sbindir}
-
- if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
- install -d ${D}${systemd_unitdir}/system
- install -m 0644 ${S}/resize-helper.service ${D}${systemd_unitdir}/system
- fi
-
- if ${@bb.utils.contains('DISTRO_FEATURES', 'sysvinit', 'true', 'false', d)}; then
- install -d ${D}${sysconfdir}/init.d
- install -m 0755 ${WORKDIR}/resize-helper.sh.in ${D}${sysconfdir}/init.d/resize-helper.sh
- sed -i -e "s:@bindir@:${bindir}:; s:@sbindir@:${sbindir}:; s:@sysconfdir@:${sysconfdir}:" \
- ${D}${sysconfdir}/init.d/resize-helper.sh
- fi
-}
-
-SYSTEMD_SERVICE:${PN} = "resize-helper.service"
-RDEPENDS:${PN} += "e2fsprogs-resize2fs gptfdisk parted util-linux udev"
-
-INITSCRIPT_NAME = "resize-helper.sh"
-INITSCRIPT_PARAMS = "start 22 5 3 ."
diff --git a/meta-mel-support/recipes-core/images/core-image-minimal-install-initramfs.bb b/meta-mel-support/recipes-core/images/core-image-minimal-install-initramfs.bb
deleted file mode 100644
index ccff19ba..00000000
--- a/meta-mel-support/recipes-core/images/core-image-minimal-install-initramfs.bb
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-require recipes-core/images/core-image-minimal-initramfs.bb
-export IMAGE_BASENAME = "${PN}"
diff --git a/meta-mel-support/recipes-core/images/development-image.bb b/meta-mel-support/recipes-core/images/development-image.bb
deleted file mode 100644
index 36178685..00000000
--- a/meta-mel-support/recipes-core/images/development-image.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SUMMARY = "A development/debugging image that fully supports the target \
-device hardware."
-
-IMAGE_FEATURES = "${IMAGE_FEATURES_DEVELOPMENT} ${EXTRA_IMAGE_FEATURES}"
-IMAGE_FEATURES_DEVELOPMENT ?= "debug-tweaks tools-profile"
-IMAGE_FEATURES_DISABLED_DEVELOPMENT ?= ""
-IMAGE_FEATURES:remove = "${IMAGE_FEATURES_DISABLED_DEVELOPMENT}"
-
-require recipes-core/images/mel-image.inc
diff --git a/meta-mel-support/recipes-core/images/mel-image.inc b/meta-mel-support/recipes-core/images/mel-image.inc
deleted file mode 100644
index 18b8ceec..00000000
--- a/meta-mel-support/recipes-core/images/mel-image.inc
+++ /dev/null
@@ -1,18 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# We want a package manager in our base images
-IMAGE_FEATURES += "package-management"
-
-# We want libgcc to always be available, even if nothing needs it, as its size
-# is minimal, and it's often needed by third party (or QA) binaries
-IMAGE_INSTALL:append:mel = " libgcc"
-
-LICENSE = "MIT"
-
-inherit core-image
-
-IMAGE_FEATURES:append:mel = " splash ${@bb.utils.contains('COMBINED_FEATURES', 'alsa', ' tools-audio', '', d)}"
-IMAGE_INSTALL:append:mel = " util-linux-mkfs connman"
-IMAGE_INSTALL:append:mel = " ${@bb.utils.contains('BBFILE_COLLECTIONS', 'openembedded-layer', 'haveged' if not any_incompatible(d, ['haveged'], 'GPL-3.0-only') else '', '', d)}"
diff --git a/meta-mel-support/recipes-core/images/production-image.bb b/meta-mel-support/recipes-core/images/production-image.bb
deleted file mode 100644
index c4b45609..00000000
--- a/meta-mel-support/recipes-core/images/production-image.bb
+++ /dev/null
@@ -1,18 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SUMMARY = "A production image that fully supports the target device \
-hardware."
-
-# By default, do not allow incompatibly-licensed packages in the
-# production-image, even when whitelisted. ALLOWED_INCOMPATIBLE_WHITELISTED
-# may be used to explicitly allow individual packages.
-ALLOW_ALL_INCOMPATIBLE_WHITELISTED = "0"
-
-IMAGE_FEATURES_PRODUCTION ?= ""
-IMAGE_FEATURES = "${IMAGE_FEATURES_PRODUCTION} ${EXTRA_IMAGE_FEATURES}"
-IMAGE_FEATURES_DISABLED_PRODUCTION ?= "debug-tweaks codebench-debug tools-profile"
-IMAGE_FEATURES:remove = "${IMAGE_FEATURES_DISABLED_PRODUCTION}"
-
-require recipes-core/images/mel-image.inc
diff --git a/meta-mel-support/recipes-core/meta/archive-release.bb b/meta-mel-support/recipes-core/meta/archive-release.bb
deleted file mode 100644
index a628ad08..00000000
--- a/meta-mel-support/recipes-core/meta/archive-release.bb
+++ /dev/null
@@ -1,472 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-DESCRIPTION = "Archive the artifacts for a ${DISTRO_NAME} release"
-LICENSE = "MIT"
-INHIBIT_DEFAULT_DEPS = "1"
-PACKAGE_ARCH = "${MACHINE_ARCH}"
-EXCLUDE_FROM_WORLD = "1"
-
-SRC_URI += "${@' '.join(uninative_urls(d)) if 'downloads' in '${RELEASE_ARTIFACTS}'.split() else ''}"
-SRC_URI += "https://github.com/01org/bmap-tools/releases/download/v3.4/bmaptool;name=bmaptool"
-SRC_URI[bmaptool.md5sum] = "7bc226c2b15aff58af31e421fa381d34"
-SRC_URI[bmaptool.sha256sum] = "8cedbb7a525dd4026b6cafe11f496de11dbda0f0e76a5b4938d2687df67bab7f"
-SRC_URI:append:qemuall = " file://runqemu.in"
-
-# We're using image fstypes data, inherit the class in case variables from it
-# are needed for IMAGE_FSTYPES
-inherit image_types nopackages
-
-UNINATIVE_BUILD_ARCHES ?= "x86_64 i686"
-MELDIR ?= "${COREBASE}/.."
-TEMPLATECONF_STR ?= "${@(oe.utils.read_file('${TOPDIR}/conf/templateconf.cfg') or '${FILE_DIRNAME}/../../../conf').rstrip()}"
-TEMPLATECONF = "${@os.path.join('${COREBASE}', '${TEMPLATECONF_STR}')}"
-
-BSPFILES_INSTALL_PATH ?= "${MACHINE}"
-BINARY_INSTALL_PATH ?= "${BSPFILES_INSTALL_PATH}/binary"
-CONF_INSTALL_PATH ?= "${BSPFILES_INSTALL_PATH}/conf"
-
-# Add a default in case the user doesn't inherit copyleft_compliance
-ARCHIVE_RELEASE_DL_DIR ?= "${DL_DIR}"
-ARCHIVE_RELEASE_DL_TOPDIR ?= "${ARCHIVE_RELEASE_DL_DIR}"
-
-# Default to shipping update-* as individual artifacts
-def configured_update_layers(d):
- """Return the configured layers whose basenames are update-*"""
- update_layers = set()
- for layer in d.getVar('BBLAYERS').split():
- basename = os.path.basename(layer)
- if basename.startswith('update-'):
- update_layers.add(layer)
- return ' '.join(sorted(update_layers))
-
-# Sub-layers to archive individually, rather than grabbing the entire
-# repository they're in
-def layers_by_name(d, *layers):
- for l in layers:
- v = d.getVar('LAYERDIR_%s' % l)
- if v:
- yield v
-
-SUBLAYERS_INDIVIDUAL_ONLY ?= ""
-SUBLAYERS_INDIVIDUAL_ONLY_TOPLEVEL ?= "${@configured_update_layers(d)}"
-
-DEPLOY_DIR_RELEASE ?= "${DEPLOY_DIR}/release-artifacts"
-RELEASE_ARTIFACTS ?= "layers bitbake templates images downloads"
-RELEASE_ARTIFACTS[doc] = "List of artifacts to include (available: layers, bitbake, templates, images, downloads"
-RELEASE_IMAGE ?= "core-image-base"
-RELEASE_IMAGE[doc] = "The image to build and archive in this release"
-RELEASE_USE_TAGS ?= "false"
-RELEASE_USE_TAGS[doc] = "Use git tags rather than just # of commits for layer archive versioning"
-RELEASE_USE_TAGS[type] = "boolean"
-RELEASE_EXCLUDED_SOURCES ?= ""
-RELEASE_EXCLUDED_SOURCES[doc] = "Patterns of files in ARCHIVE_RELEASE_DL_DIR to exclude"
-BINARY_ARTIFACTS_COMPRESSION ?= ""
-BINARY_ARTIFACTS_COMPRESSION[doc] = "Compression type for images and downloads artifacts.\
- Available: '.bz2' and '.gz'. No compression if empty"
-
-LAYERS_OWN_DOWNLOADS ?= "${@' '.join(l for l in '${BBFILE_COLLECTIONS}'.split() if l.startswith('update-'))}"
-LAYERS_OWN_DOWNLOADS[doc] = "Names of layers whose downloads should be shipped inside the layer itself, self contained."
-
-IMAGE_BASENAME = "${RELEASE_IMAGE}"
-IMAGE_LINK_NAME ?= "${IMAGE_BASENAME}-${MACHINE}"
-IMAGE_NAME_SUFFIX ?= ".rootfs"
-EXTRA_IMAGES_ARCHIVE_RELEASE ?= ""
-DEPLOY_IMAGES ?= "\
- ${@' '.join('${IMAGE_LINK_NAME}.%s' % ext for ext in d.getVar('IMAGE_EXTENSIONS').split())} \
- ${IMAGE_LINK_NAME}.license_manifest \
- ${IMAGE_LINK_NAME}.license_manifest.csv \
- ${EXTRA_IMAGES_ARCHIVE_RELEASE} \
-"
-DEPLOY_IMAGES:append:qemuall = "${@' ' + d.getVar('KERNEL_IMAGETYPE') if 'wic' not in d.getVar('IMAGE_EXTENSIONS') else ''}"
-DEPLOY_IMAGES[doc] = "List of files from DEPLOY_DIR_IMAGE which will be archived"
-
-# Use IMAGE_EXTENSION_xxx to map image type 'xxx' with real image file
-# extension name(s)
-IMAGE_EXTENSION_live = "hddimg iso"
-
-# Exclude certain image types from the packaged build.
-# This allows us to build in the automated environment for regression,
-# general testing or simply for availability of extra image types for
-# internal use without necessarily packaging them in the installers.
-ARCHIVE_RELEASE_IMAGE_FSTYPES_EXCLUDE ?= "tar.gz tar.bz2"
-
-def image_extensions(d):
- extensions = set()
- fstypes = d.getVar('IMAGE_FSTYPES').split()
- fstypes_exclude = d.getVar('ARCHIVE_RELEASE_IMAGE_FSTYPES_EXCLUDE').split()
- for type in fstypes:
- if type in fstypes_exclude:
- continue
- extension = d.getVar('IMAGE_EXTENSION_%s' % type) or type
- extensions.add(extension)
- return ' '.join(sorted(extensions))
- d.setVar('IMAGE_EXTENSIONS', ' '.join(sorted(extensions)))
-
-# If a wic image is enabled, that's all we want
-IMAGE_EXTENSIONS_FULL = "${@image_extensions(d)}"
-IMAGE_EXTENSIONS_WIC = "${@' '.join(e for e in d.getVar('IMAGE_EXTENSIONS_FULL').split() if 'wic' in e)}"
-IMAGE_EXTENSIONS ?= "${@d.getVar('IMAGE_EXTENSIONS_WIC') if d.getVar('IMAGE_EXTENSIONS_WIC') else d.getVar('IMAGE_EXTENSIONS_FULL')}"
-
-python () {
- # Make sure MELDIR is absolute, as we use it in transforms
- d.setVar('MELDIR', os.path.abspath(d.getVar('MELDIR')))
-
- for component in d.getVar('RELEASE_ARTIFACTS').split():
- ctask = 'do_archive_%s' % component
- if ctask not in d:
- bb.fatal('do_archive_release: no such task "%s" for component "%s" listed in RELEASE_ARTIFACTS' % (ctask, component))
-
- bb.build.addtask(ctask, 'do_prepare_release', 'do_patch do_prepare_recipe_sysroot', d)
- d.setVar('SSTATE_SKIP_CREATION:task-archive-%s' % component.replace('_', '-'), '1')
- d.setVarFlag(ctask, 'umask', '022')
- d.setVarFlag(ctask, 'dirs', '${S}/%s' % ctask)
- d.setVarFlag(ctask, 'cleandirs', '${S}/%s' % ctask)
- d.setVarFlag(ctask, 'sstate-inputdirs', '${S}/%s' % ctask)
- d.setVarFlag(ctask, 'sstate-outputdirs', '${DEPLOY_DIR_RELEASE}')
- d.setVarFlag(ctask, 'stamp-extra-info', '${MACHINE}')
- d.appendVarFlag(ctask, 'postfuncs', ' compress_binary_artifacts')
-}
-
-def uninative_urls(d):
- l = d.createCopy()
- for arch in d.getVar('UNINATIVE_BUILD_ARCHES').split():
- chksum = d.getVarFlag("UNINATIVE_CHECKSUM", arch)
- if chksum:
- l.setVar('BUILD_ARCH', arch)
- srcuri = l.expand("${UNINATIVE_URL}${UNINATIVE_TARBALL};sha256sum=%s;unpack=no;subdir=uninative/%s;downloadfilename=uninative/%s/${UNINATIVE_TARBALL}" % (chksum, chksum, chksum))
- yield srcuri
-
-release_tar () {
- tar --absolute-names --exclude=.svn \
- --exclude=.git --exclude=\*.pyc --exclude=\*.pyo --exclude=.gitignore "$@" \
- -v --show-stored-names
-}
-
-git_tar () {
- path="$1"
- shift
- name="$1"
- shift
- rel="${path##*/}"
-
- if [ -e "$path/.git" ]; then
- if [ "${@oe.data.typed_value('RELEASE_USE_TAGS', d)}" = "True" ]; then
- version="$(git --git-dir="$path/.git" describe --tags)"
- else
- version="$(git --git-dir="$path/.git" rev-list HEAD | wc -l)"
- fi
- git --git-dir=$path/.git archive --format=tar --prefix="${rel:-.}/" HEAD | bzip2 >${name}_${version}.tar.bz2
- else
- if repo_root "$path" | grep -q '^${MELDIR}/'; then
- if [ "${@oe.data.typed_value('RELEASE_USE_TAGS', d)}" = "True" ]; then
- version=$(cd "$path" && git describe --tags)
- else
- version=$(cd "$path" && git rev-list HEAD . | wc -l)
- fi
- release_tar $path "$@" -cjf ${name}_${version}.tar.bz2
- else
- release_tar $path "$@" -cjf $name.tar.bz2
- fi
- fi
-}
-# Workaround shell function dependency issue
-git_tar[vardeps] += "repo_root"
-
-repo_root () {
- git_root=$(cd $1 && git rev-parse --show-toplevel 2>/dev/null)
- # There's a chance this repo could be the overall environment
- # repository, not the layer repository, so just grab the layer
- # if the repo has submodules
- if [ -n "$git_root" ] && [ ! -e $git_root/.gitmodules ]; then
- echo $(cd $git_root && pwd)
- return
- fi
-
- rel=${1#${MELDIR}/}
- case "$rel" in
- /*)
- echo "$1"
- ;;
- *)
- echo "${MELDIR}/${rel%%/*}"
- ;;
- esac
-}
-repo_root[vardepsexclude] += "1#${MELDIR}/ rel%%/*"
-
-bb_layers () {
- for layer in ${BBLAYERS}; do
- layer="${layer%/}"
-
- topdir="$(repo_root "$layer")"
- repo_name="${topdir##*/}"
-
- layer_relpath="${layer#${topdir}/}"
- if [ "$layer_relpath" = "$topdir" ]; then
- layer_relpath=$repo_name
- else
- layer_relpath=$repo_name/$layer_relpath
- fi
-
- if echo "${SUBLAYERS_INDIVIDUAL_ONLY}" | grep -qw "$layer"; then
- printf "%s %s %s\n" "$layer" "$layer_relpath" "$(echo "$layer_relpath" | tr / _)"
- elif echo "${SUBLAYERS_INDIVIDUAL_ONLY_TOPLEVEL}" | grep -qw "$layer"; then
- printf "%s %s\n" "$layer" "${layer##*/}"
- else
- printf "%s %s\n" "$topdir" "$layer_relpath"
- fi
- done
-}
-# Workaround shell function dependency issue
-bb_layers[vardeps] += "repo_root"
-bb_layers[vardepsexclude] += "layer%/ topdir##*/ layer#${topdir}/"
-
-prepare_templates () {
- cp ${TEMPLATECONF}/conf-notes.txt .
- sed 's,^MACHINE ??=.*,MACHINE ??= "${MACHINE}",' ${TEMPLATECONF}/local.conf.sample >local.conf.sample
- if [ -n "${DISTRO}" ]; then
- sed -i 's,^DISTRO =.*,DISTRO = "${DISTRO}",' local.conf.sample
- fi
-
- sourcery_version="$(echo ${SOURCERY_VERSION} | sed 's/-.*$//')"
- if [ -n "$sourcery_version" ]; then
- sed -i "s,^#*\(SOURCERY_VERSION_REQUIRED =\).*,\1 \"$sourcery_version\"," local.conf.sample
- fi
-
- pdk_version="${PDK_DISTRO_VERSION}"
- if [ -n "$pdk_version" ]; then
- echo >>local.conf.sample
- echo "PDK_DISTRO_VERSION = \"$pdk_version\"" >>local.conf.sample
- fi
-
- sed -n '/^BBLAYERS/{n; :start; /\\$/{n; b start}; /^ *"$/d; :done}; p' ${TEMPLATECONF}/bblayers.conf.sample >bblayers.conf.sample
- echo 'BBLAYERS = "\' >>bblayers.conf.sample
- bb_layers | while read path relpath name; do
- printf ' $%s%s \\\n' '{MELDIR}/' "$relpath" >>bblayers.conf.sample
- done
- echo '"' >>bblayers.conf.sample
-}
-
-do_archive_layers () {
- >${MACHINE}-layers.txt
- bb_layers | while read path relpath name; do
- echo "$relpath" >>${MACHINE}-layers.txt
- done
-
- bb_layers | sort -k1,1 -u | while read path relpath name; do
- if [ -z "$name" ]; then
- name="${path##*/}"
- fi
-
- if echo "${SUBLAYERS_INDIVIDUAL_ONLY_TOPLEVEL}" | grep -qw "$path"; then
- # Grab the entire toplevel dir for non-individually-archived
- # sub-layers
- git_tar "$path" "$name" "--transform=s,^$path,$name,"
- else
- git_tar "$path" "$name" "--transform=s,^$path,$relpath,"
- fi
- done
-}
-
-do_archive_downloads () {
- for layer in ${BBLAYERS}; do
- ${@bb.utils.which('${BBPATH}', '../scripts/bb-print-layer-data')} "$layer/conf/layer.conf"
- done 2>/dev/null | sed -n 's/^\([^:]*\):[^|]*|\([^|]*\)|.*/\1|\2/p' >layermap.txt
-
- mkdir -p downloads
- if [ -e ${WORKDIR}/uninative ]; then
- cp -a ${WORKDIR}/uninative downloads/
- # We symlink to the root of downloads so the downloads dir can be
- # used either as a mirror or directly as the DL_DIR
- (cd downloads && find uninative -type f -print0 | xargs -0 -I"{}" sh -c 'touch "{}.done"; ln -sf "{}" .; ln -sf "{}.done" .')
- fi
-
- if [ "${ARCHIVE_RELEASE_DL_TOPDIR}" != "${ARCHIVE_RELEASE_DL_DIR}" ]; then
- for dir in ${ARCHIVE_RELEASE_DL_TOPDIR}/*/; do
- dir="${dir%/}"
- name=$(basename $dir)
- mkdir -p downloads/$name
- find -L $dir -type f -maxdepth 2 | while read source; do
- source_name="$(basename "$source")"
- if [ -e "${DL_DIR}/$source_name" ]; then
- ln -sf "${DL_DIR}/$source_name" "downloads/$name/$source_name"
- touch "downloads/$name/$source_name.done"
- fi
- done
- cd downloads/$name
- for file in ${RELEASE_EXCLUDED_SOURCES}; do
- rm -f "$file"
- done
- cd - >/dev/null
- layerpath="$(sed -n "s/^$name|//p" layermap.txt)" || exit 1
- if [ -n "$layerpath" ]; then
- layerroot="$(repo_root "$layerpath")"
- layerbase="${layerroot##*/}"
- if echo "${LAYERS_OWN_DOWNLOADS}" | grep -Eq "\<$name\>"; then
- layer_relpath="${layerpath#${layerroot}/}"
- if [ "$layer_relpath" = "$layerroot" ]; then
- layer_relpath=$layerbase
- else
- layer_relpath=$layerbase/$layer_relpath
- fi
- release_tar "--transform=s,^downloads/$name,$layer_relpath/downloads," -chf \
- $name-downloads.tar downloads/$name
- else
- release_tar "--transform=s,^downloads/$name,downloads," -rhf \
- $layerbase-downloads.tar downloads/$name
- fi
- fi
- done
- if [ -n "${UNINATIVE_TARBALL}" ]; then
- release_tar -chf ${MACHINE}-downloads.tar downloads/uninative $(find downloads/uninative -type f | sed 's,^.*/,downloads/,')
- fi
- else
- mkdir -p downloads
- find -L ${ARCHIVE_RELEASE_DL_DIR} -type f -maxdepth 2 | while read source; do
- source_name="$(basename "$source")"
- if [ -e "${DL_DIR}/$source_name" ]; then
- ln -sf "${DL_DIR}/$source_name" "downloads/$source_name"
- touch "downloads/$source_name.done"
- fi
- done
- cd downloads
- for file in ${RELEASE_EXCLUDED_SOURCES}; do
- rm -f "$file"
- done
- cd - >/dev/null
- release_tar -chf ${MACHINE}-downloads.tar downloads/
- fi
- rm -rf downloads layermap.txt
-}
-# Workaround shell function dependency issue
-do_archive_downloads[vardeps] += "repo_root"
-addtask archive_downloads after do_fetch
-
-do_archive_bitbake () {
- bitbake_dir="$(which bitbake)"
- bitbake_via_layers=0
- bb_layers | while read -r path _; do
- case "$bitbake_dir" in
- $path/*)
- return
- ;;
- esac
- done
-
- bitbake_path="$(repo_root $(dirname $(which bitbake))/..)"
- git_tar "$bitbake_path" bitbake "--transform=s,^$bitbake_path,${bitbake_path##*/},"
-}
-
-do_archive_images () {
- echo "--transform=s,-${MACHINE},,i" >include
- echo "--transform=s,${DEPLOY_DIR_IMAGE},${BINARY_INSTALL_PATH}," >>include
-
- for filename in ${DEPLOY_IMAGES}; do
- echo "${DEPLOY_DIR_IMAGE}/$filename" >>include
- done
-
- # Lock down any autorevs
- if [ -e "${BUILDHISTORY_DIR}" ]; then
- buildhistory-collect-srcrevs -p "${BUILDHISTORY_DIR}" >"${WORKDIR}/autorevs.conf"
- if [ -s "${WORKDIR}/autorevs.conf" ]; then
- echo "--transform=s,${WORKDIR}/autorevs.conf,${CONF_INSTALL_PATH}/autorevs.conf," >>include
- echo "${WORKDIR}/autorevs.conf" >>include
- fi
- fi
-
- if echo "${OVERRIDES}" | tr ':' '\n' | grep -qx 'qemuall'; then
- ext="$(echo "${IMAGE_EXTENSIONS}" | tr ' ' '\n' | grep -v '^tar' | head -n 1)"
- if [ ! -e "${DEPLOY_DIR_IMAGE}/${RELEASE_IMAGE}-${MACHINE}.$ext" ]; then
- bbfatal "Unable to find image for extension $ext, aborting"
- fi
- if [ -e "${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}-${MACHINE}.bin" ] || [ -e "${DEPLOY_DIR_IMAGE}/${KERNEL_IMAGETYPE}.bin" ]; then
- kernel="${KERNEL_IMAGETYPE}.bin"
- else
- kernel="${KERNEL_IMAGETYPE}"
- fi
- sed -e "s/##ROOTFS##/${RELEASE_IMAGE}.$ext/; s/##KERNEL##/$kernel/" ${WORKDIR}/runqemu.in >runqemu
- chmod +x runqemu
- echo "--transform=s,runqemu,${BINARY_INSTALL_PATH}/runqemu," >>include
- echo runqemu >>include
- fi
- if echo "${RELEASE_ARTIFACTS}" | grep -qw templates; then
- prepare_templates
- echo "--transform=s,$PWD/,${CONF_INSTALL_PATH}/," >>include
- echo "$PWD/local.conf.sample" >>include
- echo "$PWD/bblayers.conf.sample" >>include
- echo "$PWD/conf-notes.txt" >>include
- fi
-
- if [ -e "${DEPLOY_DIR_IMAGE}/${RELEASE_IMAGE}-${MACHINE}.qemuboot.conf" ]; then
- cp "${DEPLOY_DIR_IMAGE}/${RELEASE_IMAGE}-${MACHINE}.qemuboot.conf" ${WORKDIR}/qemuboot.conf
- sed -i -e 's,-${MACHINE},,g' ${WORKDIR}/qemuboot.conf
- echo "--transform=s,${WORKDIR}/qemuboot.conf,${BINARY_INSTALL_PATH}/${RELEASE_IMAGE}.qemuboot.conf," >>include
- echo "${WORKDIR}/qemuboot.conf" >>include
- fi
-
- if [ -n "${XLAYERS}" ]; then
- for layer in ${XLAYERS}; do
- echo "$layer"
- done \
- | sort -u >"${WORKDIR}/xlayers.conf"
- fi
- if [ -e "${WORKDIR}/xlayers.conf" ]; then
- echo "--transform=s,${WORKDIR}/xlayers.conf,${BSPFILES_INSTALL_PATH}/xlayers.conf," >>include
- echo "${WORKDIR}/xlayers.conf" >>include
- fi
-
- chmod +x "${WORKDIR}/bmaptool"
- echo "--transform=s,${WORKDIR}/bmaptool,${BINARY_INSTALL_PATH}/bmaptool," >>include
- echo "${WORKDIR}/bmaptool" >>include
- release_tar --files-from=include -chf ${MACHINE}-${ARCHIVE_RELEASE_VERSION}.tar
-}
-
-do_archive_templates () {
- if ! echo "${RELEASE_ARTIFACTS}" | grep -qw images; then
- prepare_templates
- fi
-}
-
-do_prepare_release () {
- echo ${DISTRO_VERSION} >distro-version
-}
-
-compress_binary_artifacts () {
- for fn in ${MACHINE}*.tar; do
- if [ -e "$fn" ]; then
- if [ ${BINARY_ARTIFACTS_COMPRESSION} = ".bz2" ]; then
- bzip2 "$fn"
- elif [ ${BINARY_ARTIFACTS_COMPRESSION} = ".gz" ]; then
- gzip "$fn"
- fi
- fi
- done
-}
-
-SSTATETASKS += "do_prepare_release ${@' '.join('do_archive_%s' % i for i in "${RELEASE_ARTIFACTS}".split())}"
-
-do_prepare_release[dirs] = "${S}/deploy"
-do_prepare_release[umask] = "022"
-SSTATE_SKIP_CREATION:task-prepare-release = "1"
-do_prepare_release[sstate-inputdirs] = "${S}/deploy"
-do_prepare_release[sstate-outputdirs] = "${DEPLOY_DIR_RELEASE}"
-do_prepare_release[stamp-extra-info] = "${MACHINE}"
-addtask do_prepare_release before do_build after do_patch
-
-# Ensure that all our dependencies are entirely built
-do_archive_images[depends] += "${@'${RELEASE_IMAGE}:do_${BB_DEFAULT_TASK}' if '${RELEASE_IMAGE}' else ''}"
-
-# When archiving downloads, make sure they're fetched
-FETCHALL_TASK = "${@'do_archive_release_downloads_all' if oe.utils.inherits(d, 'archive-release-downloads') else 'do_fetchall'}"
-do_archive_downloads[depends] += "${@'${RELEASE_IMAGE}:${FETCHALL_TASK}' if '${RELEASE_IMAGE}' else ''}"
-
-do_configure[noexec] = "1"
-do_compile[noexec] = "1"
-do_install[noexec] = "1"
-deltask do_populate_sysroot
-
-# This recipe emits no packages, and archives existing buildsystem content and
-# output whose licenses are outside our control
-deltask populate_lic
diff --git a/meta-mel-support/recipes-core/meta/archive-release/runqemu.in b/meta-mel-support/recipes-core/meta/archive-release/runqemu.in
deleted file mode 100755
index 302a650b..00000000
--- a/meta-mel-support/recipes-core/meta/archive-release/runqemu.in
+++ /dev/null
@@ -1,24 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-scriptdir="$(cd "$(dirname "$0")" && pwd)"
-meldir="$(cd "$scriptdir/../../.." && pwd)"
-
-if ! which bitbake >/dev/null 2>&1; then
- if [ -e "$meldir/manifests" ] && ! [ -e "$meldir/meta-mentor" ]; then
- echo >&2 "Unable to run bitbake, please create a workspace by sourcing $meldir/setup-mel and then source the setup script: . <workspacedir>/meta-mentor/setup-environment"
- else
- echo >&2 "Unable to run bitbake, please source the setup script: . $meldir/meta-mentor/setup-environment"
- fi
- exit 1
-fi
-
-if ( eval $(bitbake -e | grep -E '^COMPONENTS_DIR='); ! [ -e "$COMPONENTS_DIR/x86_64/qemu-helper-native/usr/bin/tunctl" ] ); then
- echo >&2 "Unable to find tunctl binary, building qemu-helper-native.."
- bitbake qemu-helper-native:do_addto_recipe_sysroot
-fi
-
-exec "$meldir/oe-core/scripts/runqemu" "$(basename "${scriptdir%/*/*}")" "$scriptdir/"*.qemuboot.conf "$@"
diff --git a/meta-mel-support/recipes-core/packagegroups/packagegroup-tools-audio.bb b/meta-mel-support/recipes-core/packagegroups/packagegroup-tools-audio.bb
deleted file mode 100644
index 0525b349..00000000
--- a/meta-mel-support/recipes-core/packagegroups/packagegroup-tools-audio.bb
+++ /dev/null
@@ -1,13 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-DESCRIPTION = "Package group for audio support."
-
-inherit packagegroup
-
-# alsa-utils-alsactl and alsa-utils-alsamixer is coming from alsa base packagegroup if alsa is added in MACHINE_FEATURES.
-RDEPENDS:${PN} += "\
- alsa-utils-amixer \
- alsa-utils-aplay \
-"
diff --git a/meta-mel-support/recipes-core/packagegroups/packagegroup-tools-benchmark.bb b/meta-mel-support/recipes-core/packagegroups/packagegroup-tools-benchmark.bb
deleted file mode 100644
index 4983fd06..00000000
--- a/meta-mel-support/recipes-core/packagegroups/packagegroup-tools-benchmark.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-inherit packagegroup incompatible-packages-check
-
-DESCRIPTION = "Package group for benchmarking the target"
-PR = "r0"
-
-META_OE_BENCHMARKS = "\
- bonnie++ \
- ${@'dbench' if not any_incompatible(d, ['dbench'], 'GPL-3.0-only') else ''} \
- iozone3 \
- iperf3 \
- lmbench \
- tiobench \
-"
-
-RDEPENDS:${PN} += "\
- ${@bb.utils.contains('BBFILE_COLLECTIONS', 'openembedded-layer', d.getVar('META_OE_BENCHMARKS'), '', d)} \
-"
diff --git a/meta-mel-support/recipes-kernel/linux/linux-yocto-rt_3.10.bb b/meta-mel-support/recipes-kernel/linux/linux-yocto-rt_3.10.bb
deleted file mode 100644
index 4aaf502f..00000000
--- a/meta-mel-support/recipes-kernel/linux/linux-yocto-rt_3.10.bb
+++ /dev/null
@@ -1,31 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-KBRANCH ?= "standard/preempt-rt/base"
-KBRANCH:qemuppc ?= "standard/preempt-rt/qemuppc"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-SRCREV_machine ?= "c75818e2932c3c0444ebebfcc0608fecf2440b92"
-SRCREV_machine:qemuppc ?= "fc7abf900967db5dea8a8f8648b8a0de7032f8d7"
-SRCREV_meta ?= "d5456dd830cad14bd844753b751b83744ced3793"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-3.10.git;bareclone=1;branch=${KBRANCH},meta;name=machine,meta"
-
-LINUX_VERSION ?= "3.10.65"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "meta"
-
-LINUX_KERNEL_TYPE = "preempt-rt"
-
-COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
-KERNEL_FEATURES:append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES:append:qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES:append:qemux86-64=" cfg/sound.scc"
-KERNEL_FEATURES:append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.10.bb b/meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.10.bb
deleted file mode 100644
index f033d221..00000000
--- a/meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.10.bb
+++ /dev/null
@@ -1,26 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-KBRANCH ?= "standard/tiny/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-LINUX_KERNEL_TYPE = "tiny"
-KCONFIG_MODE = "--allnoconfig"
-
-LINUX_VERSION ?= "3.10.65"
-
-KMETA = "meta"
-
-SRCREV_machine ?= "a2f2be49cd60b8d022fa47daae0a8293c3066b78"
-SRCREV_meta ?= "d5456dd830cad14bd844753b751b83744ced3793"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-3.10.git;bareclone=1;branch=${KBRANCH},meta;name=machine,meta"
-
-COMPATIBLE_MACHINE = "(qemux86)"
-
-# Functionality flags
-KERNEL_FEATURES = ""
diff --git a/meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.17.bb b/meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.17.bb
deleted file mode 100644
index 80145404..00000000
--- a/meta-mel-support/recipes-kernel/linux/linux-yocto-tiny_3.17.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-KBRANCH ?= "standard/tiny/base"
-LINUX_KERNEL_TYPE = "tiny"
-KCONFIG_MODE = "--allnoconfig"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-LINUX_VERSION ?= "3.17.8"
-
-KMETA = "meta"
-
-SRCREV_machine ?= "0409b1fbed221e61212e17b7637fa54f908d83f6"
-SRCREV_meta ?= "f24c2bf9c298595d00a9d8600841f2b0206e1fba"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-3.17.git;bareclone=1;branch=${KBRANCH},meta;name=machine,meta"
-
-COMPATIBLE_MACHINE = "(qemux86)"
-
-# Functionality flags
-KERNEL_FEATURES = ""
diff --git a/meta-mel-support/recipes-kernel/linux/linux-yocto_3.10.bb b/meta-mel-support/recipes-kernel/linux/linux-yocto_3.10.bb
deleted file mode 100644
index a5096988..00000000
--- a/meta-mel-support/recipes-kernel/linux/linux-yocto_3.10.bb
+++ /dev/null
@@ -1,41 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-KBRANCH ?= "standard/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# board specific branches
-KBRANCH:qemuarm ?= "standard/arm-versatile-926ejs"
-KBRANCH:qemumips ?= "standard/mti-malta32"
-KBRANCH:qemuppc ?= "standard/qemuppc"
-KBRANCH:qemux86 ?= "standard/common-pc/base"
-KBRANCH:qemux86-64 ?= "standard/common-pc-64/base"
-KBRANCH:qemumips64 ?= "standard/mti-malta64"
-
-SRCREV_machine:qemuarm ?= "7a8c197b86281f9a445e23378fdfeeb4da0c48e9"
-SRCREV_machine:qemumips ?= "926e71942842a9d1a9f64aae0458b2d777d3bca9"
-SRCREV_machine:qemuppc ?= "65648fce58a5e095cfe2bf394bc0f6200efb281c"
-SRCREV_machine:qemux86 ?= "a2f2be49cd60b8d022fa47daae0a8293c3066b78"
-SRCREV_machine:qemux86-64 ?= "a2f2be49cd60b8d022fa47daae0a8293c3066b78"
-SRCREV_machine:qemumips64 ?= "06d173388a171e7371816d74567fdec994925aa4"
-SRCREV_machine ?= "a2f2be49cd60b8d022fa47daae0a8293c3066b78"
-SRCREV_meta ?= "d5456dd830cad14bd844753b751b83744ced3793"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-3.10.git;bareclone=1;branch=${KBRANCH},${KMETA};name=machine,meta"
-
-LINUX_VERSION ?= "3.10.65"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "meta"
-
-COMPATIBLE_MACHINE = "qemuarm|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
-KERNEL_FEATURES:append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES:append:qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES:append:qemux86-64=" cfg/sound.scc"
-KERNEL_FEATURES:append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/meta-mel-support/recipes-kernel/linux/linux-yocto_3.17.bb b/meta-mel-support/recipes-kernel/linux/linux-yocto_3.17.bb
deleted file mode 100644
index 5dfb800c..00000000
--- a/meta-mel-support/recipes-kernel/linux/linux-yocto_3.17.bb
+++ /dev/null
@@ -1,43 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-KBRANCH ?= "standard/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# board specific branches
-KBRANCH:qemuarm ?= "standard/arm-versatile-926ejs"
-KBRANCH:qemuarm64 ?= "standard/qemuarm64"
-KBRANCH:qemumips ?= "standard/mti-malta32"
-KBRANCH:qemuppc ?= "standard/qemuppc"
-KBRANCH:qemux86 ?= "standard/common-pc"
-KBRANCH:qemux86-64 ?= "standard/common-pc-64/base"
-KBRANCH:qemumips64 ?= "standard/mti-malta64"
-
-SRCREV_machine:qemuarm ?= "12991e8ac40c51ef3e337f17f12aa59c6500fc7f"
-SRCREV_machine:qemuarm64 ?= "0409b1fbed221e61212e17b7637fa54f908d83f6"
-SRCREV_machine:qemumips ?= "1f4735ed314defc95ab9929258ad12844cc2c676"
-SRCREV_machine:qemuppc ?= "3231dececf867215ecab7c7f9ec3a7a7640a3f32"
-SRCREV_machine:qemux86 ?= "0409b1fbed221e61212e17b7637fa54f908d83f6"
-SRCREV_machine:qemux86-64 ?= "0409b1fbed221e61212e17b7637fa54f908d83f6"
-SRCREV_machine:qemumips64 ?= "7005c584078109dae03567e9c597a847a2bc5136"
-SRCREV_machine ?= "0409b1fbed221e61212e17b7637fa54f908d83f6"
-SRCREV_meta ?= "f24c2bf9c298595d00a9d8600841f2b0206e1fba"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-3.17.git;bareclone=1;branch=${KBRANCH},${KMETA};name=machine,meta"
-
-LINUX_VERSION ?= "3.17.8"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "meta"
-
-COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
-KERNEL_FEATURES:append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES:append:qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES:append:qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES:append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/meta-mel-support/recipes-support/tofrodos/tofrodos-native/Make-OE-friendly.patch b/meta-mel-support/recipes-support/tofrodos/tofrodos-native/Make-OE-friendly.patch
deleted file mode 100644
index 5d3c6972..00000000
--- a/meta-mel-support/recipes-support/tofrodos/tofrodos-native/Make-OE-friendly.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-Upstream-Status: Inappropriate [open-embedded]
-
-Signed-off-by: Muhammad Shakeel <muhammad_shakeel@mentor.com>
-
---- src/Makefile 2012-09-30 22:15:32.000000000 +0500
-+++ src/Makefile 2013-09-17 13:18:53.073698834 +0500
-@@ -30,7 +30,7 @@
- RM = rm -f
-
- # flags
--CFLAGS = $(DEFINES) $(TFLAG) $(CDEBUG) -c -Wall
-+CCFLAGS = $(DEFINES) $(TFLAG) $(CDEBUG) -c -Wall
- GZIPFLAGS = -9
- INSTALLBINFLAGS = -m 755
- INSTALLDATAFLAGS = -m 644
-@@ -58,7 +58,7 @@
-
- # implicit rules
- .c.o:
-- $(CC) $(CFLAGS) $<
-+ $(CC) $(CCFLAGS) $(CFLAGS) $<
-
- # user visible rules
- all: $(FROMDOS) $(TODOS)
-@@ -69,7 +69,7 @@
- clobber: clean
- $(RM) $(FROMDOS) $(TODOS)
-
--install: installman
-+install:
- $(INSTALL) $(INSTALLBINFLAGS) $(FROMDOS) $(BINDIR)
- ($(CD) $(BINDIR) ; $(LN) $(LNFLAGS) fromdos todos)
diff --git a/meta-mel-support/recipes-support/tofrodos/tofrodos-native_1.7.12a.bb b/meta-mel-support/recipes-support/tofrodos/tofrodos-native_1.7.12a.bb
deleted file mode 100644
index 5d67a53a..00000000
--- a/meta-mel-support/recipes-support/tofrodos/tofrodos-native_1.7.12a.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-DESCRIPTION = "Tofrodos is a text file conversion utility that converts ASCII files between the MSDOS and unix format"
-LICENSE = "GPL-2.0-only"
-LIC_FILES_CHKSUM = "file://../COPYING;md5=8ca43cbc842c2336e835926c2166c28b"
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
-
-SRC_URI = "http://tofrodos.sourceforge.net/download/tofrodos-${PV}.tar.gz \
- file://Make-OE-friendly.patch \
- "
-
-SRC_URI[md5sum] = "219c03d7c58975b335cdb5201338125a"
-SRC_URI[sha256sum] = "3098af78325486b99116c65c9f9bbbbfb3dfbeab1ab1e63a8da79550a5af6a08"
-
-S = "${WORKDIR}/tofrodos/src"
-
-inherit native
-
-do_install(){
- mkdir -p ${D}/${bindir}/
- oe_runmake 'BINDIR=${D}${bindir}' install
-}
diff --git a/meta-mel/README.md b/meta-mel/README.md
deleted file mode 100644
index 0f0885e3..00000000
--- a/meta-mel/README.md
+++ /dev/null
@@ -1,33 +0,0 @@
-Mentor Embedded Linux Flex OS Distribution Layer for Yocto/OE
-=====================================================
-
-This layer holds the Mentor Embedded Linux Flex OS distro configuration and
-associated policy.
-
-This layer depends on:
-
-URI: git://git.openembedded.org/openembedded-core
-Branch: master
-
-URI: git://git.yoctoproject.org/meta-yocto
-Revision: master
-
-We recommend including meta-mel-support and meta-mentor-staging as well, but
-these shouldn't be required.
-
-
-Contributing
-------------
-
-Browse url: http://git.yoctoproject.org/cgit/cgit.cgi/meta-mentor
-Clone url: git://git.yoctoproject.org/meta-mentor.git
-
-To contribute to this layer you should submit the patches for review to the
-mailing list.
-
-Mailing list: meta-mentor@yoctoproject.org
-
-When sending single patches, please use something like
-'git send-email -1 --subject-prefix 'PATCH][meta-mel' --to meta-mentor@yoctoproject.org'
-
-When sending a series, please use oe-core/scripts/create-pull-request.
diff --git a/meta-mel/classes/codename_is_corename.bbclass b/meta-mel/classes/codename_is_corename.bbclass
deleted file mode 100644
index afea0e65..00000000
--- a/meta-mel/classes/codename_is_corename.bbclass
+++ /dev/null
@@ -1,13 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-python codename_is_corename() {
- codename = d.getVar('DISTRO_CODENAME')
- if codename:
- corenames = d.getVar('LAYERSERIES_CORENAMES')
- if corenames and codename not in corenames.split():
- raise_sanity_error("This version of %s is incompatible with this version of openembedded-core (code name %s). Please use matching layer branches or update %s." % (d.getVar('DISTRO'), d.getVar('LAYERSERIES_CORENAMES'), d.getVar('DISTRO_NAME') or d.getVar('DISTRO')), d, network_error=False)
-}
-codename_is_corename[eventmask] = 'bb.event.SanityCheck'
-addhandler codename_is_corename
diff --git a/meta-mel/conf/distro/include/gdbserver-gplv3.inc b/meta-mel/conf/distro/include/gdbserver-gplv3.inc
deleted file mode 100644
index 098f93f5..00000000
--- a/meta-mel/conf/distro/include/gdbserver-gplv3.inc
+++ /dev/null
@@ -1,17 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# If ALLOW_GPLV3_GDBSERVER is set, allow {L,}GPLv3 for the gdb recipes
-ALLOW_GPLV3_GDBSERVER ?= ""
-INCOMPATIBLE_LICENSE_EXCEPTIONS += "\
- ${@'gdbserver-external:GPL-3.0 gdb:GPL-3.0' if '${ALLOW_GPLV3_GDBSERVER}' else ''} \
- ${@'gdb:LGPL-3.0' if '${ALLOW_GPLV3_GDBSERVER}' else ''} \
-"
-
-# If GPL-3.0 is in INCOMPATIBLE_LICENSE, and gdbserver/gdb isn't whitelisted,
-# then remove gdbserver from the codebench-debug image feature, otherwise the
-# build will fail.
-FEATURE_PACKAGES_codebench-debug:remove = "${@'gdbserver' if any_incompatible(d, ['gdbserver-external', 'gdb'], 'GPL-3.0-only') else ''}"
-
-INHERIT += "incompatible-packages-check"
diff --git a/meta-mel/conf/distro/include/mel-arm-tuning.inc b/meta-mel/conf/distro/include/mel-arm-tuning.inc
deleted file mode 100644
index dca2a7d0..00000000
--- a/meta-mel/conf/distro/include/mel-arm-tuning.inc
+++ /dev/null
@@ -1,28 +0,0 @@
-# Use common compatible tuning values.
-#
-# This avoids unnecessary toolchain component rebuilds and increases reuse and compatibility amongst
-# compatible machines.
-#
-# Imported from https://github.com/96boards/meta-rpb/blob/master/conf/distro/include/arm-defaults.inc
-# Imported from https://github.com/Angstrom-distribution/meta-angstrom/blob/master/conf/distro/include/arm-defaults.inc
-
-def get_generic_tune(d):
- features = d.getVar('TUNE_FEATURES').split()
- if 'aarch64' in features:
- tune = 'armv8a'
- if 'crc' in features:
- tune += '-crc'
- if 'crypto' in features:
- tune += '-crypto'
- # cortexa* tune files only list 'arm' in features instead of 'armv7*'
- elif 'armv7a' in features or 'armv7ve' in features or ('arm' in features and 'neon' in features):
- tune = 'armv7athf'
- if 'bigendian' in features:
- tune += 'b'
- if 'neon' in features:
- tune += '-neon'
- else:
- tune = d.getVar('DEFAULTTUNE')
- return tune
-
-DEFAULTTUNE:mel := "${@get_generic_tune(d)}"
diff --git a/meta-mel/conf/distro/include/sourcery-version-check.inc b/meta-mel/conf/distro/include/sourcery-version-check.inc
deleted file mode 100644
index 6c9d042c..00000000
--- a/meta-mel/conf/distro/include/sourcery-version-check.inc
+++ /dev/null
@@ -1,29 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-python sourcery_version_check () {
- if d.getVar('TCMODE', True) == 'default':
- return
-
- sourcery_version = d.getVar('SOURCERY_VERSION', True)
- if not sourcery_version or sourcery_version == 'UNKNOWN':
- return
-
- def version(s):
- if s is None:
- return []
- ver = s.split('-', 1)[0].split('.')
- if len(ver) > 2:
- ver = ver[:2]
- return ver
-
- # Check for a specified required toolchain version for releases
- toolchain_required_version = d.getVar('SOURCERY_VERSION_REQUIRED')
- if toolchain_required_version:
- if version(sourcery_version) != version(toolchain_required_version):
- bb.fatal('Found toolchain version `%s`, expected `%s`. Please install the supported toolchain.' % (sourcery_version, toolchain_required_version))
-}
-# We run this at build start to ensure that bitbake -e still works
-sourcery_version_check[eventmask] = "bb.event.BuildStarted"
-addhandler sourcery_version_check
diff --git a/meta-mel/conf/distro/include/wic-bmap.inc b/meta-mel/conf/distro/include/wic-bmap.inc
deleted file mode 100644
index d77b0b83..00000000
--- a/meta-mel/conf/distro/include/wic-bmap.inc
+++ /dev/null
@@ -1,12 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# If a wic image type is enabled, also enable wic.bmap
-python add_wic_bmap () {
- image_fstypes = d.getVar('IMAGE_FSTYPES', True).split()
- if any(f == 'wic' or f.startswith('wic.') for f in image_fstypes):
- d.setVar('IMAGE_FSTYPES', " ".join (image_fstypes + ['wic.bmap']))
-}
-add_wic_bmap[eventmask] = "bb.event.ConfigParsed"
-addhandler add_wic_bmap
diff --git a/meta-mel/conf/distro/mel-lite.conf b/meta-mel/conf/distro/mel-lite.conf
deleted file mode 100644
index 3b23de22..00000000
--- a/meta-mel/conf/distro/mel-lite.conf
+++ /dev/null
@@ -1,15 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-require conf/distro/include/mel.conf
-
-DISTRO .= "-lite"
-DISTRO_NAME += "Lite"
-DISTROOVERRIDES = "${DISTRO}:mel"
-
-SANITY_TESTED_DISTROS = "\
- ubuntu-18.04 \n\
-"
-
-GLIBCVERSION ?= "2.28%"
diff --git a/meta-mel/conf/distro/mel.conf b/meta-mel/conf/distro/mel.conf
deleted file mode 100644
index 857f28b9..00000000
--- a/meta-mel/conf/distro/mel.conf
+++ /dev/null
@@ -1,397 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-## Vendor Integration {{{1
-VENDOR_CONF = "${@'conf/vendor/%s.conf' % d.getVar('VENDOR') if d.getVar('VENDOR') else ''}"
-require ${VENDOR_CONF}
-## }}}1
-## MEL Base Configuration {{{1
-DISTRO = "mel"
-ADE_DISTRO = "mel-flex-os"
-DISTRO_NAME = "Mentor Embedded Linux Flex OS"
-DISTRO_CODENAME = "kirkstone"
-MAINTAINER = "Siemens Digital Industries Software <embedded_support@mentor.com>"
-HOME_URL = "https://www.mentor.com/embedded-software/linux/mel-flex-os/"
-SUPPORT_URL = "https://support.sw.siemens.com/"
-BUG_REPORT_URL = "https://support.sw.siemens.com/"
-ADE_PROVIDER = "${DISTRO_NAME}"
-TARGET_VENDOR = "-mel"
-SDK_VENDOR = "-melsdk"
-
-# Distro and release versioning
-DISTRO_VERSION = "13.0+snapshot-${DATE}"
-ARCHIVE_RELEASE_VERSION = "${DISTRO_VERSION}.${BSP_VERSION}.${PATCH_VERSION}"
-PDK_LICENSE_VERSION_DATE = "20181206"
-
-# Version of the mel-scripts artifact, including setup-mel
-SCRIPTS_VERSION ?= "1"
-
-# Default values for BSP and PATCH version, to be redefined in other layers
-BSP_VERSION ?= "0"
-PATCH_VERSION ?= "0"
-
-SDK_VERSION := "${@'${DISTRO_VERSION}'.replace('snapshot-${DATE}','snapshot')}"
-DISTRO_VERSION[vardepsexclude] = "DATE"
-SDK_VERSION[vardepsexclude] = "DATE"
-
-SDK_NAME = "${DISTRO}-${TCLIBC}-${SDK_ARCH}-${IMAGE_BASENAME}-${TUNE_PKGARCH}"
-SDKPATHINSTALL = "/opt/${DISTRO}/${SDK_VERSION}"
-
-# This is a single libc DISTRO, so exclude it from tmpdir name
-TCLIBCAPPEND = ""
-
-PSEUDO_IGNORE_PATHS:append = ",/run/"
-
-MEL_DEFAULT_EXTRA_RDEPENDS = "packagegroup-core-boot"
-MEL_DEFAULT_EXTRA_RRECOMMENDS = "kernel-module-af-packet"
-DISTRO_EXTRA_RDEPENDS += " ${MEL_DEFAULT_EXTRA_RDEPENDS}"
-DISTRO_EXTRA_RRECOMMENDS += " ${MEL_DEFAULT_EXTRA_RRECOMMENDS}"
-
-# Easier adjustment of oe-core QA check defaults
-WARN_TO_ERROR_QA ??= ""
-WARN_QA:remove = "${WARN_TO_ERROR_QA}"
-ERROR_QA:append = " ${WARN_TO_ERROR_QA}"
-
-# Default to the external toolchain if available
-TCMODE = "${@bb.utils.contains('BBFILE_COLLECTIONS', 'sourcery', 'external-sourcery-rebuild-libc', bb.utils.contains('BBFILE_COLLECTIONS', 'external-toolchain', 'external', 'default', d), d)}"
-
-# We want media to auto-mount
-DISTRO_EXTRA_RRECOMMENDS += "udev-extraconf"
-
-# Paths
-MELDIR ?= "${COREBASE}/.."
-
-# Use a local PR server by default
-PRSERV_HOST ?= "localhost:0"
-
-# Default to ipk packaging
-PACKAGE_CLASSES ?= "package_ipk"
-
-# MEL's supported hosts
-SANITY_TESTED_DISTROS = "\
- ubuntu-18.04 \n\
- ubuntu-20.04 \n\
- centos-7* \n \
- centoslinux-7* \n \
- debian-10* \n \
- rhel*-8* \n \
- redhatenterprise*-8* \n \
-"
-
-# Sane default append for the kernel cmdline (not used by all BSPs)
-# TODO: rename APPEND to something more appropriate
-APPEND ?= "${APPEND_SERIAL} console=tty0 ${APPEND_SPLASH}"
-
-APPEND_SPLASH = "${@'quiet splash' if '${SPLASH}' else ''}"
-APPEND_SPLASH .= "${@' plymouth:ignore-serial-consoles' if '${SPLASH}' == 'plymouth' else ''}"
-
-APPEND_SERIAL = "${@'console=${CMD_SERIAL_CONSOLE}' if '${SERIAL_CONSOLE}' else ''}"
-CMD_SERIAL_CONSOLE ?= "${@','.join(reversed('${SERIAL_CONSOLE}'.split()))}"
-
-# Not in APPEND by default, but can be added to it as needed
-APPEND_KGDBOC = "kgdbwait kgdboc=${CMD_SERIAL_CONSOLE}"
-
-# Splash screen
-SPLASH:mel ?= "psplash"
-PLYMOUTH_THEME ?= "mel"
-PLYMOUTH_SHOWDELAY ?= "0"
-DISTRO_EXTRA_RRECOMMENDS += "${@'plymouth-mel' if '${SPLASH}' == 'plymouth' else ''}"
-
-# Configuring plymouth to use the logo rather than modifying the theme script
-# to use it is a tradeoff. It lets you switch themes while keeping the same
-# splash screen, which is nice, the downside is a change to the logo requires
-# recompilation of plymouth.
-PLYMOUTH_LOGO ?= "${datadir}/plymouth/themes/mel/mel.png"
-LOGO:pn-plymouth = "${PLYMOUTH_LOGO}"
-
-# Remove MACHINE from default volname
-UBI_VOLNAME = "rootfs"
-
-# If a wic image type is enabled, also enable wic.bmap
-require conf/distro/include/wic-bmap.inc
-
-# Additional dependencies for deployed files are often pulled in via
-# do_image_wic[depends], to ensure the files are available for
-# IMAGE_BOOT_FILES, but this bypasses the do_image[recrdeptask] on
-# do_populate_lic. Add it for do_image_wic as well.
-do_image_wic[recrdeptask] += "do_populate_lic"
-
-# do_image_complete requires licenses, so add recursive dependency
-# on do_populate_lic
-do_image_complete[recrdeptask] += "do_populate_lic"
-
-# Quadruple the normal extra space in an image. 'du' is not a good way to really
-# see how much space will be needed and fails badly as the fs size grows.
-IMAGE_ROOTFS_EXTRA_SPACE = "40960"
-
-# Default locale for images
-IMAGE_LINGUAS ?= "en-us"
-
-# Make host user contamination an error
-WARN_TO_ERROR_QA = "host-user-contaminated"
-
-# Also check for host user contamination in the rootfs
-ROOTFS_POSTPROCESS_COMMAND:append = " rootfs_check_host_user_contaminated;"
-
-# Default to systemd, not sysvinit
-INIT_MANAGER ?= "systemd"
-
-# Support shallow git tarballs
-BB_GENERATE_SHALLOW_TARBALLS ?= "1"
-BB_GIT_SHALLOW ?= "1"
-
-BB_GIT_SHALLOW_DEPTH_DEFAULT ?= "1"
-BB_GIT_SHALLOW_DEPTH ??= "${@'${BB_GIT_SHALLOW_DEPTH_DEFAULT}' if not '${BB_GIT_SHALLOW_REVS}' else '0'}"
-BB_GIT_SHALLOW_REVS ??= ""
-
-# For our kernel repository, we want to ship the user the history which they
-# can't easily re-acquire from upstream.
-LINUX_VERSION_TAG ??= "v${@'.'.join('${LINUX_VERSION}'.split('.')[:2])}"
-LINUX_VERSION ??= ""
-BB_GIT_SHALLOW_REVS:pn-linux-mel ??= "${@'${LINUX_VERSION_TAG}' if '${LINUX_VERSION_TAG}' and '${LINUX_VERSION}' else ''}"
-
-# Export path variables into the devshell for convenience
-OE_TOPDIR = "${TOPDIR}"
-OE_WORKDIR = "${WORKDIR}"
-OE_TERMINAL_EXPORTS += "OE_TOPDIR OE_WORKDIR COREBASE"
-
-require conf/distro/include/no-static-libs.inc
-require conf/distro/include/yocto-uninative.inc
-
-INHERIT += "uninative"
-## }}}1
-## Mechanisms provided for user customization {{{1
-# Support USER_FEATURES
-INHERIT += "user_features"
-
-# The PACKAGECONFIG_REMOVE indirection exists to make it possible to override
-# the removals, as bitbake doesn't provide a mechanism to do so yet
-PACKAGECONFIG_REMOVE ??= ""
-PACKAGECONFIG:remove = "${PACKAGECONFIG_REMOVE}"
-
-# Ease adding to the SDK from a global context
-TOOLCHAIN_HOST_TASK_EXTRA ?= ""
-TOOLCHAIN_HOST_TASK:append = " ${TOOLCHAIN_HOST_TASK_EXTRA}"
-TOOLCHAIN_TARGET_TASK_EXTRA ?= ""
-TOOLCHAIN_TARGET_TASK_EXTRA:pn-buildtools-tarball = ""
-TOOLCHAIN_TARGET_TASK:append = " ${TOOLCHAIN_TARGET_TASK_EXTRA}"
-
-# Easier addition of shared state mirrors
-SSTATE_MIRROR_SITES ?= ""
-SSTATE_MIRRORS += "${@''.join(r'file://.* %s/PATH;downloadfilename=PATH \n' % u for u in '${SSTATE_MIRROR_SITES}'.split())}"
-## }}}1
-## Distro Features & Recipe Configuration {{{1
-MEL_DEFAULT_DISTRO_FEATURES = "opengl multiarch pam"
-
-# This violates typical MACHINE/DISTRO boundaries, but is part of MEL's
-# supported features. If the vendor supports x11 and not wayland for its
-# machines, so do we.
-DISTRO_FEATURES_DEFAULT:remove = "x11"
-MEL_DEFAULT_DISTRO_FEATURES += "${@bb.utils.contains('MACHINE_FEATURES', 'x11', \
- bb.utils.contains('MACHINE_FEATURES', 'wayland', 'wayland', 'x11', d), 'wayland', d)}"
-
-DISTRO_FEATURES ?= "${DISTRO_FEATURES_DEFAULT} ${DISTRO_FEATURES_LIBC} ${MEL_DEFAULT_DISTRO_FEATURES}"
-
-# Enable our staged fixes that are on their way upstream
-DISTRO_FEATURES:append = " mentor-staging"
-
-# Since many embedded systems don't have non-root users, allow autospawn for
-# root as well.
-PACKAGECONFIG:append:pn-pulseaudio = " autospawn-for-root"
-
-# We don't use dracut to build initramfs
-PACKAGECONFIG_REMOVE:pn-plymouth = "initrd"
-
-# Do not fetch the anti-virus db at compile-time
-INSTALL_CLAMAV_CVD ?= ""
-## }}}1
-## Inherits {{{1
-# We want information and history about build output
-INHERIT += "buildhistory"
-
-# Copy the image license manifest into DEPLOY_DIR_IMAGE
-INHERIT += "deploy-license-manifest"
-
-# Warn if there are available update layers which are not included in the
-# current configuration
-INHERIT += "mentor-updates-check"
-
-# Check PDK license
-INHERIT += "${@bb.utils.contains('BBFILE_COLLECTIONS', 'mentor-private', 'pdk-license', '', d)}"
-
-# Warn the user and disable rootfs resizing for non-GPLv3 builds
-INHERIT += "resize-rootfs-gplv3"
-
-# Ensure that our DISTRO_CODENAME aligns with LAYERSERIES_CORENAMES
-INHERIT += "codename_is_corename"
-
-# Ensure we're building the toolchain in a supported configuration
-ERROR_QA:append = " disallowed-tuning"
-ALLOWED_TUNING = "armv5te armv7ahf-neon armv7a-neon armv7at armv8a i686 riscv64 x86-64"
-INHERIT += "required_toolchain_config"
-
-# Use our toolchain relocation scripts
-INHERIT += "${@bb.utils.contains('BBFILE_COLLECTIONS', 'mentor-staging', 'toolchain_ship_relocate_sdk', '', d)}"
-TOOLCHAIN_SHAR_REL_TMPL = "${LAYERDIR_mentor-staging}/files/toolchain-shar-relocate.sh"
-TOOLCHAIN_EXT_REL_TMPL = "${LAYERDIR_mentor-staging}/files/toolchain-shar-extract.sh"
-RELOCATE_SDK_SH ?= "${LAYERDIR_mentor-staging}/files/relocate_sdk.sh"
-## }}}1
-## Preferences & Package Selection {{{1
-# Default to the Xorg X server if the BSP doesn't specify
-XSERVER ??= "\
- xserver-xorg \
- xf86-input-evdev \
- xf86-input-mouse \
- xf86-input-keyboard \
- xf86-video-fbdev \
-"
-
-# Obey our graphics image feature
-SYSTEMD_DEFAULT_TARGET ?= '${@bb.utils.contains_any("IMAGE_FEATURES", ["x11-base", "graphics", "weston"], "graphical.target", "multi-user.target", d)}'
-
-# We split out the initramfs install script bits into
-# core-image-minimal-install-initramfs, to keep core-image-minimal-initramfs
-# as generic as possible, but image-live may well expect the install bits.
-INITRD_IMAGE_LIVE ?= "core-image-minimal-install-initramfs"
-
-# Additional package groups
-#
-# We prefer wayland/weston, unless the vendor supports x11 but not wayland.
-FEATURE_PACKAGES_mel-weston = "weston weston-init weston-examples"
-FEATURE_PACKAGES_mel-x11 = "${FEATURE_PACKAGES_x11-base} ${FEATURE_PACKAGES_hwcodecs}"
-FEATURE_PACKAGES_graphics += "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', '${FEATURE_PACKAGES_mel-weston}', '', d)}"
-FEATURE_PACKAGES_graphics += "${@bb.utils.contains('DISTRO_FEATURES', 'x11', '${FEATURE_PACKAGES_mel-x11}', '', d)}"
-FEATURE_PACKAGES_tools-audio ?= "packagegroup-tools-audio"
-FEATURE_PACKAGES_tools-benchmark ?= "packagegroup-tools-benchmark"
-FEATURE_PACKAGES_multimedia ?= "gstreamer1.0 gstreamer1.0-plugins-base gstreamer1.0-plugins-good gstreamer1.0-plugins-bad"
-FEATURE_PACKAGES_virtualization ?= "docker-ce python3-docker-compose"
-FEATURE_PACKAGES_codebench-debug ?= "gdbserver strace openssh-sftp-server"
-
-# Baseline runtime for third party multilib executables.
-# libc/libgcc/libstdc++, plus lttng for tracing. Only applies to images
-# without MLPREFIX set (i.e. development-image, not lib32-development-image).
-MULTILIB_RUNTIME_PACKAGES = "glibc libgcc libstdc++ ${@bb.utils.contains('IMAGE_FEATURES', 'tools-profile', 'lttng-ust', '', d)}"
-MULTILIB_RUNTIME_FEATURE_PACKAGES = "${@' '.join(multilib_pkg_extend(d, pkg) for pkg in d.getVar('MULTILIB_RUNTIME_PACKAGES').split())}"
-FEATURE_PACKAGES_multilib-runtime ?= "${@d.getVar('MULTILIB_RUNTIME_FEATURE_PACKAGES') if not d.getVar('MLPREFIX') else ''}"
-
-# Analogous to the nfs-server group
-FEATURE_PACKAGES_samba-server ?= "samba swat"
-
-# Include nss-myhostname for sysvinit, so the hostname resolves. systemd
-# includes myhostname itself.
-DISTRO_EXTRA_RRECOMMENDS += "${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '', 'nss-myhostname', d)}"
-## }}}1
-## Workarounds & Overrides {{{1
-# Override arm tuning to reduce specificity and increase reuse.
-require conf/distro/include/mel-arm-tuning.inc
-
-# Ensure that the output directory always exists, this fixes use of meta-sca
-# with certain meta-imx recipes.
-do_sca_tracefiles[dirs] =+ "${SCA_SOURCES_DIR}"
-
-# We aren't supporting meta-intel's RMC
-BBMASK += "/meta-intel/common/recipes-bsp/systemd-boot/"
-
-# webkitgtk link fails due to memory exhaustion, so disable debug info to
-# reduce the memory footprint
-DEBUG_FLAGS:remove:pn-webkitgtk = "-g"
-
-# Work around git safe directory issue with METADATA_*, by forcing early expansion
-# while in a build user context.
-require classes/metadata_scm.bbclass
-METADATA_BRANCH := "${@base_detect_branch(d)}"
-METADATA_REVISION := "${@base_detect_revision(d)}"
-## }}}1
-## SDK & Application Development Environment {{{1
-# Use DEPLOY_DIR_ naming for consistency
-SDK_DEPLOY:mel = "${DEPLOY_DIR_SDK}"
-DEPLOY_DIR_SDK ?= "${DEPLOY_DIR}/sdk"
-
-# As we remove the toolchain from the sdk, naming it 'toolchain' is not
-# accurate, and sdk better describes what it is anyway.
-TOOLCHAIN_OUTPUTNAME ?= "${SDK_NAME}-sdk-${SDK_VERSION}"
-
-# Restore the default to buildtools-tarball, as that recipe sets it with ?=
-TOOLCHAIN_OUTPUTNAME:pn-buildtools-tarball = "${SDK_ARCH}-buildtools-nativesdk-standalone-${DISTRO_VERSION}"
-
-# Add KERNEL_* to the SDK environment (unexported) for use by the user
-TOOLCHAIN_TARGET_TASK_EXTRA += " sdk-env-kernelvars"
-
-# Set this so the ADE can set the right Yocto multilib display option
-EXTERNAL_SETUP_SCRIPT_VARS += "REAL_MULTIMACH_TARGET_SYS"
-EXTERNAL_REAL_MULTIMACH_TARGET_SYS ??= "${REAL_MULTIMACH_TARGET_SYS}"
-CB_MBS_OPTIONS[general.yocto.sdk.value] = "${EXTERNAL_REAL_MULTIMACH_TARGET_SYS}"
-
-# This allows us to control what base target packages are installed for the
-# configured multilibs, by altering SDK_MULTILIB_VARIANTS to differ from
-# MULTILIB_VARIANTS. We also append meta-environment to obey
-# SDK_MULTILIB_VARIANTS as well.
-IMAGE_CLASSES += "image-sdk-multilib-variants"
-
-# Cull duplicate/invalid files for windows SDKMACHINEs
-IMAGE_CLASSES += "${@bb.utils.contains('BBFILE_COLLECTIONS', 'mentor-staging', 'win_sdk_cull', '', d)}"
-
-# We need to ensure we can distribute downloads for SDK/ADE builds
-IMAGE_CLASSES += "archive_sdk_downloads"
-
-# Create a 'latest' symlink for the SDK
-IMAGE_CLASSES += "sdk_latest_link"
-
-# If meta-mentor-private is available, pull in the populate-ade class
-ADE_IMAGE_CLASS = "${@bb.utils.contains('BBFILE_COLLECTIONS', 'mentor-private', 'populate_ade archive_ade_downloads', '', d)}"
-IMAGE_CLASSES += "${ADE_IMAGE_CLASS}"
-## }}}1
-## MEL Releases {{{1
-# Default image for our installers
-RELEASE_IMAGE ?= "development-image"
-RELEASE_ARTIFACTS ?= "mel_layers mel_downloads templates images"
-
-# Apply any release-time srcrev lockdowns for AUTOREV recipes
-include ${MELDIR}/${MACHINE}/conf/autorevs.conf
-
-# LAYERDIRs for our layers, by name
-INHERIT += "layerdirs"
-
-# Populate a tree of downloads organized by layer
-ARCHIVE_RELEASE_DL_DIR ?= "${DEPLOY_DIR}/release-downloads"
-DL_LICENSE_INCLUDE ?= "*"
-INHERIT += "archive-release-downloads"
-
-# For our forks, also point an 'upstream' remote at upstream
-UPSTREAM_URL_meta-virtualization = "git://git.yoctoproject.org/meta-virtualization"
-FORKED_REPOS ?= "meta-virtualization"
-
-# Our public layers should use non-ssh URIs for their remotes
-PUBLIC_REPOS ?= "meta-mentor meta-sourcery meta-tracing ${FORKED_REPOS}"
-
-# Define a location for placing external artifacts to be used by the build
-MEL_EXTERNAL_ARTIFACTS ?= "${TOPDIR}/mel-external-artifacts"
-## }}}1
-## Includes {{{1
-
-# Support for SOURCERY_VERSION_REQUIRED
-require conf/distro/include/sourcery-version-check.inc
-
-# Handle GPLv3 gdbserver
-require conf/distro/include/gdbserver-gplv3.inc
-
-# QT5 configuration. These are includes rather than requires, as they live in
-# other layers.
-include conf/distro/include/qt5-mel.conf
-include conf/distro/include/qt5-versions.inc
-
-# Security configuration.
-include conf/distro/include/mel-security.conf
-
-# SWUpdate configuration.
-include conf/distro/include/mel-swupdate.conf
-
-# MCF configuration
-include conf/distro/include/mel-mcf.conf
-
-# INITRAMFS
-INITRAMFS_IMAGE ?= "mel-initramfs-image"
-INITRAMFS_IMAGE_BUNDLE ?= "${@bb.utils.contains('KERNEL_IMAGETYPES', 'fitimage', '', '1', d)}"
-## }}}1
-# vim: set fdm=marker fdl=0 :
diff --git a/meta-mel/conf/include/drop-toolchain-from-sdk.inc b/meta-mel/conf/include/drop-toolchain-from-sdk.inc
deleted file mode 100644
index 2634357d..00000000
--- a/meta-mel/conf/include/drop-toolchain-from-sdk.inc
+++ /dev/null
@@ -1,17 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# When we're using an external toolchain, we don't want to ship a newly built
-# toolchain inside the Yocto SDK. Normally meta-environment comes from the
-# same packagegroup which installs the toolchain, so add that back in
-# explicitly.
-python () {
- if oe.utils.inherits(d, 'populate_sdk_base'):
- host_task = d.getVar('TOOLCHAIN_HOST_TASK', True)
- tcmode = d.getVar('TCMODE', True)
- packagegroup = d.expand('packagegroup-cross-canadian-${MACHINE}')
- if packagegroup in host_task.split() and tcmode.startswith('external'):
- d.setVar('TOOLCHAIN_HOST_TASK:remove', 'packagegroup-cross-canadian-${MACHINE}')
- d.setVar('TOOLCHAIN_HOST_TASK:append', ' meta-environment-${MACHINE}')
-}
diff --git a/meta-mel/conf/layer.conf b/meta-mel/conf/layer.conf
deleted file mode 100644
index 906f471c..00000000
--- a/meta-mel/conf/layer.conf
+++ /dev/null
@@ -1,23 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-BBPATH .= ":${LAYERDIR}"
-BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
- ${LAYERDIR}/recipes-*/*/*.bbappend"
-
-# Let us add layer-specific bbappends which are only applied when that
-# layer is included in our configuration
-BBFILES += "${@' '.join('${LAYERDIR}/%s/recipes*/*/*.bbappend' % layer \
- for layer in BBFILE_COLLECTIONS.split())}"
-BBFILES += "${@' '.join('${LAYERDIR}/%s/recipes*/*/*.bb' % layer \
- for layer in BBFILE_COLLECTIONS.split())}"
-
-LAYERDIR_RE ?= "${LAYERDIR}"
-BBFILE_COLLECTIONS += "mel"
-BBFILE_PRIORITY_mel = "12"
-BBFILE_PATTERN_mel = "^${LAYERDIR_RE}/"
-LAYERSERIES_COMPAT_mel = "kirkstone"
-LAYERDEPENDS_mel = "core mentor-common"
-LAYERRECOMMENDS_mel = "mel-support mentor-staging sourcery mentor-private tracing-layer"
-LAYERRECOMMENDS_mel += "openembedded-layer filesystems-layer networking-layer multimedia-layer gplv2"
diff --git a/meta-mel/files/kgdb.cfg b/meta-mel/files/kgdb.cfg
deleted file mode 100644
index ec98930e..00000000
--- a/meta-mel/files/kgdb.cfg
+++ /dev/null
@@ -1,4 +0,0 @@
-CONFIG_DEBUG_KERNEL=y
-CONFIG_KGDB=y
-CONFIG_KGDB_SERIAL_CONSOLE=y
-CONFIG_DEBUG_INFO=y
diff --git a/meta-mel/lib/bblayers/mel_utils.py b/meta-mel/lib/bblayers/mel_utils.py
deleted file mode 100644
index 666f6a88..00000000
--- a/meta-mel/lib/bblayers/mel_utils.py
+++ /dev/null
@@ -1,315 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# TODO: add an argument to enable/disable dependency traversal vs just the
-# specified recipes
-import argparse
-import logging
-import os
-import sys
-import tempfile
-
-from collections import defaultdict
-
-import bb.command
-import bb.cookerdata
-import bb.fetch
-import bb.utils
-
-from bblayers.common import LayerPlugin
-
-logger = logging.getLogger('bitbake-layers')
-
-
-def plugin_init(plugins):
- return MELUtilsPlugin()
-
-
-def iter_except(func, exception, first=None):
- """Call a function repeatedly until an exception is raised.
-
- Converts a call-until-exception interface to an iterator interface.
- Like __builtin__.iter(func, sentinel) but uses an exception instead
- of a sentinel to end the loop.
-
- Examples:
- bsddbiter = iter_except(db.next, bsddb.error, db.first)
- heapiter = iter_except(functools.partial(heappop, h), IndexError)
- dictiter = iter_except(d.popitem, KeyError)
- dequeiter = iter_except(d.popleft, IndexError)
- queueiter = iter_except(q.get_nowait, Queue.Empty)
- setiter = iter_except(s.pop, KeyError)
-
- """
- try:
- if first is not None:
- yield first()
- while 1:
- yield func()
- except exception:
- pass
-
-
-class MELUtilsPlugin(LayerPlugin):
- def _get_depgraph(self, targets, task='do_build'):
- depgraph = None
-
- self.tinfoil.set_event_mask(['bb.event.DepTreeGenerated', 'bb.command.CommandCompleted', 'bb.event.NoProvider', 'bb.command.CommandFailed', 'bb.command.CommandExit'])
- if not self.tinfoil.run_command('generateDepTreeEvent', targets, task):
- logger.critical('Error starting dep tree event command')
- return 1
-
- for event in iter_except(lambda: self.tinfoil.wait_event(0.25), Exception):
- if event is None:
- continue
- if isinstance(event, bb.command.CommandCompleted):
- break
- elif isinstance(event, bb.command.CommandFailed):
- return None, 'Error running command: %s' % event.error
- elif isinstance(event, bb.command.CommandExit):
- return None, 'Error running command: exited with %s' % event.exitcode
- elif isinstance(event, bb.event.NoProvider):
- if event._reasons:
- return None, 'Nothing provides %s: %s' % (event._item, event._reasons)
- else:
- return None, 'Nothing provides %s.' % event._item
- elif isinstance(event, bb.event.DepTreeGenerated):
- depgraph = event._depgraph
- break
- elif isinstance(event, logging.LogRecord):
- logger.handle(event)
- else:
- logger.warning('Unhandled event %s: %s' % (event.__class__.__name__, event))
- return depgraph, None
-
- def _localpaths_by_layer(self, data, recipe_filename, layer_for_file, mirrortarballs=False):
- def ud_localpaths(u, layer_name, dldir, d):
- if hasattr(u.method, 'process_submodules'):
- def archive_submodule(ud, url, module, modpath, workdir, d):
- url += ";bareclone=1;nobranch=1"
- newfetch = bb.fetch2.Fetch([url], d)
- for subud in newfetch.ud.values():
- return ud_localpaths(subud, layer_name, dldir, d)
-
- # If we're using a shallow mirror tarball it needs to be unpacked
- # temporarily so that we can examine the .gitmodules file
- if u.shallow and os.path.exists(u.fullshallow) and u.method.need_update(u, d):
- import tempfile
- with tempfile.TemporaryDirectory(dir=dldir) as tmpdir:
- bb.fetch2.runfetchcmd("tar -xzf %s" % u.fullshallow, d, workdir=tmpdir)
- u.method.process_submodules(u, tmpdir, archive_submodule, d)
- else:
- u.method.process_submodules(u, u.clonedir, archive_submodule, d)
-
- decoded = bb.fetch.decodeurl(u.url)
- if decoded[0] == 'file':
- return
-
- u.setup_localpath(data)
- localpath = u.localpath
-
- if mirrortarballs and hasattr(u, 'mirrortarballs'):
- for mt in u.mirrortarballs:
- mt_abs = os.path.join(dldir, mt)
- if os.path.exists(mt_abs):
- localpath = mt_abs
- break
-
- items_by_layer[layer_name].add(os.path.normpath(localpath))
-
- src_uri = data.getVar('SRC_URI').split()
- fetcher = bb.fetch.Fetch(src_uri, data)
- urldata = fetcher.ud
- dldir = data.getVar('DL_DIR')
-
- items_by_layer = defaultdict(set)
- items_files = data.varhistory.get_variable_items_files('SRC_URI')
- for item, filename in items_files.items():
- ud = urldata[item]
- layer_name = layer_for_file(filename)
- ud_localpaths(ud, layer_name, dldir, data)
-
- recipe_layer_name = layer_for_file(recipe_filename)
- for extra_item in set(src_uri) - set(items_files.keys()):
- logger.warning('Unable to determine correct layer for `%s`: this item is missing from variable history', extra_item)
- ud = urldata[extra_item]
- ud_localpaths(ud, recipe_layer_name, dldir, data)
-
- return items_by_layer
-
- def _collect_fetch_recipes(self, targets, ctask, depgraph):
- tdepends = depgraph['tdepends']
- fetch_recipes = set()
- for target in targets:
- if ':' in target:
- recipe, task = target.split(':', 1)
- else:
- recipe, task = target, ctask
-
- if not task.startswith('do_'):
- task = 'do_' + task
-
- if task == 'do_fetch':
- fetch_recipes.add(recipe)
-
- for task, taskdeps in tdepends.items():
- for dep in taskdeps:
- deprecipe, deptask = dep.rsplit('.', 1)
- if deptask == 'do_fetch':
- fetch_recipes.add(deprecipe)
- return fetch_recipes
-
- def _gather_downloads(self, args):
- if args.task is None:
- args.task = self.tinfoil.config_data.getVar('BB_DEFAULT_TASK') or 'build'
- if not args.task.startswith('do_'):
- args.task = 'do_' + args.task
-
- depgraph, error = self._get_depgraph(args.targets, args.task)
- if not depgraph:
- if error:
- logger.critical('Failed to get the dependency graph: %s' % error)
- return 1
- else:
- logger.critical('Failed to get the dependency graph')
- return 1
-
- layer_data = depgraph['layer-priorities']
-
- def layer_for_file(filename):
- for name, pattern, re, priority in layer_data:
- if re.match(filename):
- return name
-
- fetch_recipes = self._collect_fetch_recipes(args.targets, args.task, depgraph)
-
- self.tinfoil.run_command('enableDataTracking')
-
- items_by_layer = defaultdict(set)
- for recipe in fetch_recipes:
- try:
- fn = depgraph['pn'][recipe]['filename']
- except KeyError:
- mc = self.tinfoil.config_data.getVar('BBMULTICONFIG')
- if not mc:
- raise Exception("Could not find key '%s' in depgraph and no multiconfigs defined" % recipe)
- for cfg in mc.split():
- try:
- nkey = f"mc:{cfg}:{recipe}"
- fn = depgraph['pn'][nkey]['filename']
- except KeyError:
- continue
- if not fn:
- raise Exception("Could not find recipe for '%s' in depgraph" % recipe)
-
- real_fn, cls, mc = bb.cache.virtualfn2realfn(fn)
- recipe_layer = layer_for_file(real_fn)
- appends = self.tinfoil.get_file_appends(fn)
- data = self.tinfoil.parse_recipe_file(fn, appendlist=appends)
-
- for layer, items in self._localpaths_by_layer(data, real_fn, lambda f: layer_for_file(f) or recipe_layer, args.mirrortarballs).items():
- items_by_layer[layer] |= items
-
- # If a given download is used by multiple layers, prefer the lowest
- # priority, i.e. associating it with oe-core vs some random layer
- seen = set()
- layer_priorities = {l: p for l, _, _, p in layer_data}
- for layer in sorted(layer_priorities, key=lambda i: layer_priorities[i]):
- for item in sorted(items_by_layer[layer]):
- if item not in seen:
- seen.add(item)
- yield layer, item
-
- def do_gather_downloads(self, args):
- """Gather up downloads for the specified targets, grouped by layer."""
- for layer, item in self._gather_downloads(args):
- print('%s\t%s' % (layer, item))
-
- def do_dump_downloads(self, args):
- """Dump downloads by layer into ${TMPDIR}/downloads-by-layer.txt."""
- items = self._gather_downloads(args)
- filename = self.tinfoil.config_data.expand(args.filename)
- omode = 'a' if args.append else 'w'
- with open(filename, omode) as f:
- for layer, item in items:
- f.write('%s\t%s\n' % (layer, item))
-
- def do_dump_licenses(self, args):
- """Dump licenses of all packages in the depgraph of a target into ${TMPDIR}/pn-buildlist-licenses.txt."""
- if args.task is None:
- args.task = self.tinfoil.config_data.getVar('BB_DEFAULT_TASK') or 'build'
- if not args.task.startswith('do_'):
- args.task = 'do_' + args.task
-
- filename = self.tinfoil.config_data.expand(args.filename)
-
- depgraph, error = self._get_depgraph(args.targets, args.task)
- if not depgraph:
- if error:
- logger.critical('Failed to get the dependency graph: %s' % error)
- return 1
- else:
- logger.critical('Failed to get the dependency graph')
- return 1
-
- fetch_recipes = self._collect_fetch_recipes(args.targets, args.task, depgraph)
-
- omode = 'a' if args.append else 'w'
- with open(filename, omode) as f:
- for recipe in fetch_recipes:
- try:
- fn = depgraph['pn'][recipe]['filename']
- except KeyError:
- mc = self.tinfoil.config_data.getVar('BBMULTICONFIG')
- if not mc:
- raise Exception("Could not find key '%s' in depgraph and no multiconfigs defined" % recipe)
- for cfg in mc.split():
- try:
- nkey = f"mc:{cfg}:{recipe}"
- fn = depgraph['pn'][nkey]['filename']
- except KeyError:
- continue
- if not fn:
- raise Exception("Could not find recipe for '%s' in depgraph" % recipe)
-
- real_fn, cls, mc = bb.cache.virtualfn2realfn(fn)
- appends = self.tinfoil.get_file_appends(fn)
- data = self.tinfoil.parse_recipe_file(fn, appendlist=appends)
-
- pn = data.getVar('PN')
- pv = data.getVar('PV')
- lc = data.getVar('LICENSE')
-
- if not args.sourceinfo:
- f.write('%s,%s,%s\n' % (pn, pv, lc))
- else:
- # unset su, otherwise we get previous value if there is no current
- su = ''
- for url in data.getVar('SRC_URI').split():
- scheme, host, path, user, passwd, param = bb.fetch.decodeurl(url)
- if scheme != 'file':
- su = bb.fetch.encodeurl((scheme, host, path, '', '', ''))
- hp = data.getVar('HOMEPAGE')
-
- f.write('%s,%s,%s,%s,%s\n' % (pn, pv, lc, su, hp))
-
- # remove any duplicates added due to append flag
- uniqlines = set(open(filename).readlines())
- with open(filename, 'w') as f:
- f.writelines(uniqlines)
-
- def register_commands(self, sp):
- common = argparse.ArgumentParser(add_help=False)
- common.add_argument('--mirrortarballs', '-m', help='show existing mirror tarball paths rather than git clone paths', action='store_true')
- common.add_argument('--task', '-c', help='specify the task to use when not expicitly specified for a target (default: BB_DEFAULT_TASK or "build")')
- common.add_argument('targets', nargs='+')
-
- gather = self.add_command(sp, 'gather-downloads', self.do_gather_downloads, parents=[common], parserecipes=True)
- dump = self.add_command(sp, 'dump-downloads', self.do_dump_downloads, parents=[common], parserecipes=True)
- dump.add_argument('--append', '-a', help='append to output filename', action='store_true')
- dump.add_argument('--filename', '-f', help='filename to dump to', default='${TMPDIR}/downloads-by-layer.txt')
- license = self.add_command(sp, 'dump-licenses', self.do_dump_licenses, parents=[common], parserecipes=True)
- license.add_argument('--filename', '-f', help='filename to dump to', default='${TMPDIR}/pn-buildlist-licenses.txt')
- license.add_argument('--append', '-a', help='append to output filename', action='store_true')
- license.add_argument('--sourceinfo', '-s', help='additionally dump SRC_URI and HOMEPAGE variables too', action='store_true')
diff --git a/meta-mel/lib/oeqa/selftest/cases/recipetool_mel.py b/meta-mel/lib/oeqa/selftest/cases/recipetool_mel.py
deleted file mode 100644
index 587ec90d..00000000
--- a/meta-mel/lib/oeqa/selftest/cases/recipetool_mel.py
+++ /dev/null
@@ -1,108 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-import os
-import logging
-import tempfile
-import urllib.parse
-
-from oeqa.utils.commands import runCmd, bitbake, get_bb_var, create_temp_layer
-from oeqa.utils.decorators import testcase
-from oeqa.selftest.cases import recipetool
-
-
-templayerdir = None
-
-
-def setUpModule():
- global templayerdir
- templayerdir = tempfile.mkdtemp(prefix='recipetool-mel-qa')
- create_temp_layer(templayerdir, 'selftest-recipetool-mel')
- runCmd('bitbake-layers add-layer %s' % templayerdir)
-
-
-def tearDownModule():
- runCmd('bitbake-layers remove-layer %s' % templayerdir, ignore_status=True)
- runCmd('rm -rf %s' % templayerdir)
-
-
-class RecipetoolMelTests(recipetool.RecipetoolAppendsrcBase):
- def setUpLocal(self):
- super(RecipetoolMelTests, self).setUpLocal()
- self.templayerdir = templayerdir
-
- def _test_kernel_cmd(self, cmd, target, expected_file_info):
- testrecipe = get_bb_var('PN', target)
- machine = get_bb_var('MACHINE')
- expectedfiles = [os.path.join(machine, i) for i in expected_file_info.keys()]
-
- bbappendfile, _ = self._try_recipetool_appendcmd(cmd, testrecipe, expectedfiles)
-
- src_uri = get_bb_var('SRC_URI', testrecipe).split()
- for f, destdir in expected_file_info.items():
- if destdir:
- self.assertIn('file://%s;subdir=%s' % (f, destdir), src_uri)
- else:
- self.assertIn('file://%s' % f, src_uri)
-
- filesdir = os.path.join(os.path.dirname(bbappendfile), testrecipe)
- filesextrapaths = get_bb_var('FILESEXTRAPATHS', testrecipe).split(':')
- self.assertIn(filesdir, filesextrapaths)
-
-
- # FIXME: the test files should end in .dts
- def test_kernel_add_dts(self):
- testrecipe = 'virtual/kernel'
- srcdir = get_bb_var('S', testrecipe)
- workdir = get_bb_var('WORKDIR', testrecipe)
- if srcdir == get_bb_var('STAGING_KERNEL_DIR', testrecipe):
- # If S is directly set to STAGING_KERNEL_DIR, then we most likely
- # have a custom checkout or unpack process like linux-yocto, so we
- # don't know precisely where to place the files relative to
- # WORKDIR. We default to 'git' in this case.
- subdir = 'git'
- else:
- subdir = os.path.relpath(srcdir, workdir)
- destdir = 'arch/\\${ARCH}/boot/dts'
- if subdir != '.':
- destdir = os.path.join(subdir, destdir)
-
- expected_file_info = {
- os.path.basename(self.testfile): destdir,
- 'testfile2': destdir,
- }
-
- testfile2 = os.path.join(self.tempdir, 'testfile2')
- with open(testfile2, 'w') as f:
- f.write('Test File 2')
-
- cmd = 'recipetool kernel_add_dts %s %s %s' % (self.templayerdir, self.testfile, testfile2)
- self._test_kernel_cmd(cmd, testrecipe, expected_file_info)
-
- devtree = get_bb_var('KERNEL_DEVICETREE', testrecipe)
- if not devtree:
- self.fail('KERNEL_DEVICETREE not defined')
- devtree = devtree.split()
-
- for f in expected_file_info:
- self.assertIn(f.replace('dts', 'dtb'), devtree)
-
- def test_kernel_add_fragments(self):
- fragments = []
- for i in range(1, 5):
- fn = os.path.join(self.tempdir, 'fragment%d.cfg' % i)
- fragments.append(fn)
- open(fn, 'w')
-
- cmd = 'recipetool kernel_add_fragments %s %s' % (self.templayerdir, ' '.join(fragments))
- self._test_kernel_cmd(cmd, 'virtual/kernel', dict((os.path.basename(i), None) for i in fragments))
-
- def test_kernel_set_configs(self):
- # TODO: check the generated fragment content
- cmd = 'recipetool kernel_set_configs %s CONFIG_ONE=y CONFIG_TWO=n' % self.templayerdir
- self._test_kernel_cmd(cmd, 'virtual/kernel', {'recipetool0.cfg': None})
-
- def test_kernel_set_defconfig(self):
- cmd = 'recipetool kernel_set_defconfig -r linux-dummy %s %s' % (self.templayerdir, self.testfile)
- self._test_kernel_cmd(cmd, 'linux-dummy', {'defconfig': None})
diff --git a/meta-mel/lib/recipetool/kernel.py b/meta-mel/lib/recipetool/kernel.py
deleted file mode 100644
index e530a326..00000000
--- a/meta-mel/lib/recipetool/kernel.py
+++ /dev/null
@@ -1,227 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Recipe creation tool - kernel plugin
-#
-# TODO: figure out how to get all the files added to a single SRC_URI +=
-# rather than multiple, while still getting the nice multi-line value
-# TODO: add support to oe.recipeutils to let us add include/require lines via
-# 'extralines', which is not currently supported. We could then
-# pull in linux-dtb.inc automatically if appropriate.
-#
-# These sub-commands are thin wrappers around appendsrcfile(s) coupled
-# with additional configuration variables.
-#
-# Examples:
-#
-# $ recipetool kernel_set_defconfig meta-mylayer /path/to/defconfig
-# $ recipetool kernel_add_fragments meta-mylayer one.cfg two.cfg
-# $ recipetool kernel_set_configs meta-mylayer CONFIG_LOCALVERSION_AUTO=n CONFIG_LOCALVERSION=-test
-# $ recipetool kernel_add_dts meta-mylayer *.dts
-#
-#
-# Copyright 2022 Siemens
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License version 2 as
-# published by the Free Software Foundation.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License along
-# with this program; if not, write to the Free Software Foundation, Inc.,
-# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
-
-import argparse
-import logging
-import os
-import re
-
-
-logger = logging.getLogger('recipetool')
-tinfoil = None
-
-
-def plugin_init(pluginlist):
- # Don't need to do anything here right now, but plugins must have this function defined
- pass
-
-
-def tinfoil_init(instance):
- global tinfoil
- tinfoil = instance
-
-
-def _get_recipe_file(cooker, pn):
- import oe.recipeutils
- best = cooker.findBestProvider(pn)
- recipefile = best[3]
- if not recipefile:
- skipreasons = oe.recipeutils.get_unavailable_reasons(cooker, pn)
- if skipreasons:
- logger.error('\n'.join(skipreasons))
- else:
- logger.error("Unable to find any recipe file matching %s" % pn)
- return recipefile
-
-
-def _parse_recipe(pn, tinfoil):
- recipefile = _get_recipe_file(tinfoil.cooker, pn)
- if not recipefile:
- # Error already logged
- return None
- return tinfoil.parse_recipe(pn)
-
-
-def append_srcfiles(destlayer, rd, files, use_workdir=False, use_machine=False, wildcard_version=False, extralines=None):
- import recipetool.append
-
- pn = rd.getVar('PN', True)
- if use_machine:
- machine = rd.getVar('MACHINE', True)
- else:
- machine = None
- appendargs = argparse.Namespace(destlayer=destlayer, recipe=pn, use_workdir=use_workdir, wildcard_version=wildcard_version, machine=machine)
- recipetool.append.appendsrc(appendargs, files, rd, extralines)
-
-
-def kernel_set_defconfig(args):
- rd = _parse_recipe(args.recipe, tinfoil)
- if not rd:
- return 1
-
- import bb.data
- if not bb.data.inherits_class('kernel-yocto', rd):
- extralines = []
- for configvar in ['KERNEL_DEFCONFIG', 'DEFCONFIG']:
- if rd.getVar(configvar, True):
- extralines.append('{0} = ${{WORKDIR}}/defconfig'.format(configvar))
- else:
- extralines = None
-
- return append_srcfiles(args.destlayer, rd, {args.defconfig: 'defconfig'}, use_workdir=True, use_machine=True, extralines=extralines)
-
-
-def kernel_add_dts(args):
- import oe.recipeutils
-
- rd = _parse_recipe(args.recipe, tinfoil)
- if not rd:
- return 1
-
- dtbs = (os.path.basename(dts.replace('dts', 'dtb')) for dts in args.dts_files)
- extralines = ['KERNEL_DEVICETREE += {0}'.format(' '.join(dtbs))]
- files = dict((dts, os.path.join('arch/${{ARCH}}/boot/dts/{0}'.format(os.path.basename(dts)))) for dts in args.dts_files)
- ret = append_srcfiles(args.destlayer, rd, files, use_workdir=False, use_machine=True, extralines=extralines)
-
- packages = rd.getVar('PACKAGES', True).split()
- if 'kernel-devicetree' not in packages:
- appendpath, _ = oe.recipeutils.get_bbappend_path(rd, args.destlayer, wildcardver=False)
- with open(appendpath, 'a') as f:
- f.write('require recipes-kernel/linux/linux-dtb.inc')
- return ret
-
-
-def kernel_add_fragments(args):
- rd = _parse_recipe(args.recipe, tinfoil)
- if not rd:
- return 1
-
- return _kernel_add_fragments(args.destlayer, rd, args.fragments)
-
-
-def _kernel_add_fragments(destlayer, rd, fragments, files=None, extralines=None):
- depends = rd.getVar('DEPENDS', True).split()
- md_depends = (rd.getVarFlag('do_kernel_metadata', 'depends', True) or '').split()
- depends.extend(dep.split(':', 1)[0] for dep in md_depends)
-
- if extralines is None:
- extralines = []
-
- if 'DELTA_KERNEL_DEFCONFIG' in rd:
- # linux-qoriq handles fragments itself
- extralines.append('DELTA_KERNEL_DEFCONFIG += {0}'.format(' '.join('${WORKDIR}/%s' % os.path.basename(f) for f in fragments)))
- else:
- if 'kern-tools-native' not in depends:
- logger.warn("kern-tools-native not found in the kernel's dependencies. This likely means that this kernel recipe ({0}) does not support configuration fragments.".format(rd.getVar('PN', True)))
-
- if files is None:
- files = dict((f, os.path.basename(f)) for f in fragments)
- return append_srcfiles(destlayer, rd, files, use_workdir=True, use_machine=True, extralines=extralines)
-
-
-def get_next_fragment_name(src_uri):
- fragpat = re.compile('file://recipetool([0-9]+)\.cfg$')
- matches = list(filter(None, [re.match(fragpat, u) for u in src_uri]))
- if matches:
- fragnums = sorted((int(m.group(1)) for m in matches), reverse=True)
- num = fragnums[0] + 1
- else:
- num = 0
- return 'recipetool%d' % num
-
-
-def kernel_set_configs(args):
- rd = _parse_recipe(args.recipe, tinfoil)
- if not rd:
- return 1
-
- if not args.name:
- src_uri = rd.getVar('SRC_URI', True).split()
- args.name = get_next_fragment_name(src_uri)
-
- import tempfile
- f = tempfile.NamedTemporaryFile(mode='w', delete=False)
- try:
- for cfgline in args.config_lines:
- f.write(cfgline + '\n')
- finally:
- f.close()
-
- fragfn = '{0}.cfg'.format(args.name)
- try:
- return _kernel_add_fragments(args.destlayer, rd, fragfn, files={f.name: fragfn})
- finally:
- os.unlink(f.name)
-
-
-def layer(layerpath):
- if not os.path.exists(os.path.join(layerpath, 'conf', 'layer.conf')):
- raise argparse.ArgumentTypeError('{0!r} must be a path to a valid layer'.format(layerpath))
- return layerpath
-
-
-def existing_path(filepath):
- if not os.path.exists(filepath):
- raise argparse.ArgumentTypeError('{0!r} must be an existing path'.format(filepath))
- return filepath
-
-
-def register_command(subparsers):
- common = argparse.ArgumentParser(add_help=False)
- common.add_argument('-r', '--recipe', help='Specify the kernel recipe to operate against (default: virtual/kernel)', default='virtual/kernel')
-
- parser = subparsers.add_parser('kernel_set_defconfig', help='Override the defconfig used for the kernel.', parents=[common])
- parser.add_argument('destlayer', metavar='DESTLAYER', help='Base directory of the destination layer to write the bbappend to', type=layer)
- parser.add_argument('defconfig', metavar='DEFCONFIG', help='File path to the defconfig to be used', type=existing_path)
- parser.set_defaults(func=kernel_set_defconfig, parserecipes=True)
-
- parser = subparsers.add_parser('kernel_add_dts', help='Add/replace device tree files in the kernel.', parents=[common])
- parser.add_argument('destlayer', metavar='DESTLAYER', help='Base directory of the destination layer to write the bbappend to', type=layer)
- parser.add_argument('dts_files', metavar='DTS_FILE', nargs='+', help='File path to a .dts', type=existing_path)
- parser.set_defaults(func=kernel_add_dts, parserecipes=True)
-
- parser = subparsers.add_parser('kernel_add_fragments', help='Add configuration fragments to the kernel.', parents=[common])
- parser.add_argument('destlayer', metavar='DESTLAYER', help='Base directory of the destination layer to write the bbappend to', type=layer)
- parser.add_argument('fragments', metavar='FRAGMENT', nargs='+', help='File path to a configuration fragment (.cfg)', type=existing_path)
- parser.set_defaults(func=kernel_add_fragments, parserecipes=True)
-
- parser = subparsers.add_parser('kernel_set_configs', help='Set kernel configuration parameters. Generates and includes kernel config fragments for you.', parents=[common])
- parser.add_argument('-n', '--name', metavar='NAME', help='Name of the fragment to be generated (without .cfg)')
- parser.add_argument('destlayer', metavar='DESTLAYER', help='Base directory of the destination layer to write the bbappend to', type=layer)
- parser.add_argument('config_lines', metavar='CONFIG_LINE', nargs='+', help='Kernel configuration line (e.g. CONFIG_FOO=y)')
- parser.set_defaults(func=kernel_set_configs, parserecipes=True)
diff --git a/meta-mel/mel-support/recipes-core/meta/archive-release.bbappend b/meta-mel/mel-support/recipes-core/meta/archive-release.bbappend
deleted file mode 100644
index f94b2de7..00000000
--- a/meta-mel/mel-support/recipes-core/meta/archive-release.bbappend
+++ /dev/null
@@ -1,463 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:append = ":${@':'.join('%s/../scripts/release:%s/../scripts' % (l, l) for l in '${BBPATH}'.split(':'))}"
-MEL_SCRIPTS_FILES = "mel-checkout version-sort setup-mel setup-workspace setup-ubuntu setup-rh setup-debian"
-SRC_URI += "${@' '.join(uninative_urls(d)) if 'mel_downloads' in '${RELEASE_ARTIFACTS}'.split() else ''}"
-SRC_URI += "${@' '.join('file://%s' % s for s in d.getVar('MEL_SCRIPTS_FILES').split())}"
-
-inherit layerdirs
-
-ARCHIVE_RELEASE_VERSION ?= "${DISTRO_VERSION}"
-SCRIPTS_VERSION ?= "1"
-MANIFEST_NAME ?= "${DISTRO}-${ARCHIVE_RELEASE_VERSION}-${MACHINE}"
-EXTRA_MANIFEST_NAME ?= "${DISTRO}-${ARCHIVE_RELEASE_VERSION}"
-SCRIPTS_ARTIFACT_NAME ?= "${DISTRO}-scripts-${DISTRO_VERSION}.${SCRIPTS_VERSION}"
-BSPFILES_INSTALL_PATH = "${MACHINE}/${ARCHIVE_RELEASE_VERSION}"
-GET_REMOTES_HOOK ?= ""
-
-# Layers which get their own extra manifests, rather than being included in
-# the main one. How they're combined or shipped from there is up to our
-# release scripts.
-INDIVIDUAL_MANIFEST_LAYERS ?= ""
-FORKED_REPOS ?= ""
-PUBLIC_REPOS ?= "${FORKED_REPOS}"
-
-# Define a location for placing external artifacts to be used by the build
-MEL_EXTERNAL_ARTIFACTS ?= "${TOPDIR}/mel-external-artifacts"
-
-RELEASE_EXCLUDED_LAYERNAMES ?= "workspacelayer"
-
-ARCHIVE_RELEASE_DL_DIR ?= "${DL_DIR}"
-ARCHIVE_RELEASE_DL_BY_LAYER_PATH = '${TMPDIR}/downloads-by-layer.txt'
-
-def mel_get_remotes(subdir, d):
- """Any non-public github repo or url including a mentor domain
- are considered private, so no remote is included.
- """
- try:
- url = bb.process.run(['git', 'config', 'remote.origin.url'], cwd=subdir)[0].rstrip()
- except bb.process.ExecutionError:
- return None
- else:
- if not url:
- return None
-
- remotes = {}
- test_url = url.replace('.git', '')
- public_repos = d.getVar('PUBLIC_REPOS').split()
- if 'MentorEmbedded' in test_url:
- if not any(test_url.endswith('/' + i) for i in public_repos):
- # Private github repo
- return None
- else:
- # For the public layers, we want the user to be able to fetch
- # anonymously, not just with ssh
- url = url.replace('ssh://git@', 'https://')
-
- forked_repos = d.getVar('FORKED_REPOS').split()
- for f in forked_repos:
- if test_url.endswith('/' + f):
- upstream = d.getVar('UPSTREAM_URL_%s' % f)
- if upstream:
- remotes['upstream'] = upstream
- break
- elif 'mentor.com' in test_url or 'mentorg.com' in test_url:
- # Internal repo
- return None
-
- remotes['origin'] = url
- return remotes
-
-GET_REMOTES_HOOK:mel ?= "mel_get_remotes"
-
-GIT_ROOT_TOO_FAR_PATHS = "${OEDIR} ${TOPDIR} ${HOME}"
-
-def layer_git_root(subdir, too_far_paths):
- try:
- git_root = bb.process.run(['git', 'rev-parse', '--show-toplevel'], cwd=subdir)[0].rstrip()
- except bb.process.CmdError:
- return None
-
- too_far_under_root = any(too_far_path.startswith(git_root + os.sep) for too_far_path in too_far_paths)
- if git_root in too_far_paths or too_far_under_root:
- return None
-
- return git_root
-
-def get_release_info(layerdir, layername, topdir, oedir, too_far_paths, indiv_only=None, indiv_only_toplevel=None, indiv_manifests=None):
- import collections
- import fnmatch
-
- if indiv_only is None:
- indiv_only = set()
- if indiv_only_toplevel is None:
- indiv_only_toplevel = set()
- if indiv_manifests is None:
- indiv_manifests = []
-
- relpath = None
- if layerdir not in indiv_only:
- git_root = layer_git_root(layerdir, too_far_paths)
- if git_root:
- return git_root, os.path.basename(git_root), False
-
- if layername and any(fnmatch.fnmatchcase(layername, pat) for pat in indiv_manifests):
- indiv_layer = True
- else:
- indiv_layer = False
-
- if (layerdir not in indiv_only_toplevel and
- not layerdir.startswith(topdir + os.sep) and
- layerdir.startswith(oedir + os.sep)):
- return layerdir, os.path.relpath(layerdir, oedir), indiv_layer
- else:
- return layerdir, os.path.basename(layerdir), indiv_layer
-
-python do_archive_mel_layers () {
- """Archive the layers used to build, as git pack files, with a manifest."""
- import collections
- import configparser
- import oe.reproducible
-
- if 'layerdirs' not in d.getVar('INHERIT').split():
- save_layerdirs(d)
-
- directories = d.getVar('BBLAYERS').split()
- bitbake_path = bb.utils.which(d.getVar('PATH'), 'bitbake')
- bitbake_bindir = os.path.dirname(bitbake_path)
- directories.append(os.path.dirname(bitbake_bindir))
-
- corebase = os.path.realpath(d.getVar('COREBASE'))
- oedir = os.path.dirname(corebase)
- topdir = os.path.realpath(d.getVar('TOPDIR'))
- indiv_only_toplevel = d.getVar('SUBLAYERS_INDIVIDUAL_ONLY_TOPLEVEL').split()
- indiv_only = d.getVar('SUBLAYERS_INDIVIDUAL_ONLY').split() + indiv_only_toplevel
- indiv_manifests = d.getVar('INDIVIDUAL_MANIFEST_LAYERS').split()
- excluded_layers = d.getVar('RELEASE_EXCLUDED_LAYERNAMES').split()
- too_far_paths = d.getVar('GIT_ROOT_TOO_FAR_PATHS').split()
- get_remotes_hook = d.getVar('GET_REMOTES_HOOK')
- if get_remotes_hook:
- get_remotes = bb.utils.get_context().get(get_remotes_hook)
- if not get_remotes:
- bb.fatal('Hook function specified in GET_REMOTES_HOOK (`%s`) does not exist' % get_remotes_hook)
- else:
- get_remotes = None
-
- layernames = {}
- for layername in d.getVar('BBFILE_COLLECTIONS').split():
- layerdir = d.getVar('LAYERDIR_%s' % layername)
- if layerdir:
- layernames[layerdir] = layername
-
- git_indivs = collections.defaultdict(set)
- to_archive, indiv_manifest_dirs = set(), set()
- path = d.getVar('PATH') + ':' + ':'.join(os.path.join(l, '..', 'scripts') for l in directories)
- for subdir in directories:
- subdir = os.path.realpath(subdir)
- layername = layernames.get(subdir)
- if layername in excluded_layers:
- bb.note('Skipping excluded layer %s' % layername)
- continue
-
- parent = os.path.dirname(subdir)
- git_root = layer_git_root(subdir, too_far_paths)
- if subdir in indiv_only and git_root:
- git_indivs[git_root].add(os.path.relpath(subdir, git_root))
- if layername and any(fnmatch.fnmatchcase(layername, pat) for pat in indiv_manifests):
- indiv_manifest_dirs.add(subdir)
- else:
- archive_path, dest_path, is_indiv = get_release_info(subdir, layername, topdir, oedir, too_far_paths, indiv_only=indiv_only, indiv_only_toplevel=indiv_only_toplevel, indiv_manifests=indiv_manifests)
- to_archive.add((archive_path, dest_path, None))
- if is_indiv:
- indiv_manifest_dirs.add(subdir)
-
- for parent, keep_files in git_indivs.items():
- to_archive.add((parent, os.path.basename(parent), tuple(keep_files)))
-
- outdir = d.expand('${S}/do_archive_mel_layers')
- mandir = os.path.join(outdir, 'manifests')
- bb.utils.mkdirhier(mandir)
- bb.utils.mkdirhier(os.path.join(mandir, 'extra'))
- objdir = os.path.join(outdir, 'git-bundles')
- bb.utils.mkdirhier(objdir)
- manifestfn = d.expand('%s/${MANIFEST_NAME}.manifest' % mandir)
- manifests = [manifestfn]
- message = '%s %s' % (d.getVar('DISTRO_NAME') or d.getVar('DISTRO'), d.getVar('DISTRO_VERSION'))
-
- l = d.createCopy()
- l.setVar('SRC_URI', 'git://')
- l.setVar('WORKDIR', '/invalid')
-
- manifestdata = collections.defaultdict(list)
- for subdir, path, keep_paths in sorted(to_archive):
- parent = None
- if os.path.exists(os.path.join(subdir, '.git')):
- parent = subdir
- else:
- try:
- git_topdir = bb.process.run(['git', 'rev-parse', '--show-toplevel'], cwd=subdir)[0].rstrip()
- except bb.process.CmdError:
- pass
- else:
- if git_topdir != subdir:
- subdir_relpath = os.path.relpath(subdir, git_topdir)
- try:
- ls = bb.process.run(['git', 'ls-tree', '-d', 'HEAD', subdir_relpath], cwd=subdir)
- except bb.process.CmdError as exc:
- pass
- else:
- if ls:
- parent = git_topdir
-
- if not parent:
- bb.fatal('Unable to archive non-git directory: %s' % subdir)
-
- l.setVar('S', subdir)
- source_date_epoch = oe.reproducible.get_source_date_epoch(l, parent or subdir)
-
- if get_remotes:
- remotes = get_remotes(subdir, d) or {}
- else:
- remotes = {}
- pack_base, head = git_archive(subdir, objdir, message, keep_paths, remotes)
-
- if not remotes:
- bb.note('Skipping remotes for %s' % path)
-
- head = git_archive(subdir, objdir, parent, message, keep_paths, source_date_epoch, is_public=bool(remotes))
-
- if subdir in indiv_manifest_dirs:
- name = path.replace('/', '_')
- bb.utils.mkdirhier(os.path.join(mandir, 'extra', name))
- fn = d.expand('%s/extra/%s/${EXTRA_MANIFEST_NAME}-%s.manifest' % (mandir, name, name))
- else:
- fn = manifestfn
- manifestdata[fn].append('\t'.join([path, head] + ['%s=%s' % (k,v) for k,v in remotes.items()]) + '\n')
- bb.process.run(['tar', '-cf', '%s.tar' % head, 'git-bundles/%s.bundle' % head], cwd=outdir)
- os.unlink(os.path.join(objdir, '%s.bundle' % head))
-
- os.rmdir(objdir)
-
- infofn = d.expand('%s/${MANIFEST_NAME}.info' % mandir)
- with open(infofn, 'w') as infofile:
- c = configparser.ConfigParser()
- c['DEFAULT'] = {'bspfiles_path': d.getVar('BSPFILES_INSTALL_PATH')}
- c.write(infofile)
-
- for fn, lines in manifestdata.items():
- with open(fn, 'w') as manifest:
- manifest.writelines(lines)
- files = [os.path.relpath(fn, outdir)]
- if fn == manifestfn:
- files.append(os.path.relpath(infofn, outdir))
- bb.process.run(['tar', '-cf', os.path.basename(fn) + '.tar'] + files, cwd=outdir)
-
- scripts = d.getVar('MEL_SCRIPTS_FILES').split()
- bb.process.run(['tar', '--transform=s,^,scripts/,', '--transform=s,^scripts/setup-mel,setup-mel,', '-cvf', d.expand('%s/${SCRIPTS_ARTIFACT_NAME}.tar' % outdir)] + scripts, cwd=d.getVar('WORKDIR'))
-}
-do_archive_mel_layers[dirs] = "${S}/do_archive_mel_layers ${S}"
-do_archive_mel_layers[vardeps] += "${GET_REMOTES_HOOK}"
-# We make use of the distro version, so want to avoid changing checksum issues
-# for snapshot builds.
-do_archive_mel_layers[vardepsexclude] += "DATE TIME"
-addtask archive_mel_layers after do_patch
-
-def git_archive(subdir, outdir, parent, message=None, keep_paths=None, source_date_epoch=None, is_public=False):
- """Create an archive for the specified subdir, holding a single git object
-
- 1. Clone or create the repo to a temporary location
- 2. Filter out paths not in keep_paths, if set
- 3. Make the repo shallow
- 4. Repack the repo into a single git pack
- 5. Copy the pack files to outdir
- """
- import glob
- import tempfile
-
- parent_git = os.path.join(parent, bb.process.run(['git', 'rev-parse', '--git-dir'], cwd=subdir)[0].rstrip())
- # Handle git worktrees
- _commondir = os.path.join(parent_git, 'commondir')
- if os.path.exists(_commondir):
- with open(_commondir, 'r') as f:
- parent_git = os.path.join(parent_git, f.read().rstrip())
-
- parent_head = bb.process.run(['git', 'rev-parse', 'HEAD'], cwd=subdir)[0].rstrip()
-
- with tempfile.TemporaryDirectory() as tmpdir:
- gitcmd = ['git', '--git-dir', tmpdir, '--work-tree', subdir]
- bb.process.run(gitcmd + ['init'])
-
- with open(os.path.join(tmpdir, 'objects', 'info', 'alternates'), 'w') as f:
- f.write(os.path.join(parent_git, 'objects') + '\n')
-
- if is_public and not keep_paths:
- head = parent_head
- else:
- bb.process.run(gitcmd + ['read-tree', parent_head])
-
- if message is None:
- message = 'Release of %s' % os.path.basename(subdir)
- commitcmd = ['commit-tree', '-m', message]
- commitcmd.extend(['-p', parent_head])
-
- bb.process.run(gitcmd + ['add', '-A', '.'], cwd=subdir)
- if keep_paths:
- files = bb.process.run(gitcmd + ['ls-tree', '-r', '--name-only', parent_head])[0].splitlines()
- kill_files = [f for f in files if f not in keep_paths and not any(f.startswith(p + '/') for p in keep_paths)]
- keep_files = set(files) - set(kill_files)
- if not keep_files:
- bb.fatal('No files kept for %s' % parent)
-
- bb.process.run(gitcmd + ['update-index', '--force-remove', '--'] + kill_files, cwd=subdir)
-
- tree = bb.process.run(gitcmd + ['write-tree'])[0].rstrip()
- commitcmd.append(tree)
-
- env = {
- 'GIT_AUTHOR_NAME': 'Build User',
- 'GIT_AUTHOR_EMAIL': 'build_user@build_host',
- 'GIT_COMMITTER_NAME': 'Build User',
- 'GIT_COMMITTER_EMAIL': 'build_user@build_host',
- }
- if source_date_epoch:
- env['GIT_AUTHOR_DATE'] = str(source_date_epoch)
- env['GIT_COMMITTER_DATE'] = str(source_date_epoch)
-
- head = bb.process.run(gitcmd + commitcmd, env=env)[0].rstrip()
-
- if not is_public:
- with open(os.path.join(tmpdir, 'shallow'), 'w') as f:
- f.write(head + '\n')
-
- # We need a ref to ensure repack includes the new commit, as it
- # does not include dangling objects in the pack.
- bb.process.run(['git', 'update-ref', 'refs/packing', head], cwd=tmpdir)
- bb.process.run(['git', 'prune', '--expire=now'], cwd=tmpdir)
- bb.process.run(['git', 'repack', '-a', '-d'], cwd=tmpdir)
- bb.process.run(['git', 'prune-packed'], cwd=tmpdir)
-
- bb.process.run(['git', 'bundle', 'create', os.path.join(outdir, '%s.bundle' % head), 'refs/packing'], cwd=tmpdir)
- return head
-
-def checksummed_downloads(dl_by_layer_fn, dl_by_layer_dl_dir, dl_dir):
- with open(dl_by_layer_fn, 'r') as f:
- lines = f.readlines()
-
- for layer_name, dl_path in (l.rstrip('\n').split('\t', 1) for l in lines):
- rel_path = os.path.relpath(dl_path, dl_by_layer_dl_dir)
- if rel_path.startswith('..'):
- bb.fatal('Download %s (in %s) is not relative to DL_DIR' % (dl_path, dl_by_layer_fn))
-
- dl_path = os.path.join(dl_dir, rel_path)
- if not os.path.exists(dl_path):
- # download is missing, probably excluded for license reasons
- bb.warn('Download %s does not exist, excluding' % dl_path)
- continue
-
- checksum = chksum_dl(dl_path)
- yield layer_name, dl_path, rel_path, checksum
-
-def uninative_downloads(workdir, dldir):
- for path in oe.path.find(os.path.join(workdir, 'uninative')):
- relpath = os.path.relpath(path, workdir)
- dlpath = os.path.join(dldir, relpath)
- checksum = chksum_dl(path, dlpath)
- yield None, path, relpath, checksum
-
-def chksum_dl(path, dlpath=None):
- import pickle
-
- if dlpath is None:
- dlpath = path
-
- donefile = dlpath + '.done'
- checksum = None
- if os.path.exists(donefile):
- with open(donefile, 'rb') as cachefile:
- try:
- checksums = pickle.load(cachefile)
- except EOFError:
- pass
- else:
- checksum = checksums['sha256']
-
- if not checksum:
- checksum = bb.utils.sha256_file(path)
-
- return checksum
-
-python do_archive_mel_downloads () {
- import collections
- import pickle
- import oe.path
-
- dl_dir = d.getVar('DL_DIR')
- archive_dl_dir = d.getVar('ARCHIVE_RELEASE_DL_DIR') or dl_dir
- dl_by_layer_fn = d.getVar('ARCHIVE_RELEASE_DL_BY_LAYER_PATH')
- if not os.path.exists(dl_by_layer_fn):
- bb.fatal('%s does not exist, but mel_downloads requires it. Please run `bitbake-layers dump-downloads` with appropriate arguments.' % dl_by_layer_fn)
-
- downloads = list(checksummed_downloads(dl_by_layer_fn, dl_dir, archive_dl_dir))
- downloads.extend(sorted(uninative_downloads(d.getVar('WORKDIR'), d.getVar('DL_DIR'))))
- outdir = d.expand('${S}/do_archive_mel_downloads')
- mandir = os.path.join(outdir, 'manifests')
- dldir = os.path.join(outdir, 'downloads')
- bb.utils.mkdirhier(mandir)
- bb.utils.mkdirhier(os.path.join(mandir, 'extra'))
- bb.utils.mkdirhier(dldir)
-
- layer_manifests = {}
- corebase = os.path.realpath(d.getVar('COREBASE'))
- oedir = os.path.dirname(corebase)
- topdir = os.path.realpath(d.getVar('TOPDIR'))
- indiv_only_toplevel = d.getVar('SUBLAYERS_INDIVIDUAL_ONLY_TOPLEVEL').split()
- indiv_only = d.getVar('SUBLAYERS_INDIVIDUAL_ONLY').split() + indiv_only_toplevel
- indiv_manifests = d.getVar('INDIVIDUAL_MANIFEST_LAYERS').split()
- too_far_paths = d.getVar('GIT_ROOT_TOO_FAR_PATHS').split()
-
- layers = set(i[0] for i in downloads)
- for layername in layers:
- if not layername:
- continue
-
- layerdir = d.getVar('LAYERDIR_%s' % layername)
- archive_path, dest_path, is_indiv = get_release_info(layerdir, layername, topdir, oedir, too_far_paths, indiv_only=indiv_only, indiv_only_toplevel=indiv_only_toplevel, indiv_manifests=indiv_manifests)
- if is_indiv:
- extra_name = dest_path.replace('/', '_')
- bb.utils.mkdirhier(os.path.join(mandir, 'extra', extra_name))
- manifestfn = d.expand('%s/extra/%s/${EXTRA_MANIFEST_NAME}-%s.downloads' % (mandir, extra_name, extra_name))
- layer_manifests[layername] = manifestfn
-
- main_manifest = d.expand('%s/${MANIFEST_NAME}.downloads' % mandir)
- manifests = collections.defaultdict(list)
- for layername, path, dest_path, checksum in downloads:
- manifestfn = layer_manifests.get(layername) or main_manifest
- manifests[manifestfn].append((layername, path, dest_path, checksum))
-
- for manifest, manifest_downloads in manifests.items():
- with open(manifest, 'w') as f:
- for _, _, download_path, checksum in manifest_downloads:
- f.write('%s\t%s\n' % (download_path, checksum))
-
- bb.process.run(['tar', '-cf', os.path.basename(manifest) + '.tar', os.path.relpath(manifest, outdir)], cwd=outdir)
-
- for name, path, dest_path, checksum in manifest_downloads:
- dest = os.path.join(dldir, checksum)
- oe.path.symlink(path, dest, force=True)
- bb.process.run(['tar', '-chf', '%s/download-%s.tar' % (dldir, checksum), os.path.relpath(dest, outdir)], cwd=outdir)
- os.unlink(dest)
-}
-do_archive_mel_downloads[depends] += "${@'${RELEASE_IMAGE}:${FETCHALL_TASK}' if '${RELEASE_IMAGE}' else ''}"
-
-archive_uninative_downloads () {
- # Ensure that uninative downloads are in ARCHIVE_RELEASE_DL_DIR, since
- # they're listed in the manifest
- find uninative -type f | while read -r fn; do
- mkdir -p "${ARCHIVE_RELEASE_DL_DIR}/$(dirname "$fn")"
- ln -sf "${DL_DIR}/$fn" "${ARCHIVE_RELEASE_DL_DIR}/$fn"
- done
-}
-archive_uninative_downloads[dirs] = "${WORKDIR}"
-do_archive_mel_downloads[prefuncs] += "archive_uninative_downloads"
diff --git a/meta-mel/meta-python/recipes-devtools/python/python3-unidiff_%.bbappend b/meta-mel/meta-python/recipes-devtools/python/python3-unidiff_%.bbappend
deleted file mode 100644
index 7c4e9f67..00000000
--- a/meta-mel/meta-python/recipes-devtools/python/python3-unidiff_%.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-BBCLASSEXTEND += "native"
diff --git a/meta-mel/openembedded-layer/recipes-connectivity/libwebsockets/libwebsockets_4.2.2.bbappend b/meta-mel/openembedded-layer/recipes-connectivity/libwebsockets/libwebsockets_4.2.2.bbappend
deleted file mode 100644
index 7742468a..00000000
--- a/meta-mel/openembedded-layer/recipes-connectivity/libwebsockets/libwebsockets_4.2.2.bbappend
+++ /dev/null
@@ -1,2 +0,0 @@
-SRCREV:mel = "7e4482075d30bd276c66b9f8daa1f9b8871c8743"
-SRC_URI:mel = "git://github.com/MentorEmbedded/libwebsockets.git;protocol=https;branch=v4.2-stable"
diff --git a/meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init.bb b/meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init.bb
deleted file mode 100644
index 05b3970e..00000000
--- a/meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init.bb
+++ /dev/null
@@ -1,30 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SUMMARY = "MEL DM-Crypt Image initramfs init"
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://${COREBASE}/meta/COPYING.MIT;md5=3da9cfbcb788c80a0384361b4de20420"
-
-DEPENDS = "virtual/kernel"
-RDEPENDS:${PN} += "cryptsetup"
-RDEPENDS:${PN} += "lvm2"
-RDEPENDS:${PN} += "lvm2-udevrules"
-RDEPENDS:${PN} += "udev"
-
-PR = "r0"
-
-SRC_URI = "file://init.sh"
-
-S = "${WORKDIR}"
-
-do_install() {
- install -m 0755 ${WORKDIR}/init.sh ${D}/init
- install -d ${D}/dev
- mknod -m 622 ${D}/dev/console c 5 1
-}
-
-FILES:${PN} += "/init /dev"
-
-# Due to kernel dependency
-PACKAGE_ARCH = "${MACHINE_ARCH}"
diff --git a/meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init/init.sh b/meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init/init.sh
deleted file mode 100644
index 1807ec7b..00000000
--- a/meta-mel/openembedded-layer/recipes-core/initrdscripts/dmcrypt-initramfs-init/init.sh
+++ /dev/null
@@ -1,196 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-PATH=/sbin:/bin:/usr/sbin:/usr/bin
-CONSOLE="/dev/console"
-
-TARGET_ROOT_MOUNT="/target_rootfs"
-
-# LUKS-enabled devices
-TARGET_ROOTFS_NAME="rootfs"
-TARGET_LOGFS_NAME="logfs"
-TARGET_ROOTFS_DEVICE="/dev/mapper/${TARGET_ROOTFS_NAME}"
-
-LOG_FILE="${TARGET_BOOT_MOUNT}/boot.log"
-
-# log <error-level> <msg>
-function log {
- if [ "$#" -ne "2" ]; then
- echo "${FUNCNAME} <error-level> <msg>"
- fi
-
- local level="$1";
- local msg="$2";
-
- date=`date`;
-
- if [ -n "${SYSTEMD_ENV}" ] && [ "${SYSTEMD_ENV}" -eq "1" ]; then
- echo -e "${level} ${msg}"
- else
- echo -e "# ${date} ${level} ${msg}"
- fi
-
- echo "# ${date} ${level} ${msg}" >> ${LOG_FILE}
-
- if [ "${level}" == "error" ]; then
- local frame=0
- local stacktrace="";
-
- while true; do
- stacktrace+=`caller $frame`
- if [ "$?" -ne 0 ]; then
- break
- fi
-
- _ret=$?
- stacktrace+=$'\n'
- ((frame++));
- done
-
- stacktrace=`echo ${stacktrace} |cut -f1-2 -d' ' |tr ' ' ':'`
-
- echo "Stacktrace: "
- echo "${stacktrace}"
- echo "Stacktrace: " >> ${LOG_FILE}
- echo "${stacktrace}" >> ${LOG_FILE}
- fi;
-}
-
-udev_daemon() {
- OPTIONS="/sbin/udev/udevd /sbin/udevd /lib/udev/udevd /lib/systemd/systemd-udevd"
-
- for o in $OPTIONS; do
- if [ -x "$o" ]; then
- echo $o
- return 0
- fi
- done
-
- return 1
-}
-
-_UDEV_DAEMON=`udev_daemon`
-
-
-early_setup() {
- mkdir -p /proc
- mkdir -p /sys
- mount -t proc proc /proc
- mount -t sysfs sysfs /sys
- mount -n -o mode=0755 -t devtmpfs none /dev
-
-
- mkdir -p /run
- mkdir -p /var/run
- $_UDEV_DAEMON --daemon
- udevadm trigger --action=add
- udevadm settle --timeout=3
- return 0
-}
-
-read_args() {
- for arg in $CMDLINE; do
- optarg=`expr "x$arg" : 'x[^=]*=\(.*\)'`
- case $arg in
- LABEL=*)
- label=$optarg
- ;;
- ROOT_PART=*)
- ROOT_PART=$optarg
- ;;
- esac
- done
-}
-
-do_boot() {
- echo "Boot procedure ..."
-
- if [ -z "${ROOT_PART}" ]; then
- log "error" "ROOT_PART not set"
- return 1
- fi
-
- # rootfs
- sleep 4s
- echo -ne "\n\n Open Encrypted root filesystem...\n"
- cmd="cryptsetup -v open ${ROOT_PART} ${TARGET_ROOTFS_NAME}"
- output=`eval ${cmd}`
- ret=$?
- if [ ${ret} -ne 0 ]; then
- log "error" "failed to open LUKS device ${ROOT_PART} as ${TARGET_ROOTFS_NAME}"
- log "error" "${cmd} (${ret}): ${output}"
- return 1
- fi;
-
- # TODO check filesystems
-
- # Watches the udev event queue, and exits if all current events are handled
- udevadm settle --timeout=3
- killall "${_UDEV_DAEMON##*/}" 2>/dev/null
-
- cmd="mkdir -p ${TARGET_ROOT_MOUNT}"
- output=`eval ${cmd}`
- ret=$?
- if [ ${ret} -ne 0 ]; then
- log "error" "${cmd} (${ret}): ${output}"
- return 1
- fi;
-
- cmd="mount -t ext4 ${TARGET_ROOTFS_DEVICE} ${TARGET_ROOT_MOUNT}"
- output=`eval ${cmd}`
- ret=$?
- if [ ${ret} -ne 0 ]; then
- log "error" "${cmd} (${ret}): ${output}"
- return 1
- fi;
-
- cd ${TARGET_ROOT_MOUNT}
- exec switch_root ${TARGET_ROOT_MOUNT} /sbin/init $CMDLINE
-}
-
-do_console() {
- echo "Starting console ..."
-
- # get name of active terminal
- CONSOLE=`cat /sys/devices/virtual/tty/console/active | cut -d " " -f2`
-
- # run shell on active terminal
- setsid sh -c "exec sh </dev/$CONSOLE >/dev/$CONSOLE 2>&1"
-}
-
-# Main
-
-early_setup
-if [ "$?" -ne "0" ]; then
- log "error" "early_setup failed"
- do_console
-fi;
-
-if [ $# -ne 0 ]; then
- CMDLINE="$@"
-else
- CMDLINE=`cat /proc/cmdline`
-fi;
-
-read_args
-case $label in
- boot)
- do_boot
- if [ "$?" -ne "0" ]; then
- log "error" "boot failed, rebooting in 10 sec"
- sleep 10
- reboot -f
- fi;
- ;;
-
- console)
- do_console
- ;;
- *)
- echo "Unrecognized option ${label}"
- ;;
-
-esac
diff --git a/meta-mel/openembedded-layer/recipes-support/lvm2/lvm2/lvm2-mel.service b/meta-mel/openembedded-layer/recipes-support/lvm2/lvm2/lvm2-mel.service
deleted file mode 100644
index 3977aa09..00000000
--- a/meta-mel/openembedded-layer/recipes-support/lvm2/lvm2/lvm2-mel.service
+++ /dev/null
@@ -1,15 +0,0 @@
-[Unit]
-Description=Linux Volume Manager
-DefaultDependencies=no
-Before=fsck-root.service local-fs.target
-After=udev.service
-
-[Service]
-Type=oneshot
-RemainAfterExit=yes
-ExecStart=/usr/sbin/vgmknodes --refresh
-ExecStop=/usr/sbin/pvchange -an
-ExecStop=/usr/sbin/vgchange -an
-
-[Install]
-WantedBy=sysinit.target
diff --git a/meta-mel/openembedded-layer/recipes-support/lvm2/lvm2_%.bbappend b/meta-mel/openembedded-layer/recipes-support/lvm2/lvm2_%.bbappend
deleted file mode 100644
index 1505103d..00000000
--- a/meta-mel/openembedded-layer/recipes-support/lvm2/lvm2_%.bbappend
+++ /dev/null
@@ -1,19 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
-
-SRC_URI:append = " file://lvm2-mel.service"
-
-PACKAGES += "${PN}-mel"
-SYSTEMD_PACKAGES += "${PN}-mel"
-SYSTEMD_SERVICE:${PN}-mel = "lvm2-mel.service"
-SYSTEMD_AUTO_ENABLE:${PN}-mel = "enable"
-RDEPENDS:${PN} += "${PN}-mel"
-
-do_install:append() {
- if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
- install -m 0644 ${WORKDIR}/${SYSTEMD_SERVICE:${PN}-mel} ${D}${systemd_system_unitdir}/
- fi
-}
diff --git a/meta-mel/recipes-connectivity/connman/connman_%.bbappend b/meta-mel/recipes-connectivity/connman/connman_%.bbappend
deleted file mode 100644
index aabe2b72..00000000
--- a/meta-mel/recipes-connectivity/connman/connman_%.bbappend
+++ /dev/null
@@ -1,9 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# do not use connman as a DNS proxy because both dnsmasq and connman try to
-# bind to same port 53.
-do_install:append:mel () {
- sed -i '/^ExecStart=/ s@-n@--nodnsproxy -n@g' ${D}${systemd_unitdir}/system/connman.service
-}
diff --git a/meta-mel/recipes-core/base-files/base-files_3.0.14.bbappend b/meta-mel/recipes-core/base-files/base-files_3.0.14.bbappend
deleted file mode 100644
index 67e358bd..00000000
--- a/meta-mel/recipes-core/base-files/base-files_3.0.14.bbappend
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}:"
-
-dirs755:append:mel = "\
- ${sysconfdir}/alternatives \
- ${localstatedir}/lib/alternatives \
-"
diff --git a/meta-mel/recipes-core/base-files/mel/issue b/meta-mel/recipes-core/base-files/mel/issue
deleted file mode 100644
index 568cdd1e..00000000
--- a/meta-mel/recipes-core/base-files/mel/issue
+++ /dev/null
@@ -1,2 +0,0 @@
-\n \l
-
diff --git a/meta-mel/recipes-core/base-files/mel/issue.net b/meta-mel/recipes-core/base-files/mel/issue.net
deleted file mode 100644
index c0f4fd41..00000000
--- a/meta-mel/recipes-core/base-files/mel/issue.net
+++ /dev/null
@@ -1,2 +0,0 @@
-%h
-
diff --git a/meta-mel/recipes-core/busybox/busybox/beagleboard/hwclock-default b/meta-mel/recipes-core/busybox/busybox/beagleboard/hwclock-default
deleted file mode 100644
index 94ff4e85..00000000
--- a/meta-mel/recipes-core/busybox/busybox/beagleboard/hwclock-default
+++ /dev/null
@@ -1,2 +0,0 @@
-# Can we use hwclock on this system?
-HWCLOCKACCESS=no
diff --git a/meta-mel/recipes-core/busybox/busybox/fancy-head.cfg b/meta-mel/recipes-core/busybox/busybox/fancy-head.cfg
deleted file mode 100644
index 16017ea4..00000000
--- a/meta-mel/recipes-core/busybox/busybox/fancy-head.cfg
+++ /dev/null
@@ -1 +0,0 @@
-CONFIG_FEATURE_FANCY_HEAD=y
diff --git a/meta-mel/recipes-core/busybox/busybox/pidof.cfg b/meta-mel/recipes-core/busybox/busybox/pidof.cfg
deleted file mode 100644
index a33483c8..00000000
--- a/meta-mel/recipes-core/busybox/busybox/pidof.cfg
+++ /dev/null
@@ -1,2 +0,0 @@
-CONFIG_FEATURE_PIDOF_SINGLE=y
-CONFIG_FEATURE_PIDOF_OMIT=y
diff --git a/meta-mel/recipes-core/busybox/busybox/setsid.cfg b/meta-mel/recipes-core/busybox/busybox/setsid.cfg
deleted file mode 100644
index 5f1e1c98..00000000
--- a/meta-mel/recipes-core/busybox/busybox/setsid.cfg
+++ /dev/null
@@ -1 +0,0 @@
-CONFIG_SETSID=y
diff --git a/meta-mel/recipes-core/busybox/busybox/top.cfg b/meta-mel/recipes-core/busybox/busybox/top.cfg
deleted file mode 100644
index 625cb612..00000000
--- a/meta-mel/recipes-core/busybox/busybox/top.cfg
+++ /dev/null
@@ -1,5 +0,0 @@
-CONFIG_FEATURE_TOP_INTERACTIVE=y
-CONFIG_FEATURE_TOP_SMP_CPU=y
-CONFIG_FEATURE_TOP_DECIMALS=y
-CONFIG_FEATURE_TOP_SMP_PROCESS=y
-CONFIG_FEATURE_TOPMEM=y
diff --git a/meta-mel/recipes-core/busybox/busybox_%.bbappend b/meta-mel/recipes-core/busybox/busybox_%.bbappend
deleted file mode 100644
index a6c14879..00000000
--- a/meta-mel/recipes-core/busybox/busybox_%.bbappend
+++ /dev/null
@@ -1,14 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/busybox:"
-
-# fancy-head.cfg is enabled so we have head -c, which we need for our tracing
-# scripts with lttng
-SRC_URI:append:mel = "\
- file://setsid.cfg \
- file://fancy-head.cfg \
- file://pidof.cfg \
- file://top.cfg \
-"
diff --git a/meta-mel/recipes-core/images/console-image.bb b/meta-mel/recipes-core/images/console-image.bb
deleted file mode 100644
index 09f07ab7..00000000
--- a/meta-mel/recipes-core/images/console-image.bb
+++ /dev/null
@@ -1,20 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SUMMARY = "A console-only image that fully supports the target device \
-hardware."
-
-# We want a package manager in our basic console image
-IMAGE_FEATURES += "package-management"
-
-# We want libgcc to always be available, even if nothing needs it, as its size
-# is minimal, and it's often needed by third party (or QA) binaries
-IMAGE_INSTALL:append:mel = " libgcc"
-
-LICENSE = "MIT"
-
-inherit core-image
-
-IMAGE_FEATURES .= "${@bb.utils.contains('COMBINED_FEATURES', 'alsa', ' tools-audio', '', d)}"
-IMAGE_INSTALL += " quota connman"
diff --git a/meta-mel/recipes-core/images/mel-initramfs-image.bb b/meta-mel/recipes-core/images/mel-initramfs-image.bb
deleted file mode 100644
index d932f182..00000000
--- a/meta-mel/recipes-core/images/mel-initramfs-image.bb
+++ /dev/null
@@ -1,37 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-DESCRIPTION = "MEL Image initramfs"
-
-PACKAGE_INSTALL = "initramfs-framework-base ${VIRTUAL-RUNTIME_base-utils} initramfs-module-udev udev base-passwd ${ROOTFS_BOOTSTRAP_INSTALL}"
-
-# Do not pollute the initrd image with rootfs features
-IMAGE_FEATURES = ""
-
-export IMAGE_BASENAME = "${MLPREFIX}mel-initramfs-image"
-IMAGE_NAME_SUFFIX ?= ""
-IMAGE_LINGUAS = ""
-
-LICENSE = "MIT"
-
-IMAGE_FSTYPES = "${INITRAMFS_FSTYPES}"
-inherit core-image
-
-IMAGE_ROOTFS_SIZE = "8192"
-IMAGE_ROOTFS_EXTRA_SPACE = "0"
-
-# We don't care about root password for login on initramfs images
-IMAGE_QA_COMMANDS:remove = "image_check_zapped_root_password"
-
-BAD_RECOMMENDATIONS += "busybox-syslog"
-
-# We don't need selinux labels in initramfs
-IMAGE_PREPROCESS_COMMAND:remove = "selinux_set_labels ;"
-
-COMPATIBLE_HOST:mel = "(arm|aarch64|i.86|x86_64).*-linux"
-
-# Take care of warnings due to dependency on noexec ${INITRAMFS_IMAGE}:do_image_complete's
-# do_packagedata() in our initramfs image for now. The fix needs to come from oe-core image
-# bbclass when available, after which this can be removed
-deltask do_packagedata
diff --git a/meta-mel/recipes-core/initrdscripts/files/init-boot.sh b/meta-mel/recipes-core/initrdscripts/files/init-boot.sh
deleted file mode 100644
index afe04581..00000000
--- a/meta-mel/recipes-core/initrdscripts/files/init-boot.sh
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-PATH=/sbin:/bin:/usr/sbin:/usr/bin
-
-mkdir -p /proc
-mkdir -p /sys
-mount -t proc proc /proc
-mount -t sysfs sysfs /sys
-
-# mount devtmpfs
-mount -n -o mode=0755 -t devtmpfs none "/dev"
-
-# get name of active terminal
-CONSOLE=`cat /sys/devices/virtual/tty/console/active | cut -d " " -f2`
-
-# run shell on active terminal
-setsid sh -c "exec sh </dev/$CONSOLE >/dev/$CONSOLE 2>&1"
diff --git a/meta-mel/recipes-core/initrdscripts/initramfs-boot_1.0.bbappend b/meta-mel/recipes-core/initrdscripts/initramfs-boot_1.0.bbappend
deleted file mode 100644
index bbaf9585..00000000
--- a/meta-mel/recipes-core/initrdscripts/initramfs-boot_1.0.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:mel := "${THISDIR}/files:"
diff --git a/meta-mel/recipes-core/initrdscripts/initramfs-framework/lvm b/meta-mel/recipes-core/initrdscripts/initramfs-framework/lvm
deleted file mode 100644
index e7cace85..00000000
--- a/meta-mel/recipes-core/initrdscripts/initramfs-framework/lvm
+++ /dev/null
@@ -1,18 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-lvm_enabled() {
- if ! lvscan |grep -i -w "inactive" &>/dev/null;then
- return 1
- fi
- return 0
-}
-
-lvm_run() {
- lvm pvscan --cache --activate ay
- lvm vgscan --mknodes
- udevadm trigger --action=add
-}
diff --git a/meta-mel/recipes-core/initrdscripts/initramfs-framework_%.bbappend b/meta-mel/recipes-core/initrdscripts/initramfs-framework_%.bbappend
deleted file mode 100644
index fcc6cfc5..00000000
--- a/meta-mel/recipes-core/initrdscripts/initramfs-framework_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
-
-RDEPENDS:initramfs-module-lvm += "lvm2"
-RRECOMMENDS:${PN}-base += "initramfs-module-lvm"
diff --git a/meta-mel/recipes-core/kbd/kbd_2.5.0.bbappend b/meta-mel/recipes-core/kbd/kbd_2.5.0.bbappend
deleted file mode 100644
index 41760e45..00000000
--- a/meta-mel/recipes-core/kbd/kbd_2.5.0.bbappend
+++ /dev/null
@@ -1,13 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SRC_URI:prepend:mel = "git://github.com/MentorEmbedded/kbd;branch=2.5;protocol=https "
-SRC_URI:remove:mel := "${KERNELORG_MIRROR}/linux/utils/${BPN}/${BP}.tar.xz"
-SRCREV:mel = "57b52a3f3cef3b6ba144c85fc62b3d3c8f83e4cf"
-S:mel = "${WORKDIR}/git"
-
-DEPENDS:append:mel = " bison-native"
-
-# Don't exclude autopoint
-EXTRA_AUTORECONF:mel = ""
diff --git a/meta-mel/recipes-core/meta/meta-environment.bbappend b/meta-mel/recipes-core/meta/meta-environment.bbappend
deleted file mode 100644
index 47f799b3..00000000
--- a/meta-mel/recipes-core/meta/meta-environment.bbappend
+++ /dev/null
@@ -1,11 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SDK_MULTILIB_VARIANTS ?= "${MULTILIB_VARIANTS}"
-python set_multilib_variants () {
- variants = d.getVar('SDK_MULTILIB_VARIANTS', True)
- if variants:
- d.setVar('MULTILIB_VARIANTS', variants)
-}
-do_generate_content[prefuncs] += "set_multilib_variants"
diff --git a/meta-mel/recipes-core/meta/sdk-env-kernelvars.bb b/meta-mel/recipes-core/meta/sdk-env-kernelvars.bb
deleted file mode 100644
index e84ad9c3..00000000
--- a/meta-mel/recipes-core/meta/sdk-env-kernelvars.bb
+++ /dev/null
@@ -1,21 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SUMMARY = "Add the KERNEL_ variables to the SDK environment."
-LICENSE = "MIT"
-LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"
-
-# Needed to get the vars defined
-inherit kernel-arch
-
-do_install () {
- install -d "${D}/environment-setup.d"
- cat <<END >"${D}/environment-setup.d/kernel.sh"
-KERNEL_CC="${KERNEL_CC}"
-KERNEL_LD="${KERNEL_LD}"
-KERNEL_AR="${KERNEL_AR}"
-END
-}
-
-FILES:${PN} += "/environment-setup.d/*"
diff --git a/meta-mel/recipes-core/os-release/os-release.bbappend b/meta-mel/recipes-core/os-release/os-release.bbappend
deleted file mode 100644
index 1d46103d..00000000
--- a/meta-mel/recipes-core/os-release/os-release.bbappend
+++ /dev/null
@@ -1,12 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-OS_RELEASE_FIELDS:mel = "PRETTY_NAME NAME VERSION_ID VERSION VERSION_CODENAME ID HOME_URL SUPPORT_URL BUG_REPORT_URL"
-
-ID:mel = "flex-os"
-NAME:mel = "Flex OS"
-VERSION:mel = "${DISTRO_VERSION}${@' (%s)' % DISTRO_CODENAME if 'DISTRO_CODENAME' in d else ''}"
-VERSION_ID:mel = "${DISTRO_VERSION}"
-VERSION_CODENAME:mel = "${@'(%s)' % DISTRO_CODENAME if 'DISTRO_CODENAME' in d else ''}"
-PRETTY_NAME:mel = "${DISTRO_NAME} ${VERSION}"
diff --git a/meta-mel/recipes-core/packagegroups/packagegroup-base.bbappend b/meta-mel/recipes-core/packagegroups/packagegroup-base.bbappend
deleted file mode 100644
index 6051fe4f..00000000
--- a/meta-mel/recipes-core/packagegroups/packagegroup-base.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-RDEPENDS:packagegroup-base-bluetooth:append:mel = "${@bb.utils.contains('DISTRO_FEATURES', 'pulseaudio', 'pulseaudio pulseaudio-server', '', d)}"
-
-RDEPENDS:packagegroup-base-nfs:append:mel = " nfs-utils-client"
diff --git a/meta-mel/recipes-core/packagegroups/packagegroup-core-boot.bbappend b/meta-mel/recipes-core/packagegroups/packagegroup-core-boot.bbappend
deleted file mode 100644
index c6fc6cc4..00000000
--- a/meta-mel/recipes-core/packagegroups/packagegroup-core-boot.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-#Don't use sysvinit based network configuration. We have connman for that purpose
-SYSVINIT_SCRIPTS:mel := "${@oe.utils.str_filter_out('init-ifupdown', SYSVINIT_SCRIPTS, d)}"
diff --git a/meta-mel/recipes-core/packagegroups/packagegroup-core-tools-profile.bbappend b/meta-mel/recipes-core/packagegroups/packagegroup-core-tools-profile.bbappend
deleted file mode 100644
index 7aafcd40..00000000
--- a/meta-mel/recipes-core/packagegroups/packagegroup-core-tools-profile.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# MEL Flex does not support systemtap. Systemtap brings boost which takes lots of resources. So we do not need it.
-SYSTEMTAP:mel = ""
diff --git a/meta-mel/recipes-core/psplash/mel/0001-plash-colors.h-color-change.patch b/meta-mel/recipes-core/psplash/mel/0001-plash-colors.h-color-change.patch
deleted file mode 100644
index ec3566f9..00000000
--- a/meta-mel/recipes-core/psplash/mel/0001-plash-colors.h-color-change.patch
+++ /dev/null
@@ -1,26 +0,0 @@
-From e9a4653ac28d9d27ca2da1caab0997c1b957c8fc Mon Sep 17 00:00:00 2001
-From: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
-Date: Thu, 13 Oct 2016 19:48:55 +0530
-Subject: [PATCH] plash-colors.h: color change
-
-Signed-off-by: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
----
- psplash-colors.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/psplash-colors.h b/psplash-colors.h
-index d701089..24a3a05 100644
---- a/psplash-colors.h
-+++ b/psplash-colors.h
-@@ -20,7 +20,7 @@
- #define _HAVE_PSPLASH_COLORS_H
-
- /* This is the overall background color */
--#define PSPLASH_BACKGROUND_COLOR 0xec,0xec,0xe1
-+#define PSPLASH_BACKGROUND_COLOR 0x00,0x00,0x00
-
- /* This is the color of any text output */
- #define PSPLASH_TEXT_COLOR 0x6d,0x6d,0x70
---
-2.7.4
-
diff --git a/meta-mel/recipes-core/psplash/mel/0001-psplash-config-enable-fullscreen-image.patch b/meta-mel/recipes-core/psplash/mel/0001-psplash-config-enable-fullscreen-image.patch
deleted file mode 100644
index 0ead5544..00000000
--- a/meta-mel/recipes-core/psplash/mel/0001-psplash-config-enable-fullscreen-image.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From 524a1568d8acd54c72bda67916831df2d8312b9a Mon Sep 17 00:00:00 2001
-From: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
-Date: Thu, 13 Oct 2016 17:06:31 +0530
-Subject: [PATCH] psplash-config: enable fullscreen image
-
-Signed-off-by: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
-
----
- psplash-config.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/psplash-config.h b/psplash-config.h
-index eb90ef3..d928248 100644
---- a/psplash-config.h
-+++ b/psplash-config.h
-@@ -18,7 +18,7 @@
-
- /* Bool indicating if the image is fullscreen, as opposed to split screen */
- #ifndef PSPLASH_IMG_FULLSCREEN
--#define PSPLASH_IMG_FULLSCREEN 0
-+#define PSPLASH_IMG_FULLSCREEN 1
- #endif
-
- /* Bool indicated if the progress bar should be disabled */
diff --git a/meta-mel/recipes-core/psplash/mel/mel.png b/meta-mel/recipes-core/psplash/mel/mel.png
deleted file mode 100644
index b7ca22d7..00000000
--- a/meta-mel/recipes-core/psplash/mel/mel.png
+++ /dev/null
Binary files differ
diff --git a/meta-mel/recipes-core/psplash/mel/psplash-final.service b/meta-mel/recipes-core/psplash/mel/psplash-final.service
deleted file mode 100644
index 90fe24ff..00000000
--- a/meta-mel/recipes-core/psplash/mel/psplash-final.service
+++ /dev/null
@@ -1,12 +0,0 @@
-[Unit]
-Description=Show Psplash Final Screen
-After=getty@tty1.service display-manager.service psplash-start.service
-Before=systemd-reboot.service systemd-halt.service systemd-poweroff.service
-DefaultDependencies=no
-
-[Service]
-Environment=TMPDIR=/run
-ExecStart=/usr/bin/psplash
-
-[Install]
-WantedBy=reboot.target halt.target poweroff.target
diff --git a/meta-mel/recipes-core/psplash/mel/psplash-quit.service b/meta-mel/recipes-core/psplash/mel/psplash-quit.service
deleted file mode 100755
index 6881a948..00000000
--- a/meta-mel/recipes-core/psplash/mel/psplash-quit.service
+++ /dev/null
@@ -1,12 +0,0 @@
-[Unit]
-Description=Terminate Psplash Boot Screen
-After=psplash-start.service
-ConditionPathExists=/run/psplash_fifo
-
-[Service]
-Environment=TMPDIR=/run
-Type=oneshot
-ExecStart=/usr/bin/psplash-write QUIT
-
-[Install]
-WantedBy=multi-user.target
diff --git a/meta-mel/recipes-core/psplash/mel/psplash-start.service b/meta-mel/recipes-core/psplash/mel/psplash-start.service
deleted file mode 100755
index 05c2dd80..00000000
--- a/meta-mel/recipes-core/psplash/mel/psplash-start.service
+++ /dev/null
@@ -1,12 +0,0 @@
-[Unit]
-Description=Starts Psplash Boot screen
-Wants=systemd-vconsole-setup.service
-After=systemd-vconsole-setup.service
-DefaultDependencies=no
-
-[Service]
-Environment=TMPDIR=/run
-ExecStart=/usr/bin/psplash
-
-[Install]
-WantedBy=sysinit.target
diff --git a/meta-mel/recipes-core/psplash/psplash_git.bbappend b/meta-mel/recipes-core/psplash/psplash_git.bbappend
deleted file mode 100644
index f8d44254..00000000
--- a/meta-mel/recipes-core/psplash/psplash_git.bbappend
+++ /dev/null
@@ -1,39 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}:"
-
-SRC_URI:append:mel = " ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '\
- file://psplash-quit.service \
- file://psplash-start.service \
- file://psplash-final.service \
- ', '', d)}"
-
-# Change background color and splash image with no progress bar
-SRC_URI:append:mel = " file://0001-psplash-config-enable-fullscreen-image.patch \
- file://0001-plash-colors.h-color-change.patch \
- "
-EXTRA_OECONF:append:mel = " --disable-progress-bar"
-
-# # Update to latest version of psplash
-# SRCREV:mel = "5b3c1cc28f5abdc2c33830150b48b278cc4f7bca"
-
-SPLASH_IMAGES:mel = "file://mel.png;outsuffix=default"
-
-SYSTEMD_INHERIT = ""
-SYSTEMD_INHERIT:mel = "systemd"
-inherit ${SYSTEMD_INHERIT}
-
-SYSTEMD_SERVICE:${PN}:mel = "psplash-start.service psplash-quit.service psplash-final.service"
-SYSTEMD_AUTO_ENABLE ?= "enable"
-
-do_install:append:mel() {
- if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then
- install -d ${D}${systemd_unitdir}/system/
- install -m 0644 ${WORKDIR}/psplash-quit.service ${D}${systemd_unitdir}/system
- install -m 0644 ${WORKDIR}/psplash-start.service ${D}${systemd_unitdir}/system
- install -m 0644 ${WORKDIR}/psplash-final.service ${D}${systemd_unitdir}/system
- fi
- rm -f ${D}${systemd_unitdir}/system/psplash-systemd.service
-}
diff --git a/meta-mel/recipes-core/systemd/systemd/monotonic-timestamp.patch b/meta-mel/recipes-core/systemd/systemd/monotonic-timestamp.patch
deleted file mode 100644
index a79a4d5a..00000000
--- a/meta-mel/recipes-core/systemd/systemd/monotonic-timestamp.patch
+++ /dev/null
@@ -1,160 +0,0 @@
-From 349b0586d07a9d48b781c18c7932c0b3cd102e65 Mon Sep 17 00:00:00 2001
-From: Muhammad Shakeel <mshakeel@pkl-mshakeel-ubuntu.(none)>
-Date: Tue, 25 Jun 2013 18:58:02 +0500
-Subject: [PATCH] systemctl-clock: Use monotonic instead of realtime clock
-
-Currently if system clock is updated then 'ago' part of any service
-running time doesn't show correct information. This is reported here:
-https://bugs.freedesktop.org/show_bug.cgi?id=65616
----
- src/login/loginctl.c | 10 ++++++++--
- src/machine/machinectl.c | 2 +-
- src/shared/time-util.c | 2 +-
- src/systemctl/systemctl.c | 27 ++++++++++++++++++++++++---
- 4 files changed, 34 insertions(+), 7 deletions(-)
-
-diff --git a/src/login/loginctl.c b/src/login/loginctl.c
-index 736db6a..ea64546 100644
---- a/src/login/loginctl.c
-+++ b/src/login/loginctl.c
-@@ -339,6 +339,7 @@ typedef struct SessionStatusInfo {
- uid_t uid;
- const char *name;
- usec_t timestamp;
-+ usec_t timestamp_monotonic;
- int vtnr;
- const char *seat;
- const char *tty;
-@@ -358,6 +359,7 @@ typedef struct UserStatusInfo {
- uid_t uid;
- const char *name;
- usec_t timestamp;
-+ usec_t timestamp_monotonic;
- const char *state;
- char **sessions;
- const char *display;
-@@ -382,7 +384,7 @@ static void print_session_status_info(DBusConnection *bus, SessionStatusInfo *i)
- else
- printf("%u\n", (unsigned) i->uid);
-
-- s1 = format_timestamp_relative(since1, sizeof(since1), i->timestamp);
-+ s1 = format_timestamp_relative(since1, sizeof(since1), i->timestamp_monotonic);
- s2 = format_timestamp(since2, sizeof(since2), i->timestamp);
-
- if (s1)
-@@ -462,7 +464,7 @@ static void print_user_status_info(DBusConnection *bus, UserStatusInfo *i) {
- else
- printf("%u\n", (unsigned) i->uid);
-
-- s1 = format_timestamp_relative(since1, sizeof(since1), i->timestamp);
-+ s1 = format_timestamp_relative(since1, sizeof(since1), i->timestamp_monotonic);
- s2 = format_timestamp(since2, sizeof(since2), i->timestamp);
-
- if (s1)
-@@ -598,6 +600,8 @@ static int status_property_session(const char *name, DBusMessageIter *iter, Sess
-
- if (streq(name, "Timestamp"))
- i->timestamp = (usec_t) u;
-+ else if (streq(name, "TimestampMonotonic"))
-+ i->timestamp_monotonic = (usec_t) u;
-
- break;
- }
-@@ -670,6 +674,8 @@ static int status_property_user(const char *name, DBusMessageIter *iter, UserSta
-
- if (streq(name, "Timestamp"))
- i->timestamp = (usec_t) u;
-+ else if (streq(name, "TimestampMonotonic"))
-+ i->timestamp_monotonic = (usec_t) u;
-
- break;
- }
-diff --git a/src/shared/time-util.c b/src/shared/time-util.c
-index 9ee711a..08c8a2f 100644
---- a/src/shared/time-util.c
-+++ b/src/shared/time-util.c
-@@ -171,7 +171,7 @@ char *format_timestamp(char *buf, size_t l, usec_t t) {
- char *format_timestamp_relative(char *buf, size_t l, usec_t t) {
- usec_t n, d;
-
-- n = now(CLOCK_REALTIME);
-+ n = now(CLOCK_MONOTONIC);
-
- if (t <= 0 || t > n || t + USEC_PER_DAY*7 <= t)
- return NULL;
-diff --git a/src/systemctl/systemctl.c b/src/systemctl/systemctl.c
-index 9f47b2c..a05b5f8 100644
---- a/src/systemctl/systemctl.c
-+++ b/src/systemctl/systemctl.c
-@@ -2515,6 +2515,9 @@ typedef struct UnitStatusInfo {
- usec_t active_enter_timestamp;
- usec_t active_exit_timestamp;
- usec_t inactive_enter_timestamp;
-+ usec_t active_enter_timestamp_monotonic;
-+ usec_t active_exit_timestamp_monotonic;
-+ usec_t inactive_enter_timestamp_monotonic;
-
- bool need_daemon_reload;
-
-@@ -2531,6 +2534,7 @@ typedef struct UnitStatusInfo {
- int exit_code, exit_status;
-
- usec_t condition_timestamp;
-+ usec_t condition_timestamp_monotonic;
- bool condition_result;
- bool failed_condition_trigger;
- bool failed_condition_negate;
-@@ -2560,7 +2564,7 @@ typedef struct UnitStatusInfo {
- static void print_status_info(UnitStatusInfo *i) {
- ExecStatusInfo *p;
- const char *on, *off, *ss;
-- usec_t timestamp;
-+ usec_t timestamp, timestamp_monotonic;
- char since1[FORMAT_TIMESTAMP_RELATIVE_MAX], *s1;
- char since2[FORMAT_TIMESTAMP_MAX], *s2;
- const char *path;
-@@ -2664,7 +2668,14 @@ static void print_status_info(UnitStatusInfo *i) {
- streq_ptr(i->active_state, "activating") ? i->inactive_exit_timestamp :
- i->active_exit_timestamp;
-
-- s1 = format_timestamp_relative(since1, sizeof(since1), timestamp);
-+ timestamp_monotonic = (streq_ptr(i->active_state, "active") ||
-+ streq_ptr(i->active_state, "reloading")) ? i->active_enter_timestamp_monotonic :
-+ (streq_ptr(i->active_state, "inactive") ||
-+ streq_ptr(i->active_state, "failed")) ? i->inactive_enter_timestamp_monotonic :
-+ streq_ptr(i->active_state, "activating") ? i->inactive_exit_timestamp_monotonic :
-+ i->active_exit_timestamp_monotonic;
-+
-+ s1 = format_timestamp_relative(since1, sizeof(since1), timestamp_monotonic);
- s2 = format_timestamp(since2, sizeof(since2), timestamp);
-
- if (s1)
-@@ -2675,7 +2686,7 @@ static void print_status_info(UnitStatusInfo *i) {
- printf("\n");
-
- if (!i->condition_result && i->condition_timestamp > 0) {
-- s1 = format_timestamp_relative(since1, sizeof(since1), i->condition_timestamp);
-+ s1 = format_timestamp_relative(since1, sizeof(since1), i->condition_timestamp_monotonic);
- s2 = format_timestamp(since2, sizeof(since2), i->condition_timestamp);
-
- printf(" start condition failed at %s%s%s\n",
-@@ -3030,6 +3041,16 @@ static int status_property(const char *name, DBusMessageIter *iter, UnitStatusIn
- i->active_exit_timestamp = (usec_t) u;
- else if (streq(name, "ConditionTimestamp"))
- i->condition_timestamp = (usec_t) u;
-+ else if (streq(name, "ActiveEnterTimestampMonotonic"))
-+ i->active_enter_timestamp_monotonic = (usec_t) u;
-+ else if (streq(name, "InactiveEnterTimestampMonotonic"))
-+ i->inactive_enter_timestamp_monotonic = (usec_t) u;
-+ else if (streq(name, "InactiveExitTimestampMonotonic"))
-+ i->inactive_exit_timestamp_monotonic = (usec_t) u;
-+ else if (streq(name, "ActiveExitTimestampMonotonic"))
-+ i->active_exit_timestamp_monotonic = (usec_t) u;
-+ else if (streq(name, "ConditionTimestampMonotonic"))
-+ i->condition_timestamp_monotonic = (usec_t) u;
-
- break;
- }
---
-1.8.3.4
-
diff --git a/meta-mel/recipes-core/systemd/systemd_%.bbappend b/meta-mel/recipes-core/systemd/systemd_%.bbappend
deleted file mode 100644
index 33ab5b6c..00000000
--- a/meta-mel/recipes-core/systemd/systemd_%.bbappend
+++ /dev/null
@@ -1,16 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SYSTEMD_LOGLEVEL ?= "info"
-SYSTEMD_LOGLEVEL:mel ?= "emerg"
-
-do_compile:append:mel () {
- printf '[Manager]\n' >loglevel.conf
- printf 'LogLevel=${SYSTEMD_LOGLEVEL}\n' >>loglevel.conf
-}
-
-do_install:append:mel () {
- install -d "${D}${nonarch_libdir}/systemd/system.conf.d"
- install -m 0644 loglevel.conf "${D}${nonarch_libdir}/systemd/system.conf.d/"
-}
diff --git a/meta-mel/recipes-core/util-linux/util-linux_%.bbappend b/meta-mel/recipes-core/util-linux/util-linux_%.bbappend
deleted file mode 100644
index fa0fcffc..00000000
--- a/meta-mel/recipes-core/util-linux/util-linux_%.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-EXTRA_OECONF:append:class-native:mel = " --disable-schedutils"
diff --git a/meta-mel/recipes-devtools/e2fsprogs/e2fsprogs_%.bbappend b/meta-mel/recipes-devtools/e2fsprogs/e2fsprogs_%.bbappend
deleted file mode 100644
index f8b23c13..00000000
--- a/meta-mel/recipes-devtools/e2fsprogs/e2fsprogs_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# The e2fsprogs recipe has the main package depending upon blkid and badblocks
-# for compatibility, but we know we aren't bitten by that compatibility issue,
-# so we drop that dependency.
-RDEPENDS:e2fsprogs:mel = ""
diff --git a/meta-mel/recipes-devtools/llvm/llvm_%.bbappend b/meta-mel/recipes-devtools/llvm/llvm_%.bbappend
deleted file mode 100644
index b9af2c56..00000000
--- a/meta-mel/recipes-devtools/llvm/llvm_%.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# If build system has 8 or less CPU cores, build only 8 jobs in parallel
-PARALLEL_MAKE:mel = "-j ${@'8' if oe.utils.cpu_count() <= 8 else oe.utils.cpu_count() * 2}"
diff --git a/meta-mel/recipes-devtools/python/python3_%.bbappend b/meta-mel/recipes-devtools/python/python3_%.bbappend
deleted file mode 100644
index 3330ed55..00000000
--- a/meta-mel/recipes-devtools/python/python3_%.bbappend
+++ /dev/null
@@ -1,54 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Needed by patchinfo
-PATCHINFO_PYTHONPATH = "${COMPONENTS_DIR}/${BUILD_ARCH}/python3-unidiff-native/${libdir}/python${PYTHON_MAJMIN}/site-packages"
-DEPENDS_UNIDIFF = ""
-DEPENDS_UNIDIFF:mel:class-target = "python3-unidiff-native:do_populate_sysroot"
-do_archive_release_downloads[depends] += "${DEPENDS_UNIDIFF}"
-
-# Write patch names and modified files to python3-patches.txt
-python do_archive_release_downloads:append:mel:class-target () {
- import csv
- import json
- from collections import defaultdict
- from pathlib import Path
-
- sources_dir = Path(sources_dir)
- layerdir = d.getVar('LAYERDIR_mel')
- script = Path(layerdir).parent / 'scripts' / 'patchinfo'
- if not script.exists():
- bb.fatal('Expected {} script does not exist'.format(str(script)))
-
- python = d.getVar('PYTHON')
- env = os.environ.copy()
- env['PYTHONPATH'] = d.getVar('PATCHINFO_PYTHONPATH')
-
- patchinfos = []
- patches = [bb.fetch.decodeurl(u)[2] for u in src_patches(d)]
- for patch in patches:
- try:
- info, _ = bb.process.run([python, str(script), patch], cwd=sources_dir, env=env)
- except bb.process.ExecutionError as exc:
- bb.warn("Failed to get patchinfo for %s: %s" % (patch, exc))
- continue
- else:
- try:
- patchinfo = json.loads(info)
- except json.decoder.JSONDecodeError as exc:
- bb.warn("Failed to decode json from patchinfo for %s" % patch)
- continue
- else:
- if 'Filename' in patchinfo and 'Files' in patchinfo:
- patchinfos.append(patchinfo)
- else:
- bb.warn("Unexpected json contents for patchinfo for %s" % patch)
-
- with open(sources_dir / 'python3-patches.txt', 'w') as f:
- for patchinfo in patchinfos:
- patch, files = patchinfo['Filename'], patchinfo['Files']
- f.write(patch + ':\n')
- for fn in files:
- f.write(' ' + fn + '\n')
-}
diff --git a/meta-mel/recipes-graphics/images/weston-image.bb b/meta-mel/recipes-graphics/images/weston-image.bb
deleted file mode 100644
index 84c8653f..00000000
--- a/meta-mel/recipes-graphics/images/weston-image.bb
+++ /dev/null
@@ -1,22 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SUMMARY = "Wayland/Weston image based on core-image-weston image recipe"
-
-IMAGE_FEATURES += "splash package-management hwcodecs"
-
-LICENSE = "MIT"
-
-inherit core-image features_check
-
-REQUIRED_DISTRO_FEATURES = "wayland"
-
-CORE_IMAGE_BASE_INSTALL += "weston weston-init weston-examples"
-
-# We want libgcc to always be available, even if nothing needs it, as its size
-# is minimal, and it's often needed by third party (or QA) binaries
-IMAGE_INSTALL:append:mel = " libgcc"
-
-IMAGE_FEATURES .= "${@bb.utils.contains('COMBINED_FEATURES', 'alsa', ' tools-audio', '', d)}"
-IMAGE_INSTALL += " quota connman"
diff --git a/meta-mel/recipes-graphics/libsdl2/libsdl2_%.bbappend b/meta-mel/recipes-graphics/libsdl2/libsdl2_%.bbappend
deleted file mode 100644
index 2c3a3b38..00000000
--- a/meta-mel/recipes-graphics/libsdl2/libsdl2_%.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-DISTRO_FEATURES:remove:mel = "opengl"
diff --git a/meta-mel/recipes-kernel/perf/perf.bbappend b/meta-mel/recipes-kernel/perf/perf.bbappend
deleted file mode 100644
index 3f1b6404..00000000
--- a/meta-mel/recipes-kernel/perf/perf.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# MEL supports BSP kernel versions which upstream doesn't care about.
-# Remove -I/usr/local/include from the default INCLUDES
-EXTRA_OEMAKE:append:mel = " 'INCLUDES=-I. $(CONFIG_INCLUDES)'"
diff --git a/meta-mel/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend b/meta-mel/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend
deleted file mode 100644
index a3eaedc6..00000000
--- a/meta-mel/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend
+++ /dev/null
@@ -1,16 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-do_compile:append:mel () {
- # Work around a toolchain issue with the default resampler (speex-float-N)
- # by using speex-fixed-N. JIRA: SB-1495
- set_cfg_value src/daemon/daemon.conf resample-method speex-fixed-3
-}
-
-RDEPENDS:pulseaudio-server:append:mel = "\
- pulseaudio-module-switch-on-port-available \
- pulseaudio-module-cli \
- pulseaudio-module-dbus-protocol \
- pulseaudio-module-echo-cancel \
-"
diff --git a/meta-mel/recipes-sato/images/core-image-sato.bbappend b/meta-mel/recipes-sato/images/core-image-sato.bbappend
deleted file mode 100644
index 17bbd171..00000000
--- a/meta-mel/recipes-sato/images/core-image-sato.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-IMAGE_FEATURES:append:mel = "${@bb.utils.contains('COMBINED_FEATURES', 'alsa', ' tools-audio', '', d)}"
-IMAGE_INSTALL:append:mel = " quota"
diff --git a/meta-mel/recipes-support/boost/boost_%.bbappend b/meta-mel/recipes-support/boost/boost_%.bbappend
deleted file mode 100644
index 65aada9e..00000000
--- a/meta-mel/recipes-support/boost/boost_%.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-PARALLEL_MAKE:mel = "-j 4"
diff --git a/meta-mel/recipes-support/consolekit/consolekit/0001-Ensure-filesystems-are-still-mounted-when-consolekit.patch b/meta-mel/recipes-support/consolekit/consolekit/0001-Ensure-filesystems-are-still-mounted-when-consolekit.patch
deleted file mode 100644
index 580ccad4..00000000
--- a/meta-mel/recipes-support/consolekit/consolekit/0001-Ensure-filesystems-are-still-mounted-when-consolekit.patch
+++ /dev/null
@@ -1,25 +0,0 @@
---- a/data/console-kit-log-system-restart.service.in
-+++ b/data/console-kit-log-system-restart.service.in
-@@ -2,7 +2,7 @@
- Description=Console System Reboot Logging
- DefaultDependencies=no
- After=sysinit.target console-kit-log-system-start.service
--Before=shutdown.target
-+Before=shutdown.target umount.target
-
- [Service]
- Type=oneshot
---- a/data/console-kit-log-system-stop.service.in
-+++ b/cdata/onsole-kit-log-system-stop.service.in
-@@ -2,7 +2,7 @@
- Description=Console System Shutdown Logging
- DefaultDependencies=no
- After=sysinit.target console-kit-log-system-start.service
--Before=shutdown.target
-+Before=shutdown.target umount.target
-
- [Service]
- Type=oneshot
---
-2.7.4
-
diff --git a/meta-mel/recipes-support/consolekit/consolekit_%.bbappend b/meta-mel/recipes-support/consolekit/consolekit_%.bbappend
deleted file mode 100644
index 914c16af..00000000
--- a/meta-mel/recipes-support/consolekit/consolekit_%.bbappend
+++ /dev/null
@@ -1,9 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:"
-
-SRC_URI:append:mel = " \
- file://0001-Ensure-filesystems-are-still-mounted-when-consolekit.patch \
-"
diff --git a/meta-mel/recipes-support/curl/curl_%.bbappend b/meta-mel/recipes-support/curl/curl_%.bbappend
deleted file mode 100644
index 2f1dd7c6..00000000
--- a/meta-mel/recipes-support/curl/curl_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# We need openssl support for nativesdk-curl to ensure we can clone https
-# repositories with nativesdk-git.
-DEPENDS:append:class-nativesdk:mel = " nativesdk-openssl"
-PACKAGECONFIG:append:class-nativesdk:mel = " ssl"
diff --git a/meta-mel/recipes-support/db/db_%.bbappend b/meta-mel/recipes-support/db/db_%.bbappend
deleted file mode 100644
index f4757dd2..00000000
--- a/meta-mel/recipes-support/db/db_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SRC_URI:mel = "git://github.com/MentorEmbedded/libdb;branch=5.3;protocol=https"
-SRCREV:mel = "81e5dd637b0bd954904130a2a493d3ac281148dc"
-PV:mel = "5.3.28+git${SRCPV}"
-S:mel = "${WORKDIR}/git"
diff --git a/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-2g.wks b/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-2g.wks
deleted file mode 100644
index 3a6cae28..00000000
--- a/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-2g.wks
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# short-description: Create SD card image with a boot partition
-# long-description: Creates a partitioned SD card image. Boot files
-# are located in the first vfat partition.
-
-part /boot --source bootimg-partition --ondisk mmcblk --fstype=vfat --label boot --active --align 4096 --size 64M --extra-space 0
-part / --source rootfs --ondisk mmcblk --fstype=ext4 --label root --align 4096 --size 1710080K --extra-space 0 --overhead-factor 1
diff --git a/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-4g.wks b/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-4g.wks
deleted file mode 100644
index 1f9ff929..00000000
--- a/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-4g.wks
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# short-description: Create SD card image with a boot partition
-# long-description: Creates a partitioned SD card image. Boot files
-# are located in the first vfat partition.
-
-part /boot --source bootimg-partition --ondisk mmcblk --fstype=vfat --label boot --active --align 4096 --size 64M --extra-space 0
-part / --source rootfs --ondisk mmcblk --fstype=ext4 --label root --align 4 --size 3600M --overhead-factor 1 --extra-space 0
diff --git a/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-8g.wks b/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-8g.wks
deleted file mode 100644
index e769a2df..00000000
--- a/meta-mel/scripts/lib/wic/canned-wks/sdimage-bootpart-8g.wks
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# short-description: Create SD card image with a boot partition
-# long-description: Creates a partitioned SD card image. Boot files
-# are located in the first vfat partition.
-
-part /boot --source bootimg-partition --ondisk mmcblk --fstype=vfat --label boot --active --align 4 --size 64M --extra-space 0
-part / --source rootfs --ondisk mmcblk --fstype=ext4 --label root --align 4 --size 7500M --overhead-factor 1 --extra-space 0
diff --git a/meta-mentor-common/COPYING.MIT b/meta-mentor-common/COPYING.MIT
deleted file mode 100644
index fb950dc6..00000000
--- a/meta-mentor-common/COPYING.MIT
+++ /dev/null
@@ -1,17 +0,0 @@
-Permission is hereby granted, free of charge, to any person obtaining a copy
-of this software and associated documentation files (the "Software"), to deal
-in the Software without restriction, including without limitation the rights
-to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-copies of the Software, and to permit persons to whom the Software is
-furnished to do so, subject to the following conditions:
-
-The above copyright notice and this permission notice shall be included in
-all copies or substantial portions of the Software.
-
-THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-THE SOFTWARE.
diff --git a/meta-mentor-common/README b/meta-mentor-common/README
deleted file mode 100644
index 57b9502a..00000000
--- a/meta-mentor-common/README
+++ /dev/null
@@ -1,41 +0,0 @@
-This README file contains information on the contents of the ../meta-mentor/meta-mentor-common layer.
-
-Please see the corresponding sections below for details.
-
-Dependencies
-============
-
- URI: <first dependency>
- branch: <branch name>
-
- URI: <second dependency>
- branch: <branch name>
-
- .
- .
- .
-
-Patches
-=======
-
-Please submit any patches against the ../meta-mentor/meta-mentor-common layer to the xxxx mailing list (xxxx@zzzz.org)
-and cc: the maintainer:
-
-Maintainer: XXX YYYYYY <xxx.yyyyyy@zzzzz.com>
-
-Table of Contents
-=================
-
- I. Adding the ../meta-mentor/meta-mentor-common layer to your build
- II. Misc
-
-
-I. Adding the ../meta-mentor/meta-mentor-common layer to your build
-=================================================
-
-Run 'bitbake-layers add-layer ../meta-mentor/meta-mentor-common'
-
-II. Misc
-========
-
---- replace with specific information about the ../meta-mentor/meta-mentor-common layer ---
diff --git a/meta-mentor-common/classes/archive-release-downloads.bbclass b/meta-mentor-common/classes/archive-release-downloads.bbclass
deleted file mode 100644
index 37d9c373..00000000
--- a/meta-mentor-common/classes/archive-release-downloads.bbclass
+++ /dev/null
@@ -1,118 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Deploy the downloads necessary for doing offline builds with the layers
-# distributed by archive-release, taking into account redistribution rights
-# for those sources by using license filtering.
-#
-# Originally copied from copyleft_compliance. This is kept separate due to the
-# slightly different purposes, and to let us alter how it operates without
-# affecting potential user use of copyleft_compliance.
-#
-# vi:sts=4:sw=4:et
-
-ARCHIVE_RELEASE_DL_DIR ?= '${DEPLOY_DIR}/release-downloads'
-ARCHIVE_RELEASE_EXCLUDED_DL_DIR ?= '${DEPLOY_DIR}/release-downloads-excluded'
-
-DL_LICENSE_INCLUDE ?= "${@' '.join(sorted(set(d.getVarFlags('SPDXLICENSEMAP').values())))}"
-DL_LICENSE_INCLUDE[type] = 'list'
-DL_LICENSE_INCLUDE[doc] = 'Space separated list of included licenses (supports wildcards)'
-
-DL_LICENSE_EXCLUDE ?= 'CLOSED Proprietary* Mentor Freescale EULA INTEL NetLogic'
-DL_LICENSE_EXCLUDE[type] = 'list'
-DL_LICENSE_EXCLUDE[doc] = 'Space separated list of excluded licenses (supports wildcards)'
-
-python do_archive_release_downloads () {
- """Populate a tree of the recipe sources and emit patch series files"""
- import os.path
- import shutil
- import oe.license
-
- include = oe.data.typed_value('DL_LICENSE_INCLUDE', d)
- exclude = oe.data.typed_value('DL_LICENSE_EXCLUDE', d)
-
- try:
- included, reason = oe.license.is_included(d.getVar('LICENSE', True), include, exclude)
- except oe.license.LicenseError as exc:
- bb.fatal('%s: %s' % (d.getVar('PF', True), exc))
-
- p = d.getVar('P', True)
- if not included:
- bb.debug(1, 'archive-release-downloads: %s is excluded: %s' % (p, reason))
- sources_dir = d.getVar('ARCHIVE_RELEASE_EXCLUDED_DL_DIR', True)
- else:
- bb.debug(1, 'archive-release-downloads: %s is included: %s' % (p, reason))
- sources_dir = d.getVar('ARCHIVE_RELEASE_DL_DIR', True)
-
- dl_dir = d.getVar('DL_DIR', True)
- src_uri = d.getVar('SRC_URI', True).split()
- fetch = bb.fetch2.Fetch(src_uri, d)
- ud = fetch.ud
-
- bb.utils.mkdirhier(sources_dir)
-
- for u in ud.values():
- archive_download(u, dl_dir, sources_dir, d)
-}
-
-def archive_download(u, dl_dir, sources_dir, d):
- if hasattr(u.method, 'process_submodules'):
- def archive_submodule(ud, url, module, modpath, workdir, d):
- url += ";bareclone=1;nobranch=1"
- newfetch = bb.fetch2.Fetch([url], d)
- for subud in newfetch.ud.values():
- return archive_download(subud, dl_dir, sources_dir, d)
-
- # If we're using a shallow mirror tarball it needs to be unpacked
- # temporarily so that we can examine the .gitmodules file
- if u.shallow and os.path.exists(u.fullshallow) and u.method.need_update(u, d):
- import tempfile
- with tempfile.TemporaryDirectory(dir=sources_dir) as tmpdir:
- bb.fetch2.runfetchcmd("tar -xzf %s" % u.fullshallow, d, workdir=tmpdir)
- u.method.process_submodules(u, tmpdir, archive_submodule, d)
- else:
- u.method.process_submodules(u, u.clonedir, archive_submodule, d)
-
- u.setup_localpath(d)
- local = u.localpath
- if local.endswith('.bb'):
- return
- elif not local.startswith(dl_dir + '/'):
- # For our purposes, we only want downloads, not what's in the layers
- return
- elif local.endswith('/'):
- local = local[:-1]
-
- if hasattr(u, 'mirrortarballs'):
- tarballs = u.mirrortarballs
- elif u.mirrortarball:
- tarballs = [u.mirrortarball]
- else:
- tarballs = None
-
- if tarballs:
- for tarball in tarballs:
- if tarball:
- tarball_path = os.path.join(dl_dir, tarball)
- if os.path.exists(tarball_path):
- local = tarball_path
- break
- else:
- bb.warn('No mirror tarball found for %s, using %s' % (u.url, local))
-
- oe.path.symlink(local, os.path.join(sources_dir, os.path.basename(local)), force=True)
- donestamp = local + '.done'
- if os.path.exists(donestamp):
- oe.path.symlink(donestamp, os.path.join(sources_dir, os.path.basename(donestamp)), force=True)
-
-do_archive_release_downloads[dirs] = "${WORKDIR}"
-addtask archive_release_downloads after do_fetch
-
-python do_archive_release_downloads_all() {
- pass
-}
-do_archive_release_downloads_all[recrdeptask] = "do_archive_release_downloads_all do_archive_release_downloads"
-do_archive_release_downloads_all[recideptask] = "do_${BB_DEFAULT_TASK}"
-do_archive_release_downloads_all[nostamp] = "1"
-addtask archive_release_downloads_all after do_archive_release_downloads
diff --git a/meta-mentor-common/classes/archive_sdk_downloads.bbclass b/meta-mentor-common/classes/archive_sdk_downloads.bbclass
deleted file mode 100644
index df54a347..00000000
--- a/meta-mentor-common/classes/archive_sdk_downloads.bbclass
+++ /dev/null
@@ -1,12 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-python do_archive_sdk_downloads () {
- pass
-}
-do_archive_sdk_downloads[dirs] = "${TOPDIR}"
-do_archive_sdk_downloads[recrdeptask] = "do_archive_release_downloads_all do_archive_release_downloads"
-do_archive_sdk_downloads[recideptask] = "do_${BB_DEFAULT_TASK} do_populate_sdk"
-do_archive_sdk_downloads[nostamp] = "1"
-addtask archive_sdk_downloads after do_archive_release_downloads_all
diff --git a/meta-mentor-common/classes/cml1-config.bbclass b/meta-mentor-common/classes/cml1-config.bbclass
deleted file mode 100644
index 22fce77b..00000000
--- a/meta-mentor-common/classes/cml1-config.bbclass
+++ /dev/null
@@ -1,102 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Consistent handling of the defconfig -> .config, with merge of config
-# fragments using the same mechanism as busybox and linux-yocto.
-#
-# The functionality is split into a number of small functions to easier
-# facilitate recipe alteration of the process, or filtering of the fragments
-# to be merged. To filter the fragments in use, append to the pipeline (after
-# the inherit of this class):
-#
-# merge_fragment_pipeline .= "| my_filter"
-#
-# Note: due to bitbake's use of set -e, the filter must return success (0).
-
-# For merge_config.sh
-DEPENDS += "kern-tools-native"
-
-DEFCONFIG ?= "${WORKDIR}/defconfig"
-merge_fragment_pipeline = "cat"
-
-do_configure:prepend () {
- DEFCONFIG="${DEFCONFIG}"
- if [ "${DEFCONFIG#/}" = "${DEFCONFIG}" ]; then
- DEFCONFIG="${S}/${DEFCONFIG}"
- fi
-
- if [ ! -e "$DEFCONFIG" ]; then
- bbfatal "Configuration file '${DEFCONFIG}' does not exist"
- fi
-
- install_config
- merge_fragments ${B}/.config
-}
-
-install_config () {
- cp -f $DEFCONFIG ${B}/.config
-}
-
-merge_fragments () {
- list_fragments | ${merge_fragment_pipeline} >"${B}/fragments"
- merge_config.sh -m "$1" $(cat "${B}/fragments")
-}
-
-list_fragments () {
- cat <<END
- ${@"\n".join(src_config_fragments(d))}
-END
-}
-
-def src_config_fragments(d):
- workdir = d.getVar('WORKDIR')
- fetch = bb.fetch2.Fetch([], d)
- for url in fetch.urls:
- urldata = fetch.ud[url]
- urldata.setup_localpath(d)
-
- unpacked_path = unpack_path(urldata, workdir, lambda f: f.endswith('cfg'))
- if unpacked_path:
- yield unpacked_path
-
-# This is directly from bitbake's fetch2 unpack() method
-def unpack_path(urldata, rootdir, filter_path=None):
- localpath = urldata.localpath
-
- # Localpath can't deal with 'dir/*' entries, so it converts them to '.',
- # but it must be corrected back for local files copying
- if urldata.basename == '*' and localpath.endswith('/.'):
- localpath = '%s/%s' % (file.rstrip('/.'), urldata.path)
-
- base, ext = os.path.splitext(localpath)
- if ext in ['.gz', '.bz2', '.Z', '.xz', '.lz']:
- efile = os.path.join(rootdir, os.path.basename(base))
- else:
- efile = localpath
-
- if not filter_path or not filter_path(efile):
- return
-
- if 'subdir' in urldata.parm:
- subdir = urldata.parm.get('subdir')
- if os.path.isabs(subdir):
- if not os.path.realpath(subdir).startswith(os.path.realpath(rootdir)):
- bb.fatal("subdir argument isn't a subdirectory of unpack root %s" % rootdir, urldata.url)
- unpackdir = subdir
- else:
- unpackdir = os.path.join(rootdir, subdir)
- else:
- unpackdir = rootdir
-
- destdir = '.'
- # For file:// entries all intermediate dirs in path must be created at destination
- if urldata.type == "file":
- # Trailing '/' does a copying to wrong place
- urlpath = urldata.path.rstrip('/')
- # Want files places relative to cwd so no leading '/'
- urlpath = urlpath.lstrip('/')
- if urlpath.find("/") != -1:
- destdir = urlpath.rsplit("/", 1)[0] + '/'
-
- return os.path.join(unpackdir, destdir, os.path.basename(efile))
diff --git a/meta-mentor-common/classes/copyleft_compliance_all.bbclass b/meta-mentor-common/classes/copyleft_compliance_all.bbclass
deleted file mode 100644
index df014484..00000000
--- a/meta-mentor-common/classes/copyleft_compliance_all.bbclass
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-addtask prepare_copyleft_sources_all after do_prepare_copyleft_sources
-do_prepare_copyleft_sources_all[recrdeptask] = 'do_prepare_copyleft_sources_all do_prepare_copyleft_sources'
-do_prepare_copyleft_sources_all[nostamp] = "1"
-python do_prepare_copyleft_sources_all() {
- pass
-}
diff --git a/meta-mentor-common/classes/deploy-license-manifest.bbclass b/meta-mentor-common/classes/deploy-license-manifest.bbclass
deleted file mode 100644
index 167e2306..00000000
--- a/meta-mentor-common/classes/deploy-license-manifest.bbclass
+++ /dev/null
@@ -1,20 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-ROOTFS_POSTPROCESS_COMMAND += "deploy_license_manifest;"
-IMAGE_POSTPROCESS_COMMAND += "link_license_manifest;"
-
-deploy_license_manifest () {
- if [ -e "${LICENSE_DIRECTORY}/${IMAGE_NAME}/license.manifest" ]; then
- cp ${LICENSE_DIRECTORY}/${IMAGE_NAME}/license.manifest ${IMGDEPLOYDIR}/${IMAGE_NAME}.license_manifest
- sed -n '/PACKAGE NAME/{: start; /^ *$/b done; /LICENSE:/{s/: /: "/; s/$/"/;}; s/^.*://; H; n; b start; : done; x; s/^[\n ]*//; s/ *\n */,/g; p}' ${IMGDEPLOYDIR}/${IMAGE_NAME}.license_manifest >${IMGDEPLOYDIR}/${IMAGE_NAME}.license_manifest.csv
- fi
-}
-
-link_license_manifest () {
- if [ -e "${IMGDEPLOYDIR}/${IMAGE_NAME}.license_manifest" ]; then
- ln -sf ${IMAGE_NAME}.license_manifest ${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.license_manifest
- ln -sf ${IMAGE_NAME}.license_manifest.csv ${IMGDEPLOYDIR}/${IMAGE_LINK_NAME}.license_manifest.csv
- fi
-}
diff --git a/meta-mentor-common/classes/feature_overrides.bbclass b/meta-mentor-common/classes/feature_overrides.bbclass
deleted file mode 100644
index 37f5a712..00000000
--- a/meta-mentor-common/classes/feature_overrides.bbclass
+++ /dev/null
@@ -1,32 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# This class eases conditional additions to OVERRIDES, which makes it easier
-# to create yocto-compatible layers. This is similar to distrooverrides.bbclass,
-# but is more generic.
-#
-# Example usage, in conf/layer.conf:
-#
-# INHERIT:append = " feature_overrides"
-# FEATUREOVERRIDES .= "${@bb.utils.contains('DISTRO_FEATURES', 'some-feature', ':feature-some-feature', '', d)}"
-# FEATUREOVERRIDES .= "${@bb.utils.contains('MACHINE_FEATURES', 'some-bsp-feature', ':feature-some-bsp-feature', '', d)}"
-
-python add_feature_overrides () {
- feature_overrides = filter(None, d.getVar('FEATUREOVERRIDES').split(':'))
- if feature_overrides:
- d.prependVar('OVERRIDES', ':'.join(unique_everseen(feature_overrides)) + ':')
-}
-add_feature_overrides[eventmask] = "bb.event.ConfigParsed"
-addhandler add_feature_overrides
-
-def unique_everseen(iterable):
- "List unique elements, preserving order. Remember all elements ever seen."
- # unique_everseen('AAAABBBCCDAABBB') --> A B C D
- # unique_everseen('ABBCcAD', str.lower) --> A B C D
- import itertools
- seen = set()
- seen_add = seen.add
- for element in itertools.filterfalse(seen.__contains__, iterable):
- seen_add(element)
- yield element
diff --git a/meta-mentor-common/classes/image-root-password.bbclass b/meta-mentor-common/classes/image-root-password.bbclass
deleted file mode 100644
index 3d87440c..00000000
--- a/meta-mentor-common/classes/image-root-password.bbclass
+++ /dev/null
@@ -1,45 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Enable use of the 'ROOT_PASSWORD' variable to set the root password for your
-# image or images. In addition to setting to a specific password, it also
-# handles special cases. If set to '0', empty root password is explicitly
-# allowed. If set to '*', root login is explicitly disabled. This also changes
-# the default behavior when ROOT_PASSWORD is empty -- if the image lacks
-# debug-tweaks and empty-root-password, the image qa check will fail, as the
-# user will have no way to login.
-
-ROOT_PASSWORD ?= ""
-IMAGE_INCOMPATIBLE_ZAPPED_MESSAGE = "ROOT_PASSWORD has not been set, and this \
-image has neither debug-tweaks nor empty-root-password set. This will result \
-in an image whose root login is disabled. Please set ROOT_PASSWORD to the root \
-password, to '*' to explicitly disable root login, or to '0' to explicitly \
-allow root login with an empty password."
-
-EMPTY_ROOT_PASSWORD = "${@'empty-root-password' if d.getVar('ROOT_PASSWORD', True) == '0' else ''}"
-IMAGE_FEATURES += "${EMPTY_ROOT_PASSWORD}"
-
-inherit extrausers
-
-# This variable indirection allows for the possibility of programmatically
-# generating the root password, if so desired, without mucking up bitbake's
-# variable checksums.
-ACTUAL_ROOT_PASSWORD = "${ROOT_PASSWORD}"
-EXTRA_USERS_PARAMS:prepend = "${@'usermod -P \'${ACTUAL_ROOT_PASSWORD}\' root;' if d.getVar('ACTUAL_ROOT_PASSWORD') not in ['', '0', '*'] else ''}"
-
-# Change the default behavior when the root password is empty. If the image
-# lacks empty-root-password and debug-tweaks, rather than defaulting to
-# disabling root login, error out. The user can explicitly opt-in to the old
-# behavior with this class inherited by setting ROOT_PASSWORD to '*'.
-IMAGE_QA_COMMANDS += "image_check_zapped_root_password"
-python image_check_zapped_root_password () {
- root_password = d.getVar('ROOT_PASSWORD')
- zapped_empty = bb.utils.contains_any('IMAGE_FEATURES', ['debug-tweaks', 'empty-root-password'], False, True, d)
- if not root_password and zapped_empty:
- message = d.getVar('IMAGE_INCOMPATIBLE_ZAPPED_MESSAGE')
- raise oe.utils.ImageQAFailed(message, 'image_check_zapped_root_password')
-}
-
-# Skip the QA check for initramfs images
-IMAGE_QA_COMMANDS:remove = "${@'image_check_zapped_root_password' if d.getVar('IMAGE_FSTYPES') == d.getVar('INITRAMFS_FSTYPES') != '' else ''}"
diff --git a/meta-mentor-common/classes/image-sdk-multilib-variants.bbclass b/meta-mentor-common/classes/image-sdk-multilib-variants.bbclass
deleted file mode 100644
index d75209e8..00000000
--- a/meta-mentor-common/classes/image-sdk-multilib-variants.bbclass
+++ /dev/null
@@ -1,18 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# For multilib variants not listed in SDK_MULTILIB_VARIANTS, remove
-# SDK_DEFAULT_TARGET_PKGS from TOOLCHAIN_TARGET_TASK
-#
-# This allows us to control which multilibs get the default sdk target
-# packages installed, by altering SDK_MULTILIB_VARIANTS to differ from
-# MULTILIB_VARIANTS.
-
-MULTILIB_VARIANTS ??= ""
-SDK_MULTILIB_VARIANTS ??= "${MULTILIB_VARIANTS}"
-SDK_DEFAULT_TARGET_PKGS ?= "packagegroup-core-standalone-sdk-target packagegroup-core-standalone-sdk-target-dbg"
-
-SDK_MULTILIB_VARIANTS_REMOVE = "${@' '.join(set('${MULTILIB_VARIANTS}'.split()) - set('${SDK_MULTILIB_VARIANTS}'.split()))}"
-SDK_TARGET_REMOVE = "${@' '.join(v + '-' + p for p in '${SDK_DEFAULT_TARGET_PKGS}'.split() for v in '${SDK_MULTILIB_VARIANTS_REMOVE}'.split())}"
-TOOLCHAIN_TARGET_TASK:remove = "${SDK_TARGET_REMOVE}"
diff --git a/meta-mentor-common/classes/incompatible-packages-check.bbclass b/meta-mentor-common/classes/incompatible-packages-check.bbclass
deleted file mode 100644
index 2ee0d03c..00000000
--- a/meta-mentor-common/classes/incompatible-packages-check.bbclass
+++ /dev/null
@@ -1,27 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-def any_incompatible(d, packages, licensestring=None):
- """Return True if any of the specified packages are skipped due to incompatible license.
-
- The user may specify the package's license for cross-recipe checks.
- """
- bad_licenses = (d.getVar('INCOMPATIBLE_LICENSE') or "").split()
- if not bad_licenses:
- return False
- bad_licenses = expand_wildcard_licenses(d, bad_licenses)
-
- if licensestring is None:
- licensestring = d.getVar("LICENSE:%s" % package) if package else None
- if not licensestring:
- licensestring = d.getVar('LICENSE')
-
- exceptions = (d.getVar("INCOMPATIBLE_LICENSE_EXCEPTIONS") or "").split()
- for pkg in packages:
- remaining_bad_licenses = oe.license.apply_pkg_license_exception(pkg, bad_licenses, exceptions)
-
- incompatible_lic = incompatible_pkg_license(d, remaining_bad_licenses, licensestring)
- if incompatible_lic:
- return True
- return False
diff --git a/meta-mentor-common/classes/isolated-sstate-dir.bbclass b/meta-mentor-common/classes/isolated-sstate-dir.bbclass
deleted file mode 100644
index e24d7786..00000000
--- a/meta-mentor-common/classes/isolated-sstate-dir.bbclass
+++ /dev/null
@@ -1,75 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Populate an isolated SSTATE_DIR while still populating the default shared
-# sstate directory. This is useful if SSTATE_DIR is shared, so we have access
-# to the set of cached binaries which were used in this build.
-
-ISOLATED_SSTATE_DIR ?= "${TMPDIR}/sstate-cache"
-ISOLATED_SSTATE_PATHSPEC = "${@SSTATE_PATHSPEC.replace(SSTATE_DIR + '/', ISOLATED_SSTATE_DIR + '/')}"
-
-sstate_write_isolated () {
- if [ -n "${ISOLATED_SSTATE_DIR}" ] && \
- [ "${ISOLATED_SSTATE_DIR}" != "${SSTATE_DIR}" ]; then
- isolated_dest=$(echo ${SSTATE_PKG} | sed 's,^${SSTATE_DIR}/,${ISOLATED_SSTATE_DIR}/,')
- mkdir -p $(dirname $isolated_dest)
- rm -f $isolated_dest $isolated_dest.siginfo
- ln -s ${SSTATE_PKG} $isolated_dest
- ln -s ${SSTATE_PKG}.siginfo $isolated_dest.siginfo
- fi
-}
-
-sstate_create_package:append () {
- sstate_write_isolated
-}
-# Work around missing vardep bug in bitbake
-sstate_create_package[vardeps] += "sstate_write_isolated"
-
-# Copy existing/fetched archives from SSTATE_DIR to ISOLATED_SSTATE_DIR
-sstate_write_isolated_preinst () {
- sstate_write_isolated
-}
-
-SSTATEPREINSTFUNCS:append = " sstate_write_isolated_preinst"
-
-def cleansstate_isolated(d):
- if d.getVar('ISOLATED_SSTATE_DIR', True) != d.getVar('SSTATE_DIR', True):
- l = d.createCopy()
- l.setVar('SSTATE_PATHSPEC', d.getVar('ISOLATED_SSTATE_PATHSPEC', True))
- sstate_clean_cachefiles(l)
-
-python do_cleansstate:append() {
- cleansstate_isolated(d)
-}
-
-# Sadly, there's no way to guarantee event handler execution order, so we need
-# to duplicate the bits to dump the siginfo to SSTATE_DIR.
-addhandler isolated_sstate_eventhandler
-isolated_sstate_eventhandler[eventmask] = "bb.build.TaskSucceeded"
-python isolated_sstate_eventhandler() {
- sstate_dir = d.getVar('SSTATE_DIR', True)
- isolated_sstate_dir = d.getVar('ISOLATED_SSTATE_DIR', True)
- if sstate_dir == isolated_sstate_dir:
- return
-
- # When we write an sstate package we rewrite the SSTATE_PKG
- spkg = d.getVar('SSTATE_PKG', True)
- if not spkg.endswith(".tgz"):
- taskname = d.getVar("BB_RUNTASK", True)[3:]
- spec = d.getVar('SSTATE_PKGSPEC', True)
- swspec = d.getVar('SSTATE_SWSPEC', True)
- if taskname in ["fetch", "unpack", "patch", "populate_lic"] and swspec:
- d.setVar("SSTATE_PKGSPEC", "${SSTATE_SWSPEC}")
- d.setVar("SSTATE_EXTRAPATH", "")
- sstatepkg = d.getVar('SSTATE_PKG', True)
- fn = sstatepkg + '_' + taskname + '.tgz.siginfo'
- if not os.path.exists(fn):
- bb.utils.mkdirhier(os.path.dirname(fn))
- bb.siggen.dump_this_task(fn, d)
-
- isolated_fn = fn.replace(sstate_dir + '/', isolated_sstate_dir + '/')
- if not os.path.exists(isolated_fn):
- bb.utils.mkdirhier(os.path.dirname(isolated_fn))
- os.symlink(fn, isolated_fn)
-}
diff --git a/meta-mentor-common/classes/layerdirs.bbclass b/meta-mentor-common/classes/layerdirs.bbclass
deleted file mode 100644
index afb8a499..00000000
--- a/meta-mentor-common/classes/layerdirs.bbclass
+++ /dev/null
@@ -1,21 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-def save_layerdirs(d):
- for layerpath in d.getVar('BBLAYERS', True).split():
- layerconf = os.path.join(layerpath, 'conf', 'layer.conf')
-
- l = bb.data.init()
- l.setVar('LAYERDIR', layerpath)
- l = bb.parse.handle(layerconf, l)
- l.expandVarref('LAYERDIR')
-
- for layername in (l.getVar('BBFILE_COLLECTIONS', True) or '').split():
- d.setVar('LAYERDIR_%s' % layername, layerpath)
-
-python cfg_save_layerdirs () {
- save_layerdirs(d)
-}
-cfg_save_layerdirs[eventmask] = "bb.event.ConfigParsed"
-addhandler cfg_save_layerdirs
diff --git a/meta-mentor-common/classes/mentor-updates-check.bbclass b/meta-mentor-common/classes/mentor-updates-check.bbclass
deleted file mode 100644
index 9da0e647..00000000
--- a/meta-mentor-common/classes/mentor-updates-check.bbclass
+++ /dev/null
@@ -1,36 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# If any of these layers are available, but not included in BBLAYERS, warn
-UPDATES_CHECK_LAYERS ?= "\
- ${MELDIR}/updates/update-*/ \
- ${MELDIR}/update-*/ \
- ${MELDIR}/meta-mentor-cve \
-"
-UPDATES_CHECK_LAYERS[type] = "list"
-
-check_for_updates () {
- import glob
-
- layerpaths = []
- for pattern in oe.data.typed_value('UPDATES_CHECK_LAYERS', d):
- layerpaths.extend(glob.glob(pattern))
-
- if not layerpaths:
- return
-
- missing = set()
- bblayers = d.getVar('BBLAYERS', True).split()
- bblayers = set(os.path.realpath(p) for p in bblayers)
- for lpath in layerpaths:
- if not os.path.exists(os.path.join(lpath, 'conf', 'layer.conf')):
- continue
- if os.path.realpath(lpath) not in bblayers:
- missing.add(lpath)
-
- if missing:
- bb.warn("Update layers are available, but not configured. Please add to your bblayers.conf:\n %s" % '\n '.join(missing))
-}
-check_for_updates[eventmask] = "bb.event.ConfigParsed"
-addhandler check_for_updates
diff --git a/meta-mentor-common/classes/mirrors.bbclass b/meta-mentor-common/classes/mirrors.bbclass
deleted file mode 100644
index 17eaa0a5..00000000
--- a/meta-mentor-common/classes/mirrors.bbclass
+++ /dev/null
@@ -1,25 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-PREMIRRORS:append = " \
-git://sources.redhat.com/ git://sourceware.org/ \n\
-"
-
-MIRRORS += "\
-${KERNELORG_MIRROR}/ https://kernel.googlesource.com/ \n\
-${KERNELORG_MIRROR}/ http://mirror.nexcess.net/kernel.org/ \n\
-${KERNELORG_MIRROR}/ http://mirror.gbxs.net/pub/ \n\
-${APACHE_MIRROR}/ http://archive.apache.org/dist/ \n\
-${DEBIAN_MIRROR}/ ftp://archive.debian.org/debian/pool/ \n\
-git://git.kernel.org/pub/ http://mirror.nexcess.net/kernel.org/ \n\
-\
-(ftp|https?)://.*/.* http://autobuilder.yoctoproject.org/sources/ \n\
-(ftp|https?)://.*/.* http://sources.openembedded.org/ \n\
-(ftp|https?)://.*/.* http://www.angstrom-distribution.org/unstable/sources/ \n\
-\
-(cvs|svn|git|gitsm|hg|bzr|osc|p4|svk)://.*/.* http://downloads.yoctoproject.org/mirror/sources/ \n\
-(cvs|svn|git|gitsm|hg|bzr|osc|p4|svk)://.*/.* http://autobuilder.yoctoproject.org/sources/ \n\
-(cvs|svn|git|gitsm|hg|bzr|osc|p4|svk)://.*/.* http://sources.openembedded.org/ \n\
-(cvs|svn|git|gitsm|hg|bzr|osc|p4|svk)://.*/.* http://www.angstrom-distribution.org/unstable/sources/ \n\
-"
diff --git a/meta-mentor-common/classes/required_toolchain_config.bbclass b/meta-mentor-common/classes/required_toolchain_config.bbclass
deleted file mode 100644
index aae51ce5..00000000
--- a/meta-mentor-common/classes/required_toolchain_config.bbclass
+++ /dev/null
@@ -1,27 +0,0 @@
-# Sanity test for allowed toolchain configurations
-#
-# Must be explicitly enabled both by configuring these variables and
-# adding 'disallowed-tuning' to your WARN_QA or ERROR_QA.
-ALLOWED_TUNING ?= "${DEFAULTTUNE}"
-DISALLOWED_TUNING ?= ""
-
-python required_tuning () {
- def handle_error(error_class, error_msg, d):
- if error_class in (d.getVar("ERROR_QA") or "").split():
- bb.fatal("%s [%s]" % (error_msg, error_class))
- elif error_class in (d.getVar("WARN_QA") or "").split():
- bb.warn("%s [%s]" % (error_msg, error_class))
- else:
- bb.note("%s [%s]" % (error_msg, error_class))
- return True
-
- allowed = d.getVar('ALLOWED_TUNING')
- disallowed = d.getVar('DISALLOWED_TUNING')
- tuning = d.getVar('TUNE_PKGARCH')
- if tuning in disallowed.split():
- handle_error("disallowed-tuning", "TUNE_PKGARCH %s is disallowed by DISALLOWED_TUNING (%s)" % (tuning, disallowed), d)
- elif allowed and tuning not in allowed:
- handle_error("disallowed-tuning", "TUNE_PKGARCH %s is not allowed by ALLOWED_TUNING (%s)" % (tuning, allowed), d)
-}
-required_tuning[eventmask] = 'bb.event.SanityCheck'
-addhandler required_tuning
diff --git a/meta-mentor-common/classes/resize-rootfs-gplv3.bbclass b/meta-mentor-common/classes/resize-rootfs-gplv3.bbclass
deleted file mode 100644
index 815cb840..00000000
--- a/meta-mentor-common/classes/resize-rootfs-gplv3.bbclass
+++ /dev/null
@@ -1,29 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Warn the user and disable rootfs resizing for non-GPLv3 configurations
-#
-# We use two events, as it seems ConfigParsed is firing multiple times in
-# a build at the moment.
-
-inherit incompatible-packages-check
-
-python resize_gpl_warn () {
- if d.getVar('WARN_RESIZE_GPL', True):
- bb.warn('Resizing the root filesystem to the capacity of the media has been enabled in local.conf (WKS_FILE set to a non-fixed-size image, and 96boards-tools included in MACHINE_EXTRA_RECOMMENDS), however this is a GPL-3.0 incompatible build. This configuration is invalid, as the script we use requires recent GNU Parted, which is GPL-3.0. Removing 96boards-tools from MACHINE_EXTRA_RECOMMENDS. You may wish to alter WKS_FILE to a fixed size image in conf/local.conf, as otherwise the rootfs will not be the size of the media. Doing so, or commenting out the line which adds 96boards-tools, will silence this warning.')
-}
-resize_gpl_warn[eventmask] = "bb.event.BuildStarted"
-addhandler resize_gpl_warn
-
-python resize_gpl_check () {
- rrecs = d.getVar('MACHINE_EXTRA_RRECOMMENDS', True).split()
- if (any_incompatible(d, ['96boards-tools'], 'GPL-3.0-only') and
- '96boards-tools' in rrecs):
- wks_file = d.getVar('WKS_FILE', True)
- if wks_file.endswith('-sd.wks.in') or wks_file.endswith('.wks'):
- d.setVar('WARN_RESIZE_GPL', '1')
- d.setVar('MACHINE_EXTRA_RRECOMMENDS:remove', '96boards-tools')
-}
-resize_gpl_check[eventmask] = "bb.event.ConfigParsed"
-addhandler resize_gpl_check
diff --git a/meta-mentor-common/classes/sdk_latest_link.bbclass b/meta-mentor-common/classes/sdk_latest_link.bbclass
deleted file mode 100644
index a4ca4d05..00000000
--- a/meta-mentor-common/classes/sdk_latest_link.bbclass
+++ /dev/null
@@ -1,18 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-TOOLCHAIN_LINKNAME ?= "${@'${TOOLCHAIN_OUTPUTNAME}'.replace('-${SDK_VERSION}', '')}"
-
-SDK_POSTPROCESS_COMMAND:append = "create_sdk_link;"
-
-create_sdk_link () {
- if [ "${TOOLCHAIN_OUTPUTNAME}" != "${TOOLCHAIN_LINKNAME}" ]; then
- for f in "${TOOLCHAIN_OUTPUTNAME}"*; do
- if [ -e "$f" ]; then
- ln -sf "$f" "${TOOLCHAIN_LINKNAME}${f#${TOOLCHAIN_OUTPUTNAME}}"
- fi
- done
- fi
-}
-create_sdk_link[dirs] = "${SDK_DEPLOY}"
diff --git a/meta-mentor-common/classes/user_features.bbclass b/meta-mentor-common/classes/user_features.bbclass
deleted file mode 100644
index 385e7aa5..00000000
--- a/meta-mentor-common/classes/user_features.bbclass
+++ /dev/null
@@ -1,15 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# USER_FEATURES is an explicitly supported mechanism to exert control over
-# DISTRO_FEATURES from local.conf without directly poking at it. At this point
-# it's just a convenience wrapper around append and remove.
-#
-# To add a feature, simply add it to USER_FEATURES. To remove a feature, add
-# the feature prefixed by ~. For example: USER_FEATURES += "bluetooth"
-
-USER_FEATURES ?= ""
-USER_FEATURES_REMOVE ?= "${@' '.join(l[1:] for l in '${USER_FEATURES}'.split() if l.startswith('~'))}"
-DISTRO_FEATURES:append = " ${@' '.join(l for l in '${USER_FEATURES}'.split() if not l.startswith('~'))}"
-DISTRO_FEATURES:remove = "${USER_FEATURES_REMOVE}"
diff --git a/meta-mentor-common/conf/layer.conf b/meta-mentor-common/conf/layer.conf
deleted file mode 100644
index e31deefb..00000000
--- a/meta-mentor-common/conf/layer.conf
+++ /dev/null
@@ -1,13 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-BBPATH .= ":${LAYERDIR}"
-# BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
-# ${LAYERDIR}/recipes-*/*/*.bbappend"
-
-BBFILE_COLLECTIONS += "mentor-common"
-BBFILE_PATTERN_mentor-common = "^${LAYERDIR}/"
-BBFILE_PATTERN_IGNORE_EMPTY_mentor-common = "1"
-BBFILE_PRIORITY_mentor-common = "1"
-LAYERSERIES_COMPAT_mentor-common = "kirkstone"
diff --git a/meta-mentor-staging/README.md b/meta-mentor-staging/README.md
deleted file mode 100644
index 098bc551..00000000
--- a/meta-mentor-staging/README.md
+++ /dev/null
@@ -1,28 +0,0 @@
-Siemens Digital Industries Software Staging Layer for Yocto/OE
-==========================================
-
-This layer holds the bits we need for Mentor Embedded Linux Flex OS, but which we
-intend to get merged upstream. This is our staging area. Nothing should be in
-this layer permanently, other than layer.conf and associated bits.
-
-This layer depends on:
-
-URI: git://git.openembedded.org/openembedded-core
-Branch: master
-
-
-Contributing
-------------
-
-Browse url: http://git.yoctoproject.org/cgit/cgit.cgi/meta-mentor
-Clone url: git://git.yoctoproject.org/meta-mentor.git
-
-To contribute to this layer you should submit the patches for review to the
-mailing list.
-
-Mailing list: meta-mentor@yoctoproject.org
-
-When sending single patches, please use something like
-'git send-email -1 --subject-prefix 'PATCH][meta-mentor-staging' --to meta-mentor@yoctoproject.org'
-
-When sending a series, please use oe-core/scripts/create-pull-request.
diff --git a/meta-mentor-staging/classes/cve-check-all.bbclass b/meta-mentor-staging/classes/cve-check-all.bbclass
deleted file mode 100644
index 1ab571b0..00000000
--- a/meta-mentor-staging/classes/cve-check-all.bbclass
+++ /dev/null
@@ -1,17 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-inherit cve-check
-
-CVE_CHECK_LOG ?= "${LOG_DIR}/cve.log"
-
-do_cve_check_all () {
- cp ${CVE_CHECK_TMP_FILE} ${CVE_CHECK_LOG}
-}
-
-addtask cve_check_all after do_cve_check
-do_cve_check_all[dirs] = "${LOG_DIR}"
-do_cve_check_all[doc] = "Produce cve.log for all packages in given target without building them"
-do_cve_check_all[recrdeptask] = "do_cve_check_all do_cve_check"
-do_cve_check_all[nostamp] = "1"
diff --git a/meta-mentor-staging/classes/distutils-base.bbclass b/meta-mentor-staging/classes/distutils-base.bbclass
deleted file mode 100644
index 3c12f634..00000000
--- a/meta-mentor-staging/classes/distutils-base.bbclass
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-DEPENDS += "${@["${PYTHON_PN}-native ${PYTHON_PN}", ""][(d.getVar('PACKAGES') == '')]}"
-RDEPENDS:${PN} += "${@['', '${PYTHON_PN}-core']['${CLASSOVERRIDE}' == 'class-target']}"
-
-inherit distutils-common-base pythonnative
diff --git a/meta-mentor-staging/classes/distutils.bbclass b/meta-mentor-staging/classes/distutils.bbclass
deleted file mode 100644
index a0843ca2..00000000
--- a/meta-mentor-staging/classes/distutils.bbclass
+++ /dev/null
@@ -1,91 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-inherit distutils-base
-
-DISTUTILS_BUILD_ARGS ?= ""
-DISTUTILS_STAGE_HEADERS_ARGS ?= "--install-dir=${STAGING_INCDIR}/${PYTHON_DIR}"
-DISTUTILS_STAGE_ALL_ARGS ?= "--prefix=${STAGING_DIR_HOST}${prefix} \
- --install-data=${STAGING_DATADIR}"
-DISTUTILS_INSTALL_ARGS ?= "--root=${D} \
- --prefix=${prefix} \
- --install-lib=${PYTHON_SITEPACKAGES_DIR} \
- --install-data=${datadir}"
-
-DISTUTILS_PYTHON = "python"
-DISTUTILS_PYTHON:class-native = "nativepython"
-
-distutils_do_configure() {
- if [ "${CLEANBROKEN}" != "1" ] ; then
- NO_FETCH_BUILD=1 \
- ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py clean ${DISTUTILS_BUILD_ARGS}
- fi
-}
-
-distutils_do_compile() {
- NO_FETCH_BUILD=1 \
- STAGING_INCDIR=${STAGING_INCDIR} \
- STAGING_LIBDIR=${STAGING_LIBDIR} \
- ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py build ${DISTUTILS_BUILD_ARGS} || \
- bbfatal_log "'${PYTHON_PN} setup.py build ${DISTUTILS_BUILD_ARGS}' execution failed."
-}
-
-distutils_stage_headers() {
- install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
- ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS} || \
- bbfatal_log "'${PYTHON_PN} setup.py install_headers ${DISTUTILS_STAGE_HEADERS_ARGS}' execution for stage_headers failed."
-}
-
-distutils_stage_all() {
- STAGING_INCDIR=${STAGING_INCDIR} \
- STAGING_LIBDIR=${STAGING_LIBDIR} \
- install -d ${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR}
- PYTHONPATH=${STAGING_DIR_HOST}${PYTHON_SITEPACKAGES_DIR} \
- ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS} || \
- bbfatal_log "'${PYTHON_PN} setup.py install ${DISTUTILS_STAGE_ALL_ARGS}' execution for stage_all failed."
-}
-
-distutils_do_install() {
- install -d ${D}${PYTHON_SITEPACKAGES_DIR}
- STAGING_INCDIR=${STAGING_INCDIR} \
- STAGING_LIBDIR=${STAGING_LIBDIR} \
- PYTHONPATH=${D}${PYTHON_SITEPACKAGES_DIR} \
- ${STAGING_BINDIR_NATIVE}/${PYTHON_PN}-native/${PYTHON_PN} setup.py install ${DISTUTILS_INSTALL_ARGS} || \
- bbfatal_log "'${PYTHON_PN} setup.py install ${DISTUTILS_INSTALL_ARGS}' execution failed."
-
- # support filenames with *spaces*
- # only modify file if it contains path and recompile it
- find ${D} -name "*.py" -exec grep -q ${D} {} \; \
- -exec sed -i -e s:${D}::g {} \; \
- -exec ${STAGING_BINDIR_NATIVE}/python-native/python -mcompileall {} \;
-
- for i in ${D}${bindir}/* ${D}${sbindir}/*; do
- if [ -f "$i" ]; then
- sed -i -e s:${PYTHON}:${USRBINPATH}/env\ ${DISTUTILS_PYTHON}:g $i
- sed -i -e s:${STAGING_BINDIR_NATIVE}:${bindir}:g $i
- fi
- done
-
- rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/easy-install.pth
- rm -f ${D}${PYTHON_SITEPACKAGES_DIR}/site.py*
-
- #
- # FIXME: Bandaid against wrong datadir computation
- #
- if [ -e ${D}${datadir}/share ]; then
- mv -f ${D}${datadir}/share/* ${D}${datadir}/
- rmdir ${D}${datadir}/share
- fi
-
- # Fix backport modules
- if [ -e ${STAGING_LIBDIR}/${PYTHON_DIR}/site-packages/backports/__init__.py ] &&
- [ -e ${D}${PYTHON_SITEPACKAGES_DIR}/backports/__init__.py ]; then
- rm ${D}${PYTHON_SITEPACKAGES_DIR}/backports/__init__.py;
- rm ${D}${PYTHON_SITEPACKAGES_DIR}/backports/__init__.pyc;
- fi
-}
-
-EXPORT_FUNCTIONS do_configure do_compile do_install
-
-export LDSHARED="${CCLD} -shared"
diff --git a/meta-mentor-staging/classes/python-dir.bbclass b/meta-mentor-staging/classes/python-dir.bbclass
deleted file mode 100644
index 2d2dc40b..00000000
--- a/meta-mentor-staging/classes/python-dir.bbclass
+++ /dev/null
@@ -1,9 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-PYTHON_BASEVERSION = "2.7"
-PYTHON_ABI = ""
-PYTHON_DIR = "python${PYTHON_BASEVERSION}"
-PYTHON_PN = "python"
-PYTHON_SITEPACKAGES_DIR = "${libdir}/${PYTHON_DIR}/site-packages"
diff --git a/meta-mentor-staging/classes/pythonnative.bbclass b/meta-mentor-staging/classes/pythonnative.bbclass
deleted file mode 100644
index 0c0e813c..00000000
--- a/meta-mentor-staging/classes/pythonnative.bbclass
+++ /dev/null
@@ -1,30 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-inherit python-dir
-
-PYTHON="${STAGING_BINDIR_NATIVE}/python-native/python"
-# PYTHON_EXECUTABLE is used by cmake
-PYTHON_EXECUTABLE="${PYTHON}"
-EXTRANATIVEPATH += "python-native"
-DEPENDS:append = " python-native "
-
-# python-config and other scripts are using distutils modules
-# which we patch to access these variables
-export STAGING_INCDIR
-export STAGING_LIBDIR
-
-# Packages can use
-# find_package(PythonInterp REQUIRED)
-# find_package(PythonLibs REQUIRED)
-# which ends up using libs/includes from build host
-# Therefore pre-empt that effort
-export PYTHON_LIBRARY="${STAGING_LIBDIR}/lib${PYTHON_DIR}${PYTHON_ABI}.so"
-export PYTHON_INCLUDE_DIR="${STAGING_INCDIR}/${PYTHON_DIR}${PYTHON_ABI}"
-
-# suppress host user's site-packages dirs.
-export PYTHONNOUSERSITE = "1"
-
-# autoconf macros will use their internal default preference otherwise
-export PYTHON
diff --git a/meta-mentor-staging/classes/setuptools.bbclass b/meta-mentor-staging/classes/setuptools.bbclass
deleted file mode 100644
index ac14c0c3..00000000
--- a/meta-mentor-staging/classes/setuptools.bbclass
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-inherit distutils
-
-DEPENDS += "python-setuptools-native"
diff --git a/meta-mentor-staging/classes/toolchain_ship_relocate_sdk.bbclass b/meta-mentor-staging/classes/toolchain_ship_relocate_sdk.bbclass
deleted file mode 100644
index b7a1b615..00000000
--- a/meta-mentor-staging/classes/toolchain_ship_relocate_sdk.bbclass
+++ /dev/null
@@ -1,12 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-RELOCATE_SDK_SH ?= "${@bb.utils.which(d.getVar('BBPATH'), 'scripts/relocate_sdk.sh')}"
-
-create_sdk_files:append () {
- install -m 0755 ${RELOCATE_SDK_SH} ${SDK_OUTPUT}/${SDKPATH}/relocate_sdk.sh
- sed -i -e "s:@SDKPATH@:${SDKPATH}:g; s:##DEFAULT_INSTALL_DIR##:$escaped_sdkpath:" ${SDK_OUTPUT}/${SDKPATH}/relocate_sdk.sh
-}
-
-do_populate_sdk[file-checksums] += "${RELOCATE_SDK_SH}:True"
diff --git a/meta-mentor-staging/classes/win_sdk_cull.bbclass b/meta-mentor-staging/classes/win_sdk_cull.bbclass
deleted file mode 100644
index 00dd5893..00000000
--- a/meta-mentor-staging/classes/win_sdk_cull.bbclass
+++ /dev/null
@@ -1,26 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-SDK_POSTPROCESS_COMMAND:prepend:sdkmingw32 = "cull_win_files;"
-
-cull_win_files () {
- # Cull duplicates caused by case insensitive filesytems, e.g. NTFS
- cd "${SDK_OUTPUT}"
- find . >cull.filelist
- cat cull.filelist | tr '[:upper:]' '[:lower:]' | sort | uniq -d | \
- while read case_dupe; do
- # Remove all but one of each set of duplicates
- bbnote "Keeping first case duplicate '$(grep -xi "$case_dupe" cull.filelist | sed -n '1p')'"
- grep -xi "$case_dupe" cull.filelist | sed '1d' | while read actual; do
- bbwarn "Removing case duplicate '${actual#.}' for windows SDKMACHINE"
- rm -rf "$actual"
- done
- done
-
- # Cull paths with invalid characters
- grep -E "\\\\|\?|:|\*|\"|<|>|\|" cull.filelist | while read invalid; do
- bbwarn "Removing file with invalid characters for windows SDKMACHINE: ${invalid#.}"
- rm "$invalid"
- done
-}
diff --git a/meta-mentor-staging/classes/xsctyaml.bbclass b/meta-mentor-staging/classes/xsctyaml.bbclass
deleted file mode 100644
index 26fe17bc..00000000
--- a/meta-mentor-staging/classes/xsctyaml.bbclass
+++ /dev/null
@@ -1,90 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-inherit python3native
-
-DEPENDS += "python3-pyyaml-native"
-PYTHON_SITEPACKAGES_DIR_NATIVE = "${libdir_native}/${PYTHON_DIR}/site-packages"
-YAML_APP_CONFIG ?= ''
-YAML_BSP_CONFIG ?= ''
-YAML_FILE_PATH ?= ''
-YAML_DT_BOARD_FLAGS ?= ''
-YAML_SERIAL_CONSOLE_STDIN ?= ''
-YAML_SERIAL_CONSOLE_STDOUT ?= ''
-YAML_MAIN_MEMORY_CONFIG ?= ''
-YAML_CONSOLE_DEVICE_CONFIG ?= ''
-YAML_FLASH_MEMORY_CONFIG ?= ''
-
-YAML_SERIAL_CONSOLE_STDIN_ultra96-zynqmp ?= "psu_uart_1"
-YAML_SERIAL_CONSOLE_STDOUT_ultra96-zynqmp ?= "psu_uart_1"
-
-YAML_FILE_PATH = "${WORKDIR}/${PN}.yaml"
-XSCTH_MISC:append = " -yamlconf ${YAML_FILE_PATH}"
-
-YAML_BUILD_CONFIG ?= "${@d.getVar('XSCTH_BUILD_CONFIG', True).lower()}"
-YAML_APP_CONFIG += "${@'build-config' if d.getVar('YAML_BUILD_CONFIG', True) != '' else ''}"
-YAML_APP_CONFIG[build-config] = "set,${YAML_BUILD_CONFIG}"
-
-YAML_COMPILER_FLAGS ?= "${@d.getVar('XSCTH_COMPILER_DEBUG_FLAGS', True) if d.getVar('XSCTH_BUILD_DEBUG', True) != "0" else d.getVar('XSCTH_APP_COMPILER_FLAGS', True)}"
-YAML_APP_CONFIG += "${@'compiler-misc' if d.getVar('YAML_COMPILER_FLAGS', True) != '' else ''}"
-YAML_APP_CONFIG[compiler-misc] = "add,${YAML_COMPILER_FLAGS}"
-
-YAML_BSP_CONFIG += "${@'periph_type_overrides' if d.getVar('YAML_DT_BOARD_FLAGS', True) != '' else ''}"
-YAML_BSP_CONFIG[periph_type_overrides] = "set,${YAML_DT_BOARD_FLAGS}"
-
-YAML_BSP_CONFIG += "${@'stdin' if d.getVar('YAML_SERIAL_CONSOLE_STDIN', True) != '' else ''}"
-YAML_BSP_CONFIG[stdin] = "set,${YAML_SERIAL_CONSOLE_STDIN}"
-
-YAML_BSP_CONFIG += "${@'stdout' if d.getVar('YAML_SERIAL_CONSOLE_STDOUT', True) != '' else ''}"
-YAML_BSP_CONFIG[stdout] = "set,${YAML_SERIAL_CONSOLE_STDOUT}"
-
-YAML_BSP_CONFIG += "${@'main_memory' if d.getVar('YAML_MAIN_MEMORY_CONFIG', True) != '' else ''}"
-YAML_BSP_CONFIG[main_memory] = "set,${YAML_MAIN_MEMORY_CONFIG}"
-
-
-YAML_BSP_CONFIG += "${@'flash_memory' if d.getVar('YAML_FLASH_MEMORY_CONFIG', True) != '' else ''}"
-YAML_BSP_CONFIG[flash_memory] = "set,${YAML_FLASH_MEMORY_CONFIG}"
-
-YAML_BSP_CONFIG += "${@'console_device' if d.getVar('YAML_CONSOLE_DEVICE_CONFIG', True) != '' else ''}"
-YAML_BSP_CONFIG[console_device] = "set,${YAML_CONSOLE_DEVICE_CONFIG}"
-
-def patch_yaml(config, configflags, type, type_dict, d):
- import re
- for cfg in config:
- if cfg not in configflags:
- error_msg = "%s: invalid CONFIG" % (cfg)
- bb.error("YAML config Issue: %s " % (error_msg))
- else:
- cfgval = configflags[cfg].split(',', 1)
- val = d.expand(cfgval[1])
- type_dict[type].update({cfg: {re.sub(r'\s','',cfgval[0]): val}})
-
- return type_dict
-
-python do_create_yaml() {
- import sys, os
- os.sys.path.append(os.path.join(d.getVar('RECIPE_SYSROOT_NATIVE'),d.getVar('PYTHON_SITEPACKAGES_DIR_NATIVE')[1::]))
- import yaml
- yaml_dict = {}
-
- appconfig = (d.getVar("YAML_APP_CONFIG", True) or "").split()
- if appconfig:
- yaml_dict.update({'app': {}})
- configflags = d.getVarFlags("YAML_APP_CONFIG") or {}
- yaml_dict = patch_yaml(appconfig, configflags, 'app', yaml_dict, d)
-
- bspconfig = (d.getVar("YAML_BSP_CONFIG", True) or "").split()
- if bspconfig:
- yaml_dict.update({'bsp': {}})
- configflags = d.getVarFlags("YAML_BSP_CONFIG") or {}
- yaml_dict = patch_yaml(bspconfig, configflags, 'bsp', yaml_dict, d)
-
- if len(yaml_dict) != 0:
- fp = d.getVar("YAML_FILE_PATH", True)
- if fp :
- yamlfile = open(fp, 'w')
- yamlfile.write(yaml.dump(yaml_dict, default_flow_style=True, width=2000))
-}
-
-addtask create_yaml after do_prepare_recipe_sysroot before do_configure
diff --git a/meta-mentor-staging/conf/layer.conf b/meta-mentor-staging/conf/layer.conf
deleted file mode 100644
index 3845e23c..00000000
--- a/meta-mentor-staging/conf/layer.conf
+++ /dev/null
@@ -1,29 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-BBPATH .= ":${LAYERDIR}"
-BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \
- ${LAYERDIR}/recipes-*/*/*.bbappend"
-
-# Let us add layer-specific bb/bbappends which are only applied when that
-# layer is included in our configuration
-BBFILES += "${@' '.join('${LAYERDIR}/%s/recipes*/*/*.bbappend' % layer \
- for layer in BBFILE_COLLECTIONS.split())}"
-BBFILES += "${@' '.join('${LAYERDIR}/%s/recipes*/*/*.bb' % layer \
- for layer in BBFILE_COLLECTIONS.split())}"
-
-LAYERDIR_RE ?= "${LAYERDIR}"
-LAYERDIR_mentor-staging = "${LAYERDIR}"
-BBFILE_COLLECTIONS += "mentor-staging"
-BBFILE_PRIORITY_mentor-staging = "10"
-BBFILE_PATTERN_mentor-staging = "^${LAYERDIR_RE}/"
-LAYERDEPENDS_mentor-staging = "core mentor-common"
-LAYERSERIES_COMPAT_mentor-staging = "kirkstone"
-
-# We don't want systemd and everything depending on systemd to rebuild when
-# the metadata stored in os-release changes. TODO: push this to oe-core
-SIGGEN_EXCLUDERECIPES_ABISAFE:append:feature-mentor-staging = " os-release"
-
-INHERIT:append = " feature_overrides"
-FEATUREOVERRIDES .= "${@bb.utils.contains('DISTRO_FEATURES', 'mentor-staging', ':feature-mentor-staging', '', d)}"
diff --git a/meta-mentor-staging/efibootguard/recipes-bsp/efibootguard/efibootguard_%.bbappend b/meta-mentor-staging/efibootguard/recipes-bsp/efibootguard/efibootguard_%.bbappend
deleted file mode 100644
index e2ff60d5..00000000
--- a/meta-mentor-staging/efibootguard/recipes-bsp/efibootguard/efibootguard_%.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/${BPN}:"
-
-SRC_URI:append:feature-mentor-staging = " file://0001-ebgpart-fix-conflict-with-__unused-in-system-headers.patch"
diff --git a/meta-mentor-staging/files/relocate_sdk.sh b/meta-mentor-staging/files/relocate_sdk.sh
deleted file mode 100644
index 6d22ca3b..00000000
--- a/meta-mentor-staging/files/relocate_sdk.sh
+++ /dev/null
@@ -1,85 +0,0 @@
-#!/bin/bash
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-target_sdk_dir="$(cd "$(dirname "$0")" && pwd -P)"
-default_sdk_dir="@SDKPATH@"
-
-# fix environment paths
-for env_setup_script in $target_sdk_dir/environment-setup-*; do
- if [ ! -e "$env_setup_script" ]; then
- continue
- fi
- sed -e "s:$default_sdk_dir:$target_sdk_dir:g" -i "$env_setup_script"
-done
-
-if ! xargs --version > /dev/null 2>&1; then
- echo "xargs is required by the relocation script, please install it first. Abort!"
- exit 1
-fi
-
-scriptdir="$target_sdk_dir" eval "$(grep 'OECORE_NATIVE_SYSROOT=' "$env_setup_script" | head -n 1)"
-native_sysroot="$OECORE_NATIVE_SYSROOT"
-
-# replace $default_sdk_dir with the new prefix in all text files: configs/scripts/etc.
-# replace the host perl with SDK perl.
-for replace in "$target_sdk_dir -maxdepth 1" "$native_sysroot"; do
- find $replace -type f 2>/dev/null
-done | xargs -n100 file | grep ":.*\(ASCII\|script\|source\).*text" | \
- awk -F':' '{printf "\"%s\"\n", $1}' | \
- grep -Ev "$target_sdk_dir/(environment-setup-*|relocate_sdk*|${0##*/})" | \
- xargs -n100 sed -i \
- -e "s:$default_sdk_dir:$target_sdk_dir:g" \
- -e "s:^#! */usr/bin/perl.*:#! /usr/bin/env perl:g" \
- -e "s: /usr/bin/perl: /usr/bin/env perl:g"
-
-if [ -e "$native_sysroot/lib" ]; then
- for py in python python2 python3; do
- PYTHON=`which ${py} 2>/dev/null`
- if [ $? -eq 0 ]; then
- break;
- fi
- done
-
- if [ x${PYTHON} = "x" ]; then
- echo "SDK could not be relocated. No python found."
- exit 1
- fi
-
- dl_path=$(find $native_sysroot/lib -name "ld-linux*")
- if [ "$dl_path" = "" ] ; then
- echo "SDK could not be set up. Relocate script unable to find ld-linux.so. Abort!"
- exit 1
- fi
-
- find $native_sysroot -type f \
- \( -perm -0100 -o -perm -0010 -o -perm -0001 \) -print0 | \
- xargs -0 ${PYTHON} ${env_setup_script%/*}/relocate_sdk.py $target_sdk_dir $dl_path
- if [ $? -ne 0 ]; then
- echo "Failed to run ${env_setup_script%/*}/relocate_sdk.py. Abort!"
- exit 1
- fi
-
- # change all symlinks pointing to $default_sdk_dir
- for l in $(find $native_sysroot -type l); do
- ln -sfn $(readlink $l|sed -e "s:$default_sdk_dir:$target_sdk_dir:") $l
- if [ $? -ne 0 ]; then
- echo "Failed to setup symlinks. Relocate script failed. Abort!"
- exit 1
- fi
- done
-fi
-
-# Execute post-relocation script
-post_relocate="$target_sdk_dir/post-relocate-setup.sh"
-if [ -e "$post_relocate" ]; then
- sed -e "s:$default_sdk_dir:$target_sdk_dir:g" -i $post_relocate
- /bin/sh $post_relocate "$target_sdk_dir" "$default_sdk_dir"
- if [ $? -ne 0 ]; then
- echo "Failed to run $post_relocate. Abort!"
- exit 1
- fi
- rm -f $post_relocate
-fi
diff --git a/meta-mentor-staging/files/toolchain-shar-extract.sh b/meta-mentor-staging/files/toolchain-shar-extract.sh
deleted file mode 100644
index 38367c0e..00000000
--- a/meta-mentor-staging/files/toolchain-shar-extract.sh
+++ /dev/null
@@ -1,265 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-[ -z "$ENVCLEANED" ] && exec /usr/bin/env -i ENVCLEANED=1 HOME="$HOME" \
- LC_ALL=en_US.UTF-8 \
- TERM=$TERM \
- http_proxy="$http_proxy" https_proxy="$https_proxy" ftp_proxy="$ftp_proxy" \
- no_proxy="$no_proxy" all_proxy="$all_proxy" GIT_PROXY_COMMAND="$GIT_PROXY_COMMAND" "$0" "$@"
-[ -f /etc/environment ] && . /etc/environment
-export PATH=`echo "$PATH" | sed -e 's/:\.//' -e 's/::/:/'`
-
-tweakpath () {
- case ":${PATH}:" in
- *:"$1":*)
- ;;
- *)
- PATH=$PATH:$1
- esac
-}
-
-# Some systems don't have /usr/sbin or /sbin in the cleaned environment PATH but we make need it
-# for the system's host tooling checks
-tweakpath /usr/sbin
-tweakpath /sbin
-
-INST_ARCH=$(uname -m | sed -e "s/i[3-6]86/ix86/" -e "s/x86[-_]64/x86_64/")
-SDK_ARCH=$(echo @SDK_ARCH@ | sed -e "s/i[3-6]86/ix86/" -e "s/x86[-_]64/x86_64/")
-
-INST_GCC_VER=$(gcc --version | sed -ne 's/.* \([0-9]\+\.[0-9]\+\)\.[0-9]\+.*/\1/p')
-SDK_GCC_VER='@SDK_GCC_VER@'
-
-verlte () {
- [ "$1" = "`printf "$1\n$2" | sort -V | head -n1`" ]
-}
-
-verlt() {
- [ "$1" = "$2" ] && return 1 || verlte $1 $2
-}
-
-verlt `uname -r` @OLDEST_KERNEL@
-if [ $? = 0 ]; then
- echo "Error: The SDK needs a kernel > @OLDEST_KERNEL@"
- exit 1
-fi
-
-if [ "$INST_ARCH" != "$SDK_ARCH" ]; then
- # Allow for installation of ix86 SDK on x86_64 host
- if [ "$INST_ARCH" != x86_64 -o "$SDK_ARCH" != ix86 ]; then
- echo "Error: Incompatible SDK installer! Your host is $INST_ARCH and this SDK was built for $SDK_ARCH hosts."
- exit 1
- fi
-fi
-
-if ! xz -V > /dev/null 2>&1; then
- echo "Error: xz is required for installation of this SDK, please install it first"
- exit 1
-fi
-
-DEFAULT_INSTALL_DIR="@SDKPATH@"
-SUDO_EXEC=""
-EXTRA_TAR_OPTIONS=""
-target_sdk_dir=""
-answer=""
-relocate=1
-savescripts=0
-verbose=0
-publish=0
-listcontents=0
-while getopts ":yd:npDRSl" OPT; do
- case $OPT in
- y)
- answer="Y"
- ;;
- d)
- target_sdk_dir=$OPTARG
- ;;
- n)
- prepare_buildsystem="no"
- ;;
- p)
- prepare_buildsystem="no"
- publish=1
- ;;
- D)
- verbose=1
- ;;
- R)
- relocate=0
- savescripts=1
- ;;
- S)
- savescripts=1
- ;;
- l)
- listcontents=1
- ;;
- *)
- echo "Usage: $(basename $0) [-y] [-d <dir>]"
- echo " -y Automatic yes to all prompts"
- echo " -d <dir> Install the SDK to <dir>"
- echo "======== Extensible SDK only options ============"
- echo " -n Do not prepare the build system"
- echo " -p Publish mode (implies -n)"
- echo "======== Advanced DEBUGGING ONLY OPTIONS ========"
- echo " -S Save relocation scripts"
- echo " -R Do not relocate executables"
- echo " -D use set -x to see what is going on"
- echo " -l list files that will be extracted"
- exit 1
- ;;
- esac
-done
-
-payload_offset=$(($(grep -na -m1 "^MARKER:$" $0|cut -d':' -f1) + 1))
-if [ "$listcontents" = "1" ] ; then
- tail -n +$payload_offset $0| tar tvJ || exit 1
- exit
-fi
-
-titlestr="@SDK_TITLE@ installer version @SDK_VERSION@"
-printf "%s\n" "$titlestr"
-printf "%${#titlestr}s\n" | tr " " "="
-
-if [ $verbose = 1 ] ; then
- set -x
-fi
-
-@SDK_PRE_INSTALL_COMMAND@
-
-# SDK_EXTENSIBLE is exposed from the SDK_PRE_INSTALL_COMMAND above
-if [ "$SDK_EXTENSIBLE" = "1" ]; then
- DEFAULT_INSTALL_DIR="@SDKEXTPATH@"
- if [ "$INST_GCC_VER" = '4.8' -a "$SDK_GCC_VER" = '4.9' ] || [ "$INST_GCC_VER" = '4.8' -a "$SDK_GCC_VER" = '' ] || \
- [ "$INST_GCC_VER" = '4.9' -a "$SDK_GCC_VER" = '' ]; then
- echo "Error: Incompatible SDK installer! Your host gcc version is $INST_GCC_VER and this SDK was built by gcc higher version."
- exit 1
- fi
-fi
-
-if [ "$target_sdk_dir" = "" ]; then
- if [ "$answer" = "Y" ]; then
- target_sdk_dir="$DEFAULT_INSTALL_DIR"
- else
- read -p "Enter target directory for SDK (default: $DEFAULT_INSTALL_DIR): " target_sdk_dir
- [ "$target_sdk_dir" = "" ] && target_sdk_dir=$DEFAULT_INSTALL_DIR
- fi
-fi
-
-eval target_sdk_dir=$(echo "$target_sdk_dir"|sed 's/ /\\ /g')
-if [ -d "$target_sdk_dir" ]; then
- target_sdk_dir=$(cd "$target_sdk_dir"; pwd)
-else
- target_sdk_dir=$(readlink -m "$target_sdk_dir")
-fi
-
-# limit the length for target_sdk_dir, ensure the relocation behaviour in relocate_sdk.py has right result.
-if [ ${#target_sdk_dir} -gt 2048 ]; then
- echo "Error: The target directory path is too long!!!"
- exit 1
-fi
-
-if [ "$SDK_EXTENSIBLE" = "1" ]; then
- # We're going to be running the build system, additional restrictions apply
- if echo "$target_sdk_dir" | grep -q '[+\ @$]'; then
- echo "The target directory path ($target_sdk_dir) contains illegal" \
- "characters such as spaces, @, \$ or +. Abort!"
- exit 1
- fi
- # The build system doesn't work well with /tmp on NFS
- fs_dev_path="$target_sdk_dir"
- while [ ! -d "$fs_dev_path" ] ; do
- fs_dev_path=`dirname $fs_dev_path`
- done
- fs_dev_type=`stat -f -c '%t' "$fs_dev_path"`
- if [ "$fsdevtype" = "6969" ] ; then
- echo "The target directory path $target_sdk_dir is on NFS, this is not possible. Abort!"
- exit 1
- fi
-else
- if [ -n "$(echo $target_sdk_dir|grep ' ')" ]; then
- echo "The target directory path ($target_sdk_dir) contains spaces. Abort!"
- exit 1
- fi
-fi
-
-if [ -e "$target_sdk_dir/environment-setup-@REAL_MULTIMACH_TARGET_SYS@" ]; then
- echo "The directory \"$target_sdk_dir\" already contains a SDK for this architecture."
- printf "If you continue, existing files will be overwritten! Proceed[y/N]? "
-
- default_answer="n"
-else
- printf "You are about to install the SDK to \"$target_sdk_dir\". Proceed[Y/n]? "
-
- default_answer="y"
-fi
-
-if [ "$answer" = "" ]; then
- read answer
- [ "$answer" = "" ] && answer="$default_answer"
-else
- echo $answer
-fi
-
-if [ "$answer" != "Y" -a "$answer" != "y" ]; then
- echo "Installation aborted!"
- exit 1
-fi
-
-# Try to create the directory (this will not succeed if user doesn't have rights)
-mkdir -p $target_sdk_dir >/dev/null 2>&1
-
-# if don't have the right to access dir, gain by sudo
-if [ ! -x $target_sdk_dir -o ! -w $target_sdk_dir -o ! -r $target_sdk_dir ]; then
- if [ "$SDK_EXTENSIBLE" = "1" ]; then
- echo "Unable to access \"$target_sdk_dir\", will not attempt to use" \
- "sudo as as extensible SDK cannot be used as root."
- exit 1
- fi
-
- SUDO_EXEC=$(which "sudo")
- if [ -z $SUDO_EXEC ]; then
- echo "No command 'sudo' found, please install sudo first. Abort!"
- exit 1
- fi
-
- # test sudo could gain root right
- $SUDO_EXEC pwd >/dev/null 2>&1
- [ $? -ne 0 ] && echo "Sorry, you are not allowed to execute as root." && exit 1
-
- # now that we have sudo rights, create the directory
- $SUDO_EXEC mkdir -p $target_sdk_dir >/dev/null 2>&1
-fi
-
-printf "Extracting SDK..."
-tail -n +$payload_offset $0| $SUDO_EXEC tar xJ -C $target_sdk_dir --checkpoint=.2500 $EXTRA_TAR_OPTIONS || exit 1
-echo "done"
-
-printf "Setting it up..."
-real_env_setup_script="$(grep -ql OECORE_NATIVE_SYSROOT= "$target_sdk_dir/"environment-setup* 2>/dev/null | head -n 1)"
-if [ -n "$real_env_setup_script" ] ; then
- env_setup_script="$real_env_setup_script"
-fi
-
-@SDK_POST_INSTALL_COMMAND@
-
-echo "done"
-
-# delete the relocating script, so that user is forced to re-run the installer
-# if he/she wants another location for the sdk
-if [ $savescripts = 0 ] ; then
- $SUDO_EXEC rm -f ${env_setup_script%/*}/relocate_sdk.py ${env_setup_script%/*}/relocate_sdk.sh
-fi
-
-echo "SDK has been successfully set up and is ready to be used."
-echo "Each time you wish to use the SDK in a new shell session, you need to source the environment setup script e.g."
-for env_setup_script in `ls $target_sdk_dir/environment-setup-*`; do
- echo " \$ . $env_setup_script"
-done
-
-exit 0
-
-MARKER:
diff --git a/meta-mentor-staging/files/toolchain-shar-relocate.sh b/meta-mentor-staging/files/toolchain-shar-relocate.sh
deleted file mode 100644
index 468679af..00000000
--- a/meta-mentor-staging/files/toolchain-shar-relocate.sh
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-$SUDO_EXEC $target_sdk_dir/relocate_sdk.sh
diff --git a/meta-mentor-staging/fsl-bsp-release/recipes-bsp/imx-vpu/imx-vpu_%.bbappend b/meta-mentor-staging/fsl-bsp-release/recipes-bsp/imx-vpu/imx-vpu_%.bbappend
deleted file mode 100644
index cc58d382..00000000
--- a/meta-mentor-staging/fsl-bsp-release/recipes-bsp/imx-vpu/imx-vpu_%.bbappend
+++ /dev/null
@@ -1,15 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-do_install:append:feature-mentor-staging () {
- if [ "${libdir}" != "/usr/lib" ]; then
- install -d "$(dirname "${D}${libdir}")"
- mv "${D}/usr/lib" "${D}${libdir}"
- fi
- if [ "${includedir}" != "/usr/include" ]; then
- install -d "$(dirname "${D}${includedir}")"
- mv "${D}/usr/include" "${D}${includedir}"
- fi
- rmdir --ignore-fail-on-non-empty "${D}/usr"
-}
diff --git a/meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync/rsyncd.conf b/meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync/rsyncd.conf
deleted file mode 100644
index 8d21249d..00000000
--- a/meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync/rsyncd.conf
+++ /dev/null
@@ -1,19 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0-or-later
-# ---------------------------------------------------------------------------------------------------------------------
-
-# /etc/rsyncd.conf
-
-# Minimal configuration file for rsync daemon
-# See rsync(1) and rsyncd.conf(5) man pages for help
-
-# This file is required by rsync --daemon
-pid file = /var/run/rsyncd.pid
-use chroot = yes
-read only = yes
-
-# Simple example for enabling your own local rsync server
-#[everything]
-# path = /
-# comment = Everything except /etc exposed
-# exclude = /etc
diff --git a/meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync_2.6.9+git.bb b/meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync_2.6.9+git.bb
deleted file mode 100644
index 896669b8..00000000
--- a/meta-mentor-staging/gplv2/recipes-devtools/rsync/rsync_2.6.9+git.bb
+++ /dev/null
@@ -1,28 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-require recipes-devtools/rsync/rsync_2.6.9.bb
-
-SRC_URI = "git://git.samba.org/rsync.git;protocol=https;branch=master \
- file://rsyncd.conf \
- file://addrinfo.h \
- file://0001-If-we-re-cross-compiling-tell-the-user-to-run-mkroun.patch \
- file://0002-Changed-the-creation-of-rounding.h-to-use-a-set-of-c.patch \
- file://0003-Renamed-mkrounding.c-to-rounding.c.patch \
- file://0004-Improved-the-manpage-install-rules.patch \
- file://force-protocol-version-29.patch \
-"
-
-SRCREV = "496c809f8cf529c5a95f9578b34a9299b0d92ffb"
-PV .= "${SRCPV}"
-
-S = "${WORKDIR}/git"
-
-do_configure:prepend () {
- install ${WORKDIR}/addrinfo.h ${S}/lib/
-}
-
-do_configure:append () {
- oe_runmake proto
-}
diff --git a/meta-mentor-staging/lib/oe/__init__.py b/meta-mentor-staging/lib/oe/__init__.py
deleted file mode 100644
index 86f9a56b..00000000
--- a/meta-mentor-staging/lib/oe/__init__.py
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0-only
-# ---------------------------------------------------------------------------------------------------------------------
-
-from pkgutil import extend_path
-__path__ = extend_path(__path__, __name__)
diff --git a/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch b/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch
deleted file mode 100644
index ae75adb4..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch
+++ /dev/null
@@ -1,89 +0,0 @@
-From 4163c0a0eb88263a3d3e593942cd9cf402909977 Mon Sep 17 00:00:00 2001
-From: Christopher Larson <chris_larson@mentor.com>
-Date: Mon, 5 Nov 2018 22:23:43 +0500
-Subject: [PATCH] PR3597: Potential bogus -Wformat-overflow warning with
- -Wformat enabled
-
-2018-05-29 Andrew John Hughes <gnu_andrew@member.fsf.org>
-
- PR3597: Potential bogus -Wformat-overflow warning
- with -Wformat enabled
- * Makefile.am:
- (ICEDTEA_PATCHES): Add patch.
- * NEWS: Updated.
- * patches/pr3597.patch:
- Disable -Wformat-overflow on the
- the build_pipe_classes function with GCC >= 7 as it
- produces apparent false positives.
-
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
----
- Makefile.am | 4 ++++
- patches/pr3597.patch | 43 +++++++++++++++++++++++++++++++++++++++++++
- 2 files changed, 47 insertions(+)
- create mode 100644 patches/pr3597.patch
-
-diff --git a/Makefile.am b/Makefile.am
-index 5f0c90d..c1950b5 100644
---- a/Makefile.am
-+++ b/Makefile.am
-@@ -277,6 +277,10 @@ else
- ICEDTEA_PATCHES += patches/nss-not-enabled-config.patch
- endif
-
-+# Apply additional HotSpot patches against same patch base
-+ICEDTEA_PATCHES += \
-+ patches/pr3597.patch
-+
- ICEDTEA_PATCHES += $(DISTRIBUTION_PATCHES)
-
- # Bootstrapping patches
-diff --git a/patches/pr3597.patch b/patches/pr3597.patch
-new file mode 100644
-index 0000000..5e3b4ef
---- /dev/null
-+++ b/patches/pr3597.patch
-@@ -0,0 +1,43 @@
-+diff --git openjdk.orig/hotspot/src/share/vm/adlc/adlc.hpp openjdk/hotspot/src/share/vm/adlc/adlc.hpp
-+--- openjdk.orig/hotspot/src/share/vm/adlc/adlc.hpp
-++++ openjdk/hotspot/src/share/vm/adlc/adlc.hpp
-+@@ -85,6 +85,19 @@
-+ #undef max
-+ #define max(a, b) (((a)>(b)) ? (a) : (b))
-+
-++#if !defined(__clang_major__) && (__GNUC__ >= 7)
-++#define PRAGMA_DIAG_PUSH _Pragma("GCC diagnostic push")
-++#define PRAGMA_DIAG_POP _Pragma("GCC diagnostic pop")
-++#define PRAGMA_FORMAT_OVERFLOW_IGNORED _Pragma("GCC diagnostic ignored \"-Wformat-overflow\"")
-++#define PRAGMA_FORMAT_OVERFLOW_IGNORED_EXTERNAL PRAGMA_FORMAT_OVERFLOW_IGNORED
-++#define PRAGMA_FORMAT_OVERFLOW_IGNORED_INTERNAL PRAGMA_FORMAT_OVERFLOW_IGNORED
-++#else
-++#define PRAGMA_DIAG_PUSH
-++#define PRAGMA_DIAG_POP
-++#define PRAGMA_FORMAT_OVERFLOW_IGNORED_EXTERNAL
-++#define PRAGMA_FORMAT_OVERFLOW_IGNORED_INTERNAL
-++#endif
-++
-+ // ADLC components
-+ #include "arena.hpp"
-+ #include "opto/adlcVMDeps.hpp"
-+diff --git openjdk.orig/hotspot/src/share/vm/adlc/output_c.cpp openjdk/hotspot/src/share/vm/adlc/output_c.cpp
-+--- openjdk.orig/hotspot/src/share/vm/adlc/output_c.cpp
-++++ openjdk/hotspot/src/share/vm/adlc/output_c.cpp
-+@@ -560,6 +560,8 @@
-+ return (ndx);
-+ }
-+
-++PRAGMA_DIAG_PUSH
-++PRAGMA_FORMAT_OVERFLOW_IGNORED_EXTERNAL
-+ void ArchDesc::build_pipe_classes(FILE *fp_cpp) {
-+ const char *classname;
-+ const char *resourcename;
-+@@ -1016,6 +1018,7 @@
-+ fprintf(fp_cpp, "}\n");
-+ fprintf(fp_cpp, "#endif\n");
-+ }
-++PRAGMA_DIAG_POP
-+
-+ // ---------------------------------------------------------------------------
-+ //------------------------------Utilities to build Instruction Classes--------
diff --git a/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0002-8184309-PR3596-Build-warnings-from-GCC-7.1-on-Fedora.patch b/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0002-8184309-PR3596-Build-warnings-from-GCC-7.1-on-Fedora.patch
deleted file mode 100644
index 866c2cc4..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native/0002-8184309-PR3596-Build-warnings-from-GCC-7.1-on-Fedora.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-From 18cc03a4713ff7c69a909950f9e3aca5de7db38e Mon Sep 17 00:00:00 2001
-From: Christopher Larson <chris_larson@mentor.com>
-Date: Tue, 6 Nov 2018 02:18:35 +0500
-Subject: [PATCH] 8184309, PR3596: Build warnings from GCC 7.1 on Fedora 26
-
-Another patch from upstream icedtea.
-
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
----
- Makefile.am | 3 ++-
- patches/8184309-pr3596.patch | 21 +++++++++++++++++++++
- 2 files changed, 23 insertions(+), 1 deletion(-)
- create mode 100644 patches/8184309-pr3596.patch
-
-Index: icedtea-2.1.3/Makefile.am
-===================================================================
---- icedtea-2.1.3.orig/Makefile.am
-+++ icedtea-2.1.3/Makefile.am
-@@ -279,7 +279,8 @@ endif
-
- # Apply additional HotSpot patches against same patch base
- ICEDTEA_PATCHES += \
-- patches/pr3597.patch
-+ patches/pr3597.patch \
-+ patches/8184309-pr3596.patch
-
- ICEDTEA_PATCHES += $(DISTRIBUTION_PATCHES)
-
-Index: icedtea-2.1.3/patches/8184309-pr3596.patch
-===================================================================
---- /dev/null
-+++ icedtea-2.1.3/patches/8184309-pr3596.patch
-@@ -0,0 +1,22 @@
-+# HG changeset patch
-+# User ysuenaga
-+# Date 1527498573 -3600
-+# Mon May 28 10:09:33 2018 +0100
-+# Node ID ef176cb429c49d1c330d9575938f66b04e3fb730
-+# Parent 6915dc9ae18cce5625d3a3fc74b37da70a5b4215
-+8184309, PR3596: Build warnings from GCC 7.1 on Fedora 26
-+Reviewed-by: kbarrett, vlivanov
-+
-+Index: openjdk/hotspot/src/share/vm/code/dependencies.cpp
-+===================================================================
-+--- openjdk.orig/hotspot/src/share/vm/code/dependencies.cpp
-++++ openjdk/hotspot/src/share/vm/code/dependencies.cpp
-+@@ -488,7 +488,7 @@ void Dependencies::write_dependency_to(x
-+ if (j == 1) {
-+ xtty->object("x", args[j]);
-+ } else {
-+- char xn[10]; sprintf(xn, "x%d", j);
-++ char xn[12]; sprintf(xn, "x%d", j);
-+ xtty->object(xn, args[j]);
-+ }
-+ }
diff --git a/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native_%.bbappend b/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native_%.bbappend
deleted file mode 100644
index 9c0dce7e..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/icedtea/icedtea7-native_%.bbappend
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/${PN}:"
-
-SRC_URI:append:feature-mentor-staging = "\
- file://0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch \
- file://0002-8184309-PR3596-Build-warnings-from-GCC-7.1-on-Fedora.patch \
-"
diff --git a/meta-mentor-staging/meta-java/recipes-core/jamvm/jamvm_%.bbappend b/meta-mentor-staging/meta-java/recipes-core/jamvm/jamvm_%.bbappend
deleted file mode 100644
index e6b1f854..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/jamvm/jamvm_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-do_install:append:feature-mentor-staging () {
- chown -R root:root ${D}${datadir}/jamvm/classes.zip
-}
-
diff --git a/meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-flags-to-compile-with-GCC-6.patch b/meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-flags-to-compile-with-GCC-6.patch
deleted file mode 100644
index 062c6bfa..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-flags-to-compile-with-GCC-6.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-From 732aab80cb1505ef2f4d8a6e141f835aa9f6d985 Mon Sep 17 00:00:00 2001
-From: Abdur Rehman <abdur_rehman@mentor.com>
-Date: Mon, 24 Oct 2016 20:24:32 +0500
-Subject: [PATCH] icedtea flags to compile with GCC 6
-
-Upstream bug filed here:
-https://bugs.openjdk.java.net/browse/JDK-8163032
-
-This patch combines the changes introduced by following commits:
-* http://hg.openjdk.java.net/jdk7u/jdk7u/hotspot/rev/e34324d73cd5
-* http://hg.openjdk.java.net/jdk7u/jdk7u/jdk/rev/9e1264f51bae
-
-Upstream-Status: Backport
-
-Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
----
- openjdk/hotspot/make/linux/makefiles/gcc.make | 7 +++++++
- openjdk/jdk/make/common/Defs-linux.gmk | 8 +++++++-
- 2 files changed, 14 insertions(+), 1 deletion(-)
-
-diff --git openjdk/hotspot/make/linux/makefiles/gcc.make openjdk/hotspot/make/linux/makefiles/gcc.make
-index 4ef0e49..bca3c5c 100644
---- openjdk/hotspot/make/linux/makefiles/gcc.make
-+++ openjdk/hotspot/make/linux/makefiles/gcc.make
-@@ -83,6 +83,7 @@ ifeq ($(TYPE),SHARK)
- CFLAGS += $(LIBFFI_CFLAGS)
- CFLAGS += $(LLVM_CFLAGS)
- endif
-+CFLAGS += -std=gnu++98
- CFLAGS += $(VM_PICFLAG)
- CFLAGS += -fno-rtti
- CFLAGS += -fno-exceptions
-@@ -93,6 +94,12 @@ CFLAGS += -fcheck-new
- ifneq "$(shell expr \( $(CC_VER_MAJOR) \> 4 \) \| \( \( $(CC_VER_MAJOR) = 4 \) \& \( $(CC_VER_MINOR) \>= 3 \) \))" "0"
- CFLAGS += -fvisibility=hidden
- endif
-+# GCC 6 has more aggressive dead-store elimination which causes the VM to crash
-+# It also optimises away null pointer checks which are still needed.
-+# We turn both of these optimisations off.
-+ifneq "$(shell expr \( $(CC_VER_MAJOR) \>= 6 \))" "0"
-+CFLAGS += -fno-delete-null-pointer-checks -fno-lifetime-dse
-+endif
-
- ARCHFLAG = $(ARCHFLAG/$(BUILDARCH))
- ARCHFLAG/i486 = -m32 -march=i586
-diff --git openjdk/jdk/make/common/Defs-linux.gmk openjdk/jdk/make/common/Defs-linux.gmk
-index f64042c..727593c 100644
---- openjdk/jdk/make/common/Defs-linux.gmk
-+++ openjdk/jdk/make/common/Defs-linux.gmk
-@@ -217,6 +217,12 @@ CFLAGS_REQUIRED_ppc64 += -fno-tree-vectorize
- CFLAGS_REQUIRED = $(CFLAGS_REQUIRED_$(ARCH))
- LDFLAGS_COMMON += $(LDFLAGS_COMMON_$(ARCH))
- endif
-+# GCC 6 has more aggressive dead-store elimination which causes the VM to crash
-+# It also optimises away null pointer checks which are still needed.
-+# We turn both of these optimisations off.
-+ifeq ($(shell $(EXPR) $(CC_MAJORVER) \>= 6 ),1)
-+ CFLAGS_REQUIRED += -fno-delete-null-pointer-checks -fno-lifetime-dse
-+endif
-
- # If this is a --hash-style=gnu system, use --hash-style=both
- # The gnu .hash section won't work on some Linux systems like SuSE 10.
-@@ -281,7 +287,7 @@ CFLAGS_OPT = $(CC_OPT)
- CFLAGS_DBG = $(DEBUG_FLAG)
- CFLAGS_COMMON += $(CFLAGS_REQUIRED)
-
--CXXFLAGS_COMMON = $(GLOBAL_KPIC) -DCC_NOEX $(GCC_WARNINGS)
-+CXXFLAGS_COMMON = -std=gnu++98 $(GLOBAL_KPIC) -DCC_NOEX $(GCC_WARNINGS)
- CXXFLAGS_OPT = $(CC_OPT)
- CXXFLAGS_DBG = $(DEBUG_FLAG)
- CXXFLAGS_COMMON += $(CFLAGS_REQUIRED)
---
-2.8.1
-
diff --git a/meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-specify-overloaded-variant-of-fmod.patch b/meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-specify-overloaded-variant-of-fmod.patch
deleted file mode 100644
index 09fbffe0..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/openjdk/files/icedtea-specify-overloaded-variant-of-fmod.patch
+++ /dev/null
@@ -1,28 +0,0 @@
-From 64a8800cd4efa15bf625227b7cd3a2e15ebfa359 Mon Sep 17 00:00:00 2001
-From: Abdur Rehman <abdur_rehman@mentor.com>
-Date: Tue, 25 Oct 2016 13:29:51 +0500
-Subject: [PATCH] arm32JIT.cpp: specify overloaded variant of fmod
-
-Upstream-Status: Pending
-
-Signed-off-by: Abdur Rehman <abdur_rehman@mentor.com>
----
- openjdk/hotspot/src/cpu/zero/vm/arm32JIT.cpp | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git openjdk/hotspot/src/cpu/zero/vm/arm32JIT.cpp openjdk/hotspot/src/cpu/zero/vm/arm32JIT.cpp
-index 089a1c9..4482fd6 100644
---- openjdk/hotspot/src/cpu/zero/vm/arm32JIT.cpp
-+++ openjdk/hotspot/src/cpu/zero/vm/arm32JIT.cpp
-@@ -8185,7 +8185,7 @@ handlers[H_INVOKEINTERFACE] = (unsigned)(cb->hp + INVOKEINTERFACE_STUB);
-
- handlers[H_DREM] = out_pos(&codebuf);
- stm(&codebuf, (1<<ARM_LR), ARM_SP, PUSH_FD, 1);
-- mov_imm(&codebuf, ARM_IP, (u32)fmod);
-+ mov_imm(&codebuf, ARM_IP, (u32)(double (*)(double, double))fmod);
- #ifdef __ARM_PCS_VFP
- vmov_reg_d_toVFP(&codebuf, VFP_D0, ARM_R0, ARM_R1);
- vmov_reg_d_toVFP(&codebuf, VFP_D1, ARM_R2, ARM_R3);
---
-2.8.1
-
diff --git a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-7_%.bbappend b/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-7_%.bbappend
deleted file mode 100644
index 9608219c..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-7_%.bbappend
+++ /dev/null
@@ -1,26 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/files:"
-
-ICEDTEAPATCHES:append:feature-mentor-staging = "\
- file://icedtea-flags-to-compile-with-GCC-6.patch;apply=no \
- file://icedtea-specify-overloaded-variant-of-fmod.patch;apply=no \
-"
-
-DISTRIBUTION_PATCHES:append:feature-mentor-staging = "\
- patches/icedtea-flags-to-compile-with-GCC-6.patch \
- patches/icedtea-specify-overloaded-variant-of-fmod.patch \
-"
-
-FILES:${JDKPN}-jdk:append:feature-mentor-staging = " ${JDK_HOME}/tapset "
-
-EXTRA_OEMAKE:append:feature-mentor-staging = " LDFLAGS_HASH_STYLE='${LDFLAGS}'"
-
-INSANE_SKIP:${JDKPN}-vm-zero:append:feature-mentor-staging = " textrel"
-
-python () {
- if 'feature-mentor-staging' in d.getVar('OVERRIDES').split(':'):
- d.setVarFlag('DISTRIBUTION_PATCHES', 'export', 1)
-}
diff --git a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8-native_%.bbappend b/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8-native_%.bbappend
deleted file mode 100644
index f3b7a640..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8-native_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/${BPN}:"
-
-SRC_URI:append:feature-mentor-staging = " file://0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch"
-
diff --git a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch b/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch
deleted file mode 100644
index 6320cdd5..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8/0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch
+++ /dev/null
@@ -1,71 +0,0 @@
-From 7efbc09cf4fb6aa9c081974d378d503c8bb0745e Mon Sep 17 00:00:00 2001
-From: Christopher Larson <chris_larson@mentor.com>
-Date: Mon, 5 Nov 2018 21:01:47 +0500
-Subject: [PATCH] PR3597: Potential bogus -Wformat-overflow warning with
- -Wformat enabled
-
-2018-05-29 Andrew John Hughes <gnu_andrew@member.fsf.org>
-
-PR3597: Potential bogus -Wformat-overflow warning
-with -Wformat enabled
-* Makefile.am:
-* (ICEDTEA_PATCHES): Add patch.
-* * NEWS: Updated.
-* * patches/pr3597.patch:
-* Disable -Wformat-overflow on the
-* the build_pipe_classes function with GCC >= 7 as it
-* produces apparent false positives.
-
-Patch pulled from the icedtea project.
-
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
----
- hotspot/src/share/vm/adlc/adlc.hpp | 13 +++++++++++++
- hotspot/src/share/vm/adlc/output_c.cpp | 3 +++
- 2 files changed, 16 insertions(+)
-
-diff --git a/hotspot/src/share/vm/adlc/adlc.hpp b/hotspot/src/share/vm/adlc/adlc.hpp
-index 8d48ed60..48a226ae 100644
---- a/hotspot/src/share/vm/adlc/adlc.hpp
-+++ b/hotspot/src/share/vm/adlc/adlc.hpp
-@@ -85,6 +85,19 @@ typedef unsigned int uintptr_t;
- #undef max
- #define max(a, b) (((a)>(b)) ? (a) : (b))
-
-+#if !defined(__clang_major__) && (__GNUC__ >= 7)
-+#define PRAGMA_DIAG_PUSH _Pragma("GCC diagnostic push")
-+#define PRAGMA_DIAG_POP _Pragma("GCC diagnostic pop")
-+#define PRAGMA_FORMAT_OVERFLOW_IGNORED _Pragma("GCC diagnostic ignored \"-Wformat-overflow\"")
-+#define PRAGMA_FORMAT_OVERFLOW_IGNORED_EXTERNAL PRAGMA_FORMAT_OVERFLOW_IGNORED
-+#define PRAGMA_FORMAT_OVERFLOW_IGNORED_INTERNAL PRAGMA_FORMAT_OVERFLOW_IGNORED
-+#else
-+#define PRAGMA_DIAG_PUSH
-+#define PRAGMA_DIAG_POP
-+#define PRAGMA_FORMAT_OVERFLOW_IGNORED_EXTERNAL
-+#define PRAGMA_FORMAT_OVERFLOW_IGNORED_INTERNAL
-+#endif
-+
- // ADLC components
- #include "arena.hpp"
- #include "opto/adlcVMDeps.hpp"
-diff --git a/hotspot/src/share/vm/adlc/output_c.cpp b/hotspot/src/share/vm/adlc/output_c.cpp
-index f53dbd58..7a59ec59 100644
---- a/hotspot/src/share/vm/adlc/output_c.cpp
-+++ b/hotspot/src/share/vm/adlc/output_c.cpp
-@@ -560,6 +560,8 @@ static int pipeline_res_mask_initializer(
- return (ndx);
- }
-
-+PRAGMA_DIAG_PUSH
-+PRAGMA_FORMAT_OVERFLOW_IGNORED_EXTERNAL
- void ArchDesc::build_pipe_classes(FILE *fp_cpp) {
- const char *classname;
- const char *resourcename;
-@@ -1016,6 +1018,7 @@ void ArchDesc::build_pipe_classes(FILE *fp_cpp) {
- fprintf(fp_cpp, "}\n");
- fprintf(fp_cpp, "#endif\n");
- }
-+PRAGMA_DIAG_POP
-
- // ---------------------------------------------------------------------------
- //------------------------------Utilities to build Instruction Classes--------
diff --git a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8_%.bbappend b/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8_%.bbappend
deleted file mode 100644
index 9d595c0b..00000000
--- a/meta-mentor-staging/meta-java/recipes-core/openjdk/openjdk-8_%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/${PN}:"
-
-SRC_URI:append:feature-mentor-staging = " file://0001-PR3597-Potential-bogus-Wformat-overflow-warning-with.patch"
-
diff --git a/meta-mentor-staging/meta-python/recipes-devtools/python/python3-pyudev_%.bbappend b/meta-mentor-staging/meta-python/recipes-devtools/python/python3-pyudev_%.bbappend
deleted file mode 100644
index 557e0fd4..00000000
--- a/meta-mentor-staging/meta-python/recipes-devtools/python/python3-pyudev_%.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-RDEPENDS:${PN}:append:feature-mentor-staging = "\
- ${PYTHON_PN}-fcntl \
-"
diff --git a/meta-mentor-staging/openembedded-layer/recipes-extended/collectd/collectd_%.bbappend b/meta-mentor-staging/openembedded-layer/recipes-extended/collectd/collectd_%.bbappend
deleted file mode 100644
index 857b845b..00000000
--- a/meta-mentor-staging/openembedded-layer/recipes-extended/collectd/collectd_%.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-PACKAGECONFIG[rrdtool] = "--enable-rrdtool,--disable-rrdtool,rrdtool"
-PACKAGECONFIG[rrdcached] = "--enable-rrdcached,--disable-rrdcached,rrdcached"
diff --git a/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/local-tcp-test b/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/local-tcp-test
deleted file mode 100755
index 09be814e..00000000
--- a/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/local-tcp-test
+++ /dev/null
@@ -1,26 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: LGPL-2.1-or-later
-# ---------------------------------------------------------------------------------------------------------------------
-
-scriptdir="$(dirname "$0")"
-
-client_log=$scriptdir/unit-test-client.log
-server_log=$scriptdir/unit-test-server.log
-
-rm -f $client_log $server_log
-
-$scriptdir/unit-test-server > $server_log 2>&1 &
-
-sleep 1
-
-$scriptdir/unit-test-client > $client_log 2>&1
-rc=$?
-
-killall unit-test-server >/dev/null 2>&1
-
-if ! grep -q "ALL TESTS PASS WITH SUCCESS." $client_log; then
- rc=1
-fi
-exit $rc
diff --git a/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/run-ptest b/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/run-ptest
deleted file mode 100755
index bd6790a1..00000000
--- a/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus/run-ptest
+++ /dev/null
@@ -1,13 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: LGPL-2.1-or-later
-# ---------------------------------------------------------------------------------------------------------------------
-
-for test in @PTEST_PATH@/tests/*-test; do
- if "$test"; then
- echo "PASS: ${test##*/}"
- else
- echo "FAIL: ${test##*/}"
- fi
-done
diff --git a/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus_%.bbappend b/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus_%.bbappend
deleted file mode 100644
index abcc86bb..00000000
--- a/meta-mentor-staging/openembedded-layer/recipes-extended/libmodbus/libmodbus_%.bbappend
+++ /dev/null
@@ -1,17 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/libmodbus:"
-SRC_URI:append:feature-mentor-staging = " \
- file://run-ptest \
- file://local-tcp-test \
-"
-
-inherit ptest
-
-do_install_ptest() {
- install -d ${D}${PTEST_PATH}/tests/
- install -m 0755 ${WORKDIR}/*-test ${B}/tests/.libs/* ${D}${PTEST_PATH}/tests/
- sed -i -e 's#@PTEST_PATH@#${PTEST_PATH}#g' ${D}${PTEST_PATH}/run-ptest
-}
diff --git a/meta-mentor-staging/perl-layer/recipes-perl/libnet/libnet-ssleay-perl_1.85.bbappend b/meta-mentor-staging/perl-layer/recipes-perl/libnet/libnet-ssleay-perl_1.85.bbappend
deleted file mode 100644
index c8bfaa3b..00000000
--- a/meta-mentor-staging/perl-layer/recipes-perl/libnet/libnet-ssleay-perl_1.85.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-RDEPENDS:${PN}:append:feature-mentor-staging = " \
- perl-module-autoloader \
-"
diff --git a/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase/Fix-note-alignment.patch b/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase/Fix-note-alignment.patch
deleted file mode 100644
index 017ff5fc..00000000
--- a/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase/Fix-note-alignment.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From 4d8f490c91767806c267cb50fb3f97e8ecc7e533 Mon Sep 17 00:00:00 2001
-From: Andreas Schwab <schwab@suse.de>
-Date: Sun, 17 May 2020 11:57:58 +0200
-Subject: [PATCH] Fix note alignment
-
-It is architecture defined whether .align means .palign or .balign. Use
-.balign to make that explicit.
-
-Change-Id: I8c7e3760b37edfb207b7088319a338a1f583255b
-Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
-Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
-Upstream-Status: Backport [47a4e6a9497b068a0400ba3f01629c62608e1ec3]
----
- src/corelib/global/minimum-linux.S | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/corelib/global/minimum-linux.S b/src/corelib/global/minimum-linux.S
-index dfc3cec1be..e324379efc 100644
---- a/src/corelib/global/minimum-linux.S
-+++ b/src/corelib/global/minimum-linux.S
-@@ -62,7 +62,7 @@
-
- .section ".note.GNU-stack", "", progbits
- .section ".note.ABI-tag", "a", note
-- .align 4 /* we have 32-bit data */
-+ .balign 4 /* we have 32-bit data */
-
- /* * For the format of the note section's contents, see Elf32_Nhdr / Elf64_Nhdr */
- .long .Lnameend-.Lname /* n_namesz */
---
-2.28.0
-
diff --git a/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase_%.bbappend b/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase_%.bbappend
deleted file mode 100644
index c02e0b13..00000000
--- a/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtbase_%.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend := "${THISDIR}/qtbase:"
-SRC_URI:append:feature-mentor-staging = " file://Fix-note-alignment.patch"
diff --git a/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtwebkit_%.bbappend b/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtwebkit_%.bbappend
deleted file mode 100644
index 5549950a..00000000
--- a/meta-mentor-staging/qt5-layer/recipes-qt/qt5/qtwebkit_%.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-DEPENDS:append:feature-mentor-staging = " flex-native"
diff --git a/meta-mentor-staging/recipes-connectivity/connman/connman_%.bbappend b/meta-mentor-staging/recipes-connectivity/connman/connman_%.bbappend
deleted file mode 100644
index 321a3f61..00000000
--- a/meta-mentor-staging/recipes-connectivity/connman/connman_%.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/files:"
-SRC_URI:append:feature-mentor-staging = " file://0001-connman-implement-network-interface-management-techn.patch"
diff --git a/meta-mentor-staging/recipes-connectivity/connman/files/0001-connman-implement-network-interface-management-techn.patch b/meta-mentor-staging/recipes-connectivity/connman/files/0001-connman-implement-network-interface-management-techn.patch
deleted file mode 100644
index 06695ea5..00000000
--- a/meta-mentor-staging/recipes-connectivity/connman/files/0001-connman-implement-network-interface-management-techn.patch
+++ /dev/null
@@ -1,31 +0,0 @@
-From e6dedb531096f29825bddaf428ca8d3c4ad1df26 Mon Sep 17 00:00:00 2001
-From: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
-Date: Tue, 1 Jul 2014 23:47:15 +0530
-Subject: [PATCH] connman: implement network interface management techniques
-
-This is required to obtain a managed network interface before connman
-tries to call cleanup_devices function, this will let connman
-create new routing table without bringing down the ethernet interface.
-
-Signed-off-by: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
-
----
- src/connman.service.in | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/src/connman.service.in b/src/connman.service.in
-index 79e75d6..0e7275a 100644
---- a/src/connman.service.in
-+++ b/src/connman.service.in
-@@ -12,7 +12,10 @@ Conflicts=systemd-resolved.service
- Type=dbus
- BusName=net.connman
- Restart=on-failure
--ExecStart=@sbindir@/connmand -n
-+EnvironmentFile=-/tmp/connman.env
-+ExecStartPre=/bin/sh -c "if grep 'nfsroot\|ip=' /proc/cmdline; then ETH_IFACE=$(ip addr | grep 'eth[0-9]:' | grep 'UP' | sed -e 's,\(eth[0-9]\)\(.*\),\1,' -e 's,^.*: ,,' ); NET_ADDR=$(cat /proc/cmdline | sed -ne 's/^.*ip=\([^ :]*\).*$/\1/p'); echo -e 'OPT=-I '$ETH_IFACE'\nOPT2='$ETH_IFACE'\nNET_ADDR='$NET_ADDR' ' > /tmp/connman.env; fi "
-+ExecStart=/bin/sh -c "if [ \"$NET_ADDR\" = \"off\" ] || [ \"$NET_ADDR\" = \"none\" ]; then /usr/sbin/connmand -n; else /usr/sbin/connmand -n $OPT; fi"
-+ExecStartPost=/bin/sh -c "if [ ! -z \"$OPT\" ] && [ \"$NET_ADDR\" = \"dhcp\" ]; then /sbin/udhcpc -i $OPT2; fi"
- StandardOutput=null
- CapabilityBoundingSet=CAP_NET_ADMIN CAP_NET_BIND_SERVICE CAP_NET_RAW CAP_SYS_TIME CAP_SYS_MODULE CAP_SYS_ADMIN
- ProtectHome=true
diff --git a/meta-mentor-staging/recipes-core/glibc/glibc-locale_%.bbappend b/meta-mentor-staging/recipes-core/glibc/glibc-locale_%.bbappend
deleted file mode 100644
index ae6f962f..00000000
--- a/meta-mentor-staging/recipes-core/glibc/glibc-locale_%.bbappend
+++ /dev/null
@@ -1,20 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Work around long standing periodic host-user-contaminated QA failure by
-# explicitly correcting the ownership.
-#
-# See `glibc-locale: Rewrite do_install using install utility instead of cp`
-# on the oe-core mailing list for discussion. This should be dropped when
-# a real fix is implemented.
-
-do_prep_locale_tree:append () {
- chown -R root:root $treedir
-}
-
-# Explicitly disable host-user-contaminated to further work around the
-# pseudo bug. With pseudo acting up, even if the ownership is correct,
-# it may well think it is not, so just sidestep the issue until upstream
-# fixes the root cause.
-ERROR_QA:remove = "host-user-contaminated"
diff --git a/meta-mentor-staging/recipes-core/initrdscripts/files/0001-initramfs-framework-finish-move-mounts-to-rootfs-bef.patch b/meta-mentor-staging/recipes-core/initrdscripts/files/0001-initramfs-framework-finish-move-mounts-to-rootfs-bef.patch
deleted file mode 100644
index 1aad3949..00000000
--- a/meta-mentor-staging/recipes-core/initrdscripts/files/0001-initramfs-framework-finish-move-mounts-to-rootfs-bef.patch
+++ /dev/null
@@ -1,51 +0,0 @@
-From 59f5fd34edae4e1c4633b160ee6c6e51ec6a98e4 Mon Sep 17 00:00:00 2001
-From: Awais Belal <awais_belal@mentor.com>
-Date: Wed, 28 Nov 2018 13:02:08 +0500
-Subject: [PATCH] initramfs-framework/finish: move mounts to rootfs before
- switching
-
-If basic device mounts are not moved onto the rootfs before
-switching, the device is not properly accessible for operations
-such as mkfs and for such devices once the system is fully booted
-we see
-
-root@v1000:~# mkfs.ext4 /dev/sdb1
-mke2fs 1.43.8 (1-Jan-2018)
-/dev/sdb1 contains a ext4 file system
- last mounted on Wed Nov 28 07:33:54 2018
-Proceed anyway? (y,N) y
-/dev/sdb1 is apparently in use by the system; will not make a filesystem here!
-
-This fragment is picked up from initramfs-live-boot. See
-8293f564685d0f587ab63a107285625dc4f98f1c and
-6f8f984ba363f764e83290b972ec31a90aad1603
-for more details.
-
-Signed-off-by: Awais Belal <awais_belal@mentor.com>
----
- finish | 9 +++++++++
- 1 file changed, 9 insertions(+)
-
-diff --git a/finish b/finish
-index 717383e..9722d02 100755
---- a/finish
-+++ b/finish
-@@ -14,6 +14,15 @@ finish_run() {
-
- info "Switching root to '$ROOTFS_DIR'..."
-
-+ debug "Moving basic mounts onto rootfs"
-+ for dir in `awk '/\/dev.* \/run\/media/{print $2}' /proc/mounts`; do
-+ # Parse any OCT or HEX encoded chars such as spaces
-+ # in the mount points to actual ASCII chars
-+ dir=`printf $dir`
-+ mkdir -p "${ROOTFS_DIR}/media/${dir##*/}"
-+ mount -n --move "$dir" "${ROOTFS_DIR}/media/${dir##*/}"
-+ done
-+
- debug "Moving /dev, /proc and /sys onto rootfs..."
- mount --move /dev $ROOTFS_DIR/dev
- mount --move /proc $ROOTFS_DIR/proc
---
-2.11.1
-
diff --git a/meta-mentor-staging/recipes-core/initrdscripts/files/0001-initrdscripts-init-live.sh-Fixed-mounts-fail-to-move.patch b/meta-mentor-staging/recipes-core/initrdscripts/files/0001-initrdscripts-init-live.sh-Fixed-mounts-fail-to-move.patch
deleted file mode 100644
index ce62f3b7..00000000
--- a/meta-mentor-staging/recipes-core/initrdscripts/files/0001-initrdscripts-init-live.sh-Fixed-mounts-fail-to-move.patch
+++ /dev/null
@@ -1,65 +0,0 @@
-From f8d1c573897825f8ffcc68263b9379ca9c2f775c Mon Sep 17 00:00:00 2001
-From: "Arsalan H. Awan" <Arsalan_Awan@mentor.com>
-Date: Fri, 20 Apr 2018 19:06:48 +0500
-Subject: [PATCH] initrdscripts/init-live.sh: Fixed mounts fail to move to real
- root fs
-
-When there are spaces in the mount points of devices e.g.:
-
- a partition mounted at "/run/media/My Root Partition-sda1",
-
-the initrd fails to move such mount points over to the
-corresponding directories at /media under the real root filesystem,
-and the mount points would appear at the same location as they were
-mounted on when detected by initrd, for example:
- here: "/run/media/My Root Partition-sda1"
- instead of here: "/media/My Root Partition-sda1"
-
-This causes issues such as:
-
- * The disks/partitions cannot be formated with any filesystem
- using e.g. mkfs.ext4 or mke2fs in general. When tried to do so
- by making sure the device is not mounted, it failed with
- errors such as:
-
- > /dev/sda1 is apparently in use by the system; will not make a
- filesystem here!
- > /dev/sda1: Device or resource busy while setting up superblock
-
- * The read/write operations become extremely slow. e.g. Under testing,
- it took approx. 2 hours just to copy 700 MB of data to the partition,
- and it took more than 40 minutes to delete that data from it.
- Same operations took under 5 minutes on a partition that had no
- spaces in its mount point (or that was successfully moved to real
- root by initrd and appeared under /media instead of /run/media).
-
-This commit fixes such issues by quoting the arguments of failing mount
-move commands and by parsing OCT or HEX encoded special characters
-such as spaces to ASCII characters in the mount points.
-
-Signed-off-by: Arsalan H. Awan <Arsalan_Awan@mentor.com>
----
- init-live.sh | 7 +++++--
- 1 file changed, 5 insertions(+), 2 deletions(-)
-
-diff --git a/init-live.sh b/init-live.sh
-index 441b41c9d6..e58df12061 100644
---- a/init-live.sh
-+++ b/init-live.sh
-@@ -91,8 +91,11 @@ boot_live_root() {
- # Move the mount points of some filesystems over to
- # the corresponding directories under the real root filesystem.
- for dir in `awk '/\/dev.* \/run\/media/{print $2}' /proc/mounts`; do
-- mkdir -p ${ROOT_MOUNT}/media/${dir##*/}
-- mount -n --move $dir ${ROOT_MOUNT}/media/${dir##*/}
-+ # Parse any OCT or HEX encoded chars such as spaces
-+ # in the mount points to actual ASCII chars
-+ dir=`printf $dir`
-+ mkdir -p "${ROOT_MOUNT}/media/${dir##*/}"
-+ mount -n --move "$dir" "${ROOT_MOUNT}/media/${dir##*/}"
- done
- mount -n --move /proc ${ROOT_MOUNT}/proc
- mount -n --move /sys ${ROOT_MOUNT}/sys
---
-2.11.1
-
diff --git a/meta-mentor-staging/recipes-core/initrdscripts/initramfs-framework_1.0.bbappend b/meta-mentor-staging/recipes-core/initrdscripts/initramfs-framework_1.0.bbappend
deleted file mode 100644
index ce9fade0..00000000
--- a/meta-mentor-staging/recipes-core/initrdscripts/initramfs-framework_1.0.bbappend
+++ /dev/null
@@ -1,6 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/files:"
-SRC_URI:append:feature-mentor-staging = " file://0001-initramfs-framework-finish-move-mounts-to-rootfs-bef.patch"
diff --git a/meta-mentor-staging/recipes-core/initrdscripts/initramfs-live-boot_1.0.bbappend b/meta-mentor-staging/recipes-core/initrdscripts/initramfs-live-boot_1.0.bbappend
deleted file mode 100644
index 2e062946..00000000
--- a/meta-mentor-staging/recipes-core/initrdscripts/initramfs-live-boot_1.0.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/files:"
-
-SRC_URI:append:feature-mentor-staging = " file://0001-initrdscripts-init-live.sh-Fixed-mounts-fail-to-move.patch"
diff --git a/meta-mentor-staging/recipes-core/meta/buildtools-tarball.bbappend b/meta-mentor-staging/recipes-core/meta/buildtools-tarball.bbappend
deleted file mode 100644
index d9310a18..00000000
--- a/meta-mentor-staging/recipes-core/meta/buildtools-tarball.bbappend
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# buildtools-tarball is host only, and does not add TOOLCHAIN_TARGET_TASK to
-# RDEPENDS. Forcibly empty it, otherwise a TOOLCHAIN_TARGET_TASK:append at the
-# config level will break the buildtools-tarball build
-python () {
- d.setVar('TOOLCHAIN_TARGET_TASK', '')
-}
diff --git a/meta-mentor-staging/recipes-core/meta/meta-environment.bbappend b/meta-mentor-staging/recipes-core/meta/meta-environment.bbappend
deleted file mode 100644
index ba39ff05..00000000
--- a/meta-mentor-staging/recipes-core/meta/meta-environment.bbappend
+++ /dev/null
@@ -1,23 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-create_sdk_files:append () {
- script=${SDK_OUTPUT}/${SDKPATH}/environment-setup-${REAL_MULTIMACH_TARGET_SYS}
- cat >"${script}.new" <<END
-if [ -n "\$BASH_SOURCE" ] || [ -n "\$ZSH_NAME" ]; then
- if [ -n "\$BASH_SOURCE" ]; then
- scriptdir="\$(cd "\$(dirname "\$BASH_SOURCE")" && pwd)"
- elif [ -n "\$ZSH_NAME" ]; then
- scriptdir="\$(cd "\$(dirname "\$0")" && pwd)"
- fi
-else
- if [ ! -d "${SDKPATH}" ]; then
- echo >&2 "Warning: Unable to determine SDK install path from environment setup script location, using default of ${SDKPATH}."
- fi
- scriptdir="${SDKPATH}"
-fi
-END
- sed -e "s#${SDKPATH}#\$scriptdir#g" "$script" >>"${script}.new"
- mv "${script}.new" "${script}"
-}
diff --git a/meta-mentor-staging/recipes-core/systemd/systemd-boot/0001-Use-an-array-for-efi-ld-to-allow-for-ld-arguments.patch b/meta-mentor-staging/recipes-core/systemd/systemd-boot/0001-Use-an-array-for-efi-ld-to-allow-for-ld-arguments.patch
deleted file mode 100644
index 5cb62278..00000000
--- a/meta-mentor-staging/recipes-core/systemd/systemd-boot/0001-Use-an-array-for-efi-ld-to-allow-for-ld-arguments.patch
+++ /dev/null
@@ -1,48 +0,0 @@
-From 586638384dd980628e1d51a29fd9324eab661834 Mon Sep 17 00:00:00 2001
-From: Christopher Larson <chris_larson@mentor.com>
-Date: Mon, 5 Oct 2020 22:06:12 +0500
-Subject: [PATCH] Use an array for efi-ld to allow for ld arguments
-
-Signed-off-by: Christopher Larson <chris_larson@mentor.com>
----
- meson_options.txt | 2 +-
- src/boot/efi/meson.build | 6 +++---
- 2 files changed, 4 insertions(+), 4 deletions(-)
-
-diff --git a/meson_options.txt b/meson_options.txt
-index 44ff23f641..8dad5926db 100644
---- a/meson_options.txt
-+++ b/meson_options.txt
-@@ -305,7 +305,7 @@ option('gnu-efi', type : 'combo', choices : ['auto', 'true', 'false'],
- description : 'gnu-efi support for sd-boot')
- option('efi-cc', type : 'array',
- description : 'the compiler to use for EFI modules')
--option('efi-ld', type : 'string',
-+option('efi-ld', type : 'array',
- description : 'the linker to use for EFI modules')
- option('efi-libdir', type : 'string',
- description : 'path to the EFI lib directory')
-diff --git a/src/boot/efi/meson.build b/src/boot/efi/meson.build
-index c1fe04597b..b42b202ad3 100644
---- a/src/boot/efi/meson.build
-+++ b/src/boot/efi/meson.build
-@@ -45,8 +45,8 @@ if conf.get('ENABLE_EFI') == 1 and get_option('gnu-efi') != 'false'
- efi_cc = cc.cmd_array()
- endif
- efi_ld = get_option('efi-ld')
-- if efi_ld == ''
-- efi_ld = find_program('ld', required: true)
-+ if efi_ld.length() == 0
-+ efi_ld = [find_program('ld', required: true)]
- endif
- efi_incdir = get_option('efi-includedir')
-
-@@ -211,7 +211,7 @@ if have_gnu_efi
- tuple[0],
- input : tuple[2],
- output : tuple[0],
-- command : [efi_ld, '-o', '@OUTPUT@'] +
-+ command : efi_ld + ['-o', '@OUTPUT@'] +
- efi_ldflags + tuple[2] +
- ['-lefi', '-lgnuefi', libgcc_file_name])
-
diff --git a/meta-mentor-staging/recipes-core/systemd/systemd-boot_%.bbappend b/meta-mentor-staging/recipes-core/systemd/systemd-boot_%.bbappend
deleted file mode 100644
index 537f51a1..00000000
--- a/meta-mentor-staging/recipes-core/systemd/systemd-boot_%.bbappend
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/${PN}:"
-
-SRC_URI:append:feature-mentor-staging = " file://0001-Use-an-array-for-efi-ld-to-allow-for-ld-arguments.patch"
-
-LDFLAGS:remove:feature-mentor-staging := "${@ " ".join(d.getVar('LD').split()[1:])} "
-EXTRA_OEMESON:append:feature-mentor-staging = ' "-Defi-ld=${@meson_array("LD", d)}"'
diff --git a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-add-LABELs-to-mountpoints.patch b/meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-add-LABELs-to-mountpoints.patch
deleted file mode 100644
index e5b5ab85..00000000
--- a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-add-LABELs-to-mountpoints.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From 3ad00853d0e81fc8e0729c7c7312fab3a5a1a94c Mon Sep 17 00:00:00 2001
-From: "Arsalan H. Awan" <Arsalan_Awan@mentor.com>
-Date: Thu, 1 Nov 2018 17:37:07 +0500
-Subject: [PATCH] udev-extraconf/mount.sh: add LABELs to mountpoints
-
-This alters the mountpoints such that if a device has a LABEL or
-a PARTLABEL, it will be mounted at e.g.:
-
- /run/media/$LABEL-<device-node>
- /run/media/$PARTLABEL-<device-node>
- /run/media/rootfs-sda2
-
-otherwise the device will be mounted at e.g.:
-
- /run/media/<device-node>
- /run/media/sda1
-
-The <device-node> appended with LABEL or PARTLABEL makes sure that
-the mountpoint is unique, therefore, avoids overlapping mounts.
-
-Signed-off-by: Arsalan H. Awan <Arsalan_Awan@mentor.com>
----
- mount.sh | 10 ++++++++++
- 1 file changed, 10 insertions(+)
-
-Index: 1.1-r0/mount.sh
-===================================================================
---- 1.1-r0.orig/mount.sh
-+++ 1.1-r0/mount.sh
-@@ -94,6 +94,16 @@ automount() {
- # configured in fstab
- grep -q "^$DEVNAME " /proc/mounts && return
-
-+ # Get the LABEL or PARTLABEL
-+ LABEL=`/sbin/blkid | grep "${DEVNAME}:" | grep -o 'LABEL=".*"' | cut -d '"' -f2`
-+ # If the $DEVNAME has a LABEL or a PARTLABEL
-+ if [ -n "$LABEL" ]; then
-+ # Set the mount location dir name to LABEL appended
-+ # with $name e.g. label-sda. That would avoid overlapping
-+ # mounts in case two devices have same LABEL
-+ name="${LABEL}-${name}"
-+ fi
-+
- ! test -d "$MOUNT_BASE/$name" && mkdir -p "$MOUNT_BASE/$name"
- # Silent util-linux's version of mounting auto
- if [ "x`readlink $MOUNT`" = "x/bin/mount.util-linux" ] ;
diff --git a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-ignore-lvm-in-automount.patch b/meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-ignore-lvm-in-automount.patch
deleted file mode 100644
index 54077945..00000000
--- a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0001-udev-extraconf-mount.sh-ignore-lvm-in-automount.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From c81149d0faef688270b7f4b49bef7bd71016b242 Mon Sep 17 00:00:00 2001
-From: Ansar Rasool <ansar_rasool@mentor.com>
-Date: Tue, 10 Nov 2020 12:50:14 +0500
-Subject: [PATCH 1/1] udev-extraconf/mount.sh: ignore lvm in automount
-
-Signed-off-by: Ansar Rasool <ansar_rasool@mentor.com>
----
- mount.sh | 4 ++++
- 1 file changed, 4 insertions(+)
-
-diff --git a/mount.sh b/mount.sh
-index ef4e1ad..513a716 100644
---- a/mount.sh
-+++ b/mount.sh
-@@ -67,6 +67,8 @@ automount_systemd() {
- ;;
- swap)
- return ;;
-+ lvm*|LVM*)
-+ return ;;
- # TODO
- *)
- ;;
-@@ -127,6 +129,8 @@ automount() {
- ;;
- swap)
- return ;;
-+ lvm*|LVM*)
-+ return ;;
- # TODO
- *)
- ;;
---
-2.17.1
-
diff --git a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0002-udev-extraconf-mount.sh-save-mount-name-in-our-tmp-f.patch b/meta-mentor-staging/recipes-core/udev/udev-extraconf/0002-udev-extraconf-mount.sh-save-mount-name-in-our-tmp-f.patch
deleted file mode 100644
index 2848d15a..00000000
--- a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0002-udev-extraconf-mount.sh-save-mount-name-in-our-tmp-f.patch
+++ /dev/null
@@ -1,32 +0,0 @@
-From befcce7e25a74424b9c4c42cecd67daea71819da Mon Sep 17 00:00:00 2001
-From: Awais Belal <awais_belal@mentor.com>
-Date: Tue, 29 Jan 2019 15:02:45 +0500
-Subject: [PATCH 2/3] udev-extraconf/mount.sh: save mount name in our tmp file
- cache
-
-Doing this will allow to fetch the exact name created by the
-auto-mounter during the remove action where depending on the
-scenario utilities such as the blkid might not be usable due
-to actual device not being present on the system.
-
-Signed-off-by: Awais Belal <awais_belal@mentor.com>
----
- mount.sh | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-Index: 1.1-r0/mount.sh
-===================================================================
---- 1.1-r0.orig/mount.sh
-+++ 1.1-r0/mount.sh
-@@ -130,7 +130,10 @@ automount() {
- rm_dir "$MOUNT_BASE/$name"
- else
- logger "mount.sh/automount" "Auto-mount of [$MOUNT_BASE/$name] successful"
-- touch "/tmp/.automount-$name"
-+ # The actual device might not be present in the remove event so blkid cannot
-+ # be used to calculate what name was generated here. Simply save the mount
-+ # name in our tmp file.
-+ echo "$name" > "/tmp/.automount-$name"
- fi
- }
-
diff --git a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0003-udev-extraconf-mount.sh-only-mount-devices-on-hotplu.patch b/meta-mentor-staging/recipes-core/udev/udev-extraconf/0003-udev-extraconf-mount.sh-only-mount-devices-on-hotplu.patch
deleted file mode 100644
index 20d250e3..00000000
--- a/meta-mentor-staging/recipes-core/udev/udev-extraconf/0003-udev-extraconf-mount.sh-only-mount-devices-on-hotplu.patch
+++ /dev/null
@@ -1,86 +0,0 @@
-From 36c64467750823d42d5a4936afa6e96be6325bad Mon Sep 17 00:00:00 2001
-From: Awais Belal <awais_belal@mentor.com>
-Date: Tue, 29 Jan 2019 15:05:43 +0500
-Subject: [PATCH 3/3] udev-extraconf/mount.sh: only mount devices on hotplug
-
-fdisk from util-linux (2.31.1) and above allows the user to
-manipulate an already mounted device. In order to achieve this
-functionality it issues a BLKRRPART (block device re-read part)
-ioctl and in response the kernel generates remove/change/add
-events if the device is not mounted (manually unmounted etc)
-which are caught and processed by udev. This causes our auto-mounter
-to remount everything because it does not keep track and things
-go out of control.
-Differentiating between types of remove events such as the one
-described above (generated by BLKRRPART) and one where the device
-is physically plugged out is only possible using the DEVPATH variable
-which is cleaned up only when the device is actually plugged-out.
-This fixes the above anomaly by only mounting a device in add event
-which is cleaned up properly (tmp cache deleted) in the remove event
-or is not present in the tmp cache while making use of the DEVPATH
-variable during the remove action.
-
-Signed-off-by: Awais Belal <awais_belal@mentor.com>
----
- mount.sh | 33 ++++++++++++++++++++-------
- 1 file changed, 26 insertions(+), 7 deletions(-)
-
-Index: 1.1-r0/mount.sh
-===================================================================
---- 1.1-r0.orig/mount.sh
-+++ 1.1-r0/mount.sh
-@@ -45,6 +45,13 @@ automount_systemd() {
- return
- fi
-
-+ # Only go for auto-mounting when the device has been cleaned up in remove
-+ # or has not been identified yet
-+ if [ -e "/tmp/.automount-$name" ]; then
-+ logger "mount.sh/automount" "[$MOUNT_BASE/$name] is already cached"
-+ return
-+ fi
-+
- # Skip the partition which are already in /etc/fstab
- grep "^[[:space:]]*$DEVNAME" /etc/fstab && return
- for n in LABEL PARTLABEL UUID PARTUUID; do
-@@ -104,6 +111,13 @@ automount() {
- name="${LABEL}-${name}"
- fi
-
-+ # Only go for auto-mounting when the device has been cleaned up in remove
-+ # or has not been identified yet
-+ if [ -e "/tmp/.automount-$name" ]; then
-+ logger "mount.sh/automount" "[$MOUNT_BASE/$name] is already cached"
-+ return
-+ fi
-+
- ! test -d "$MOUNT_BASE/$name" && mkdir -p "$MOUNT_BASE/$name"
- # Silent util-linux's version of mounting auto
- if [ "x`readlink $MOUNT`" = "x/bin/mount.util-linux" ] ;
-@@ -164,12 +178,18 @@ if [ "$ACTION" = "add" ] && [ -n "$DEVNA
- fi
-
- if [ "$ACTION" = "remove" ] || [ "$ACTION" = "change" ] && [ -x "$UMOUNT" ] && [ -n "$DEVNAME" ]; then
-- for mnt in `cat /proc/mounts | grep "$DEVNAME" | cut -f 2 -d " " `
-- do
-- $UMOUNT $mnt
-- done
--
-- # Remove empty directories from auto-mounter
-- name="`basename "$DEVNAME"`"
-- test -e "/tmp/.automount-$name" && rm_dir "$MOUNT_BASE/$name"
-+ name="`basename "$DEVNAME"`"
-+ tmpfile=`find /tmp | grep "\.automount-.*${name}$"`
-+ if [ ! -e "/sys/$DEVPATH" -a -e "$tmpfile" ]; then
-+ logger "mount.sh/remove" "cleaning up $DEVNAME, was mounted by the auto-mounter"
-+ for mnt in `cat /proc/mounts | grep "$DEVNAME" | cut -f 2 -d " " `
-+ do
-+ $UMOUNT $mnt
-+ done
-+ # Remove mount directory created by the auto-mounter
-+ # and clean up our tmp cache file
-+ mntdir=`cat "$tmpfile"`
-+ rm_dir "$MOUNT_BASE/$mntdir"
-+ rm "$tmpfile"
-+ fi
- fi
diff --git a/meta-mentor-staging/recipes-core/udev/udev-extraconf/systemd-udevd.service b/meta-mentor-staging/recipes-core/udev/udev-extraconf/systemd-udevd.service
deleted file mode 100644
index a9b86eb6..00000000
--- a/meta-mentor-staging/recipes-core/udev/udev-extraconf/systemd-udevd.service
+++ /dev/null
@@ -1,3 +0,0 @@
-.include @systemd_unitdir@/system/systemd-udevd.service
-[Service]
-MountFlags=shared
diff --git a/meta-mentor-staging/recipes-core/udev/udev-extraconf_%.bbappend b/meta-mentor-staging/recipes-core/udev/udev-extraconf_%.bbappend
deleted file mode 100644
index 844a9e4a..00000000
--- a/meta-mentor-staging/recipes-core/udev/udev-extraconf_%.bbappend
+++ /dev/null
@@ -1,22 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/${PN}:"
-SRC_URI:append:feature-mentor-staging = " file://0001-udev-extraconf-mount.sh-add-LABELs-to-mountpoints.patch \
- ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'file://systemd-udevd.service', '', d)} \
- file://0002-udev-extraconf-mount.sh-save-mount-name-in-our-tmp-f.patch \
- file://0003-udev-extraconf-mount.sh-only-mount-devices-on-hotplu.patch \
- file://0001-udev-extraconf-mount.sh-ignore-lvm-in-automount.patch"
-
-RDEPENDS:${PN}:append:feature-mentor-staging = " util-linux-blkid"
-
-FILES:${PN}:append:feature-mentor-staging = " ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', '${sysconfdir}/systemd/system/systemd-udevd.service', '', d)}"
-
-do_install:append:feature-mentor-staging () {
- if ${@bb.utils.contains('DISTRO_FEATURES', 'systemd', 'true', 'false', d)}; then
- install -d ${D}${sysconfdir}/systemd/system
- install ${WORKDIR}/systemd-udevd.service ${D}${sysconfdir}/systemd/system/systemd-udevd.service
- sed -i 's|@systemd_unitdir@|${systemd_unitdir}|g' ${D}${sysconfdir}/systemd/system/systemd-udevd.service
- fi
-}
diff --git a/meta-mentor-staging/recipes-graphics/libsdl2/libsdl2_2.%.bbappend b/meta-mentor-staging/recipes-graphics/libsdl2/libsdl2_2.%.bbappend
deleted file mode 100644
index 1ac41114..00000000
--- a/meta-mentor-staging/recipes-graphics/libsdl2/libsdl2_2.%.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-CFLAGS:append:class-native = " -DNO_SHARED_MEMORY"
diff --git a/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/fix_dshare_status.patch b/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/fix_dshare_status.patch
deleted file mode 100644
index 4c6409a9..00000000
--- a/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/fix_dshare_status.patch
+++ /dev/null
@@ -1,21 +0,0 @@
-Upstream-Status: Pending
-
-Alsa plugin dshare is reporting incorrect stream state when it detects underrun
-Update stream state from pcm handle than slave pcm of dshare plugin
-
-Signed-off-by: Sanjeev Chugh <sanjeev_chugh@mentor.com>
-Signed-off-by: Mikhail Durnev <mikhail_durnev@mentor.com>
-
-Index: alsa-lib-1.1.3/src/pcm/pcm_dshare.c
-===================================================================
---- alsa-lib-1.1.3.orig/src/pcm/pcm_dshare.c 2017-03-26 09:38:40.150371765 +0500
-+++ alsa-lib-1.1.3/src/pcm/pcm_dshare.c 2017-03-26 09:40:03.878373271 +0500
-@@ -226,7 +226,7 @@
- snd_pcm_direct_t *dshare = pcm->private_data;
-
- memset(status, 0, sizeof(*status));
-- snd_pcm_status(dshare->spcm, status);
-+ snd_pcm_status(pcm, status);
-
- switch (dshare->state) {
- case SNDRV_PCM_STATE_DRAINING:
diff --git a/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/plug_fix_rate_converter_config.patch b/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/plug_fix_rate_converter_config.patch
deleted file mode 100644
index 8ec789a0..00000000
--- a/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib/plug_fix_rate_converter_config.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-Upstream-Status: Pending
-
-# Author: Andreas Pape <apape@de.adit-jv.com>
-# Date: Tue Feb 4 10:00:00 2014
-# pcm plug: save converter config.
-#
-# Passed config is freed after call to open, thus it is invalid when trying to extract the converter name.
-# This patch copies the config entry for later usage.
-#
-
-Index: alsa-lib-1.1.4.1/src/pcm/pcm_plug.c
-===================================================================
---- alsa-lib-1.1.4.1.orig/src/pcm/pcm_plug.c 2017-06-30 02:06:01.200623861 +0500
-+++ alsa-lib-1.1.4.1/src/pcm/pcm_plug.c 2017-06-30 02:06:01.196623861 +0500
-@@ -1122,6 +1122,8 @@
-
- err = snd_pcm_new(&pcm, SND_PCM_TYPE_PLUG, name, slave->stream, slave->mode);
- if (err < 0) {
-+ if (plug->rate_converter)
-+ snd_config_delete((snd_config_t*)plug->rate_converter);
- free(plug);
- return err;
- }
diff --git a/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib_1.2.%.bbappend b/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib_1.2.%.bbappend
deleted file mode 100644
index c664770f..00000000
--- a/meta-mentor-staging/recipes-multimedia/alsa/alsa-lib_1.2.%.bbappend
+++ /dev/null
@@ -1,10 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/${BPN}:"
-
-SRC_URI:append:feature-mentor-staging = "\
- file://plug_fix_rate_converter_config.patch \
- file://fix_dshare_status.patch \
-"
diff --git a/meta-mentor-staging/recipes-multimedia/alsa/alsa-utils/0001-alsa-utils-interrupt-streaming-via-signal.patch b/meta-mentor-staging/recipes-multimedia/alsa/alsa-utils/0001-alsa-utils-interrupt-streaming-via-signal.patch
deleted file mode 100644
index 7ff0646d..00000000
--- a/meta-mentor-staging/recipes-multimedia/alsa/alsa-utils/0001-alsa-utils-interrupt-streaming-via-signal.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From 0a6011294769c49652bda6f37b0282a29c55cbe9 Mon Sep 17 00:00:00 2001
-From: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
-Date: Mon, 19 Dec 2016 14:04:39 +0530
-Subject: [PATCH] alsa-utils: interrupt streaming via signal
-
-aplay/arecord (alsa-utils v1.1.2) cannot interrupt streaming
-via CTRL-C. Fixed the issue by properly handling 'in_aborting'
-flag in appropriate functions.
-
-Upstream-Status: Pending
-
-Signed-off-by: Anant Agrawal <Anant_Agrawal@mentor.com>
-Signed-off-by: Mikhail Durnev <mikhail_durnev@mentor.com>
-Signed-off-by: Srikanth Krishnakar <Srikanth_Krishnakar@mentor.com>
----
- aplay/aplay.c | 20 ++++++++++++++------
- 1 file changed, 14 insertions(+), 6 deletions(-)
-
-Index: alsa-utils-1.1.5/aplay/aplay.c
-===================================================================
---- alsa-utils-1.1.5.orig/aplay/aplay.c 2017-12-22 00:15:51.570478262 +0500
-+++ alsa-utils-1.1.5/aplay/aplay.c 2017-12-22 00:15:51.566478262 +0500
-@@ -396,14 +396,22 @@
- putchar('\n');
- if (!quiet_mode)
- fprintf(stderr, _("Aborted by signal %s...\n"), strsignal(sig));
-- if (handle)
-+ if (stream == SND_PCM_STREAM_CAPTURE) {
-+ if (fmt_rec_table[file_type].end) {
-+ fmt_rec_table[file_type].end(fd);
-+ fd = -1;
-+ }
-+ stream = -1;
-+ }
-+ if (fd > 1) {
-+ close(fd);
-+ fd = -1;
-+ }
-+ if (handle && sig != SIGABRT) {
- snd_pcm_abort(handle);
-- if (sig == SIGABRT) {
-- /* do not call snd_pcm_close() and abort immediately */
- handle = NULL;
-- prg_exit(EXIT_FAILURE);
- }
-- signal(sig, SIG_DFL);
-+ prg_exit(EXIT_FAILURE);
- }
-
- /* call on SIGUSR1 signal. */
diff --git a/meta-mentor-staging/recipes-multimedia/alsa/alsa-utils_1.2%.bbappend b/meta-mentor-staging/recipes-multimedia/alsa/alsa-utils_1.2%.bbappend
deleted file mode 100644
index 14d23c64..00000000
--- a/meta-mentor-staging/recipes-multimedia/alsa/alsa-utils_1.2%.bbappend
+++ /dev/null
@@ -1,8 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-FILESEXTRAPATHS:prepend:feature-mentor-staging := "${THISDIR}/${PN}:"
-
-# Interrupt streaming via CTRL-C
-SRC_URI:append:feature-mentor-staging = " file://0001-alsa-utils-interrupt-streaming-via-signal.patch"
diff --git a/meta-mentor-staging/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend b/meta-mentor-staging/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend
deleted file mode 100644
index 354e547e..00000000
--- a/meta-mentor-staging/recipes-multimedia/pulseaudio/pulseaudio_%.bbappend
+++ /dev/null
@@ -1,9 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-RDEPENDS:pulseaudio-module-systemd-login:append:feature-mentor-staging = " systemd"
-RDEPENDS:pulseaudio-server:append:feature-mentor-staging = "\
- ${@bb.utils.contains('PACKAGECONFIG', 'systemd', 'pulseaudio-module-systemd-login', '', d)} \
- ${@bb.utils.contains('PACKAGECONFIG', 'bluez5', 'pulseaudio-module-bluetooth-discover pulseaudio-module-bluez5-discover pulseaudio-module-bluez5-device', '', d)} \
-"
diff --git a/meta-mentor-staging/recipes-support/curl/curl_%.bbappend b/meta-mentor-staging/recipes-support/curl/curl_%.bbappend
deleted file mode 100644
index 52b9c62e..00000000
--- a/meta-mentor-staging/recipes-support/curl/curl_%.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-EXTRA_OECONF:append = " \
- --with-ca-path=${sysconfdir}/ssl/certs \
-"
diff --git a/meta-mentor-staging/security/recipes-ids/tripwire/tripwire_%.bbappend b/meta-mentor-staging/security/recipes-ids/tripwire/tripwire_%.bbappend
deleted file mode 100644
index e0a7ed66..00000000
--- a/meta-mentor-staging/security/recipes-ids/tripwire/tripwire_%.bbappend
+++ /dev/null
@@ -1,24 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-# Use vi by default to avoid pulling in nano
-RDEPENDS_REMOVE = "nano"
-RDEPENDS:${PN}:remove:feature-mentor-staging = " ${RDEPENDS_REMOVE}"
-
-do_install:append:feature-mentor-staging () {
- # When submitting upstream, modify twcfg.txt in the layer instead
- sed -i -e 's#^EDITOR[[:space:]]*=.*#EDITOR=/usr/bin/vi#' ${D}${sysconfdir}/${PN}/twcfg.txt
- if grep -q nano ${D}${sysconfdir}/${PN}/twcfg.txt; then
- bbfatal "EDITOR adjustment failed"
- fi
-
- # The main recipe installs the installation script to
- # /etc which isn't meant for such stuff (executables)
- # move it to a more appropriate location
- if [ -e "${D}${sysconfdir}/tripwire/twinstall.sh" ]; then
- rm -f "${D}${sysconfdir}/tripwire/twinstall.sh"
- fi
- install -d "${D}${bindir}"
- install -m 0755 "${WORKDIR}/twinstall.sh" "${D}${bindir}/"
-}
diff --git a/meta-mentor-staging/security/recipes-security/nikto/nikto_%.bbappend b/meta-mentor-staging/security/recipes-security/nikto/nikto_%.bbappend
deleted file mode 100644
index 4a56379c..00000000
--- a/meta-mentor-staging/security/recipes-security/nikto/nikto_%.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-RDEPENDS:${PN}:append:feature-mentor-staging = " perl-module-list-util perl-module-bignum"
diff --git a/meta-mentor-staging/security/recipes-security/scapy/python3-scapy_%.bbappend b/meta-mentor-staging/security/recipes-security/scapy/python3-scapy_%.bbappend
deleted file mode 100644
index 557e0fd4..00000000
--- a/meta-mentor-staging/security/recipes-security/scapy/python3-scapy_%.bbappend
+++ /dev/null
@@ -1,7 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-RDEPENDS:${PN}:append:feature-mentor-staging = "\
- ${PYTHON_PN}-fcntl \
-"
diff --git a/meta-mentor-staging/selinux/recipes-security/selinux/libselinux-python_3.0.bbappend b/meta-mentor-staging/selinux/recipes-security/selinux/libselinux-python_3.0.bbappend
deleted file mode 100644
index 07662dc2..00000000
--- a/meta-mentor-staging/selinux/recipes-security/selinux/libselinux-python_3.0.bbappend
+++ /dev/null
@@ -1,5 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-inherit python3targetconfig
diff --git a/scripts/bb-determine-layers b/scripts/bb-determine-layers
deleted file mode 100755
index 83583474..00000000
--- a/scripts/bb-determine-layers
+++ /dev/null
@@ -1,550 +0,0 @@
-#!/usr/bin/env python3
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-import argparse
-import collections
-import collections.abc
-import contextlib
-import glob
-import os
-import signal
-import sys
-
-
-glob_default = './*/:./*/*/:{scriptdir}/../../*/:{scriptdir}/../../*/*/'
-layers_default = 'core'
-override_default = ''
-
-
-class Terminate(BaseException):
- """Exception raised if we receive a SIGTERM"""
- pass
-
-
-def sigterm_exception(signum, stackframe):
- """Raise Terminate exception if we receive a SIGTERM"""
- raise Terminate()
-
-
-def setup_command_import(command, relpath='../lib'):
- """Set up sys.path based on the location of a binary in the PATH """
- PATH = os.environ['PATH'].split(':')
- cmd_paths = [os.path.join(path, relpath)
- for path in PATH if os.path.exists(os.path.join(path, command))]
- if not cmd_paths:
- raise ImportError("Unable to locate bb, please ensure PATH is set correctly.")
-
- sys.path[0:0] = cmd_paths
-
-
-def find(dir, dirfilter=None, **walkoptions):
- """ Given a directory, recurse into that directory,
- returning all files as absolute paths. """
-
- for root, dirs, files in os.walk(dir, **walkoptions):
- if dirfilter is not None:
- for d in dirs:
- if not dirfilter(d):
- dirs.remove(d)
-
- for file in files:
- yield os.path.join(root, file)
-
-
-class StatusDisplay(object):
- """Show the user what we're doing, and whether we succeed"""
-
- def __init__(self, message, output=None):
- self.message = message
- if output is None:
- output = sys.stderr
- self.output = output
- self.finished = False
-
- def __enter__(self):
- self.output.write('{}..'.format(self.message))
- self.output.flush()
- return self
-
- def __exit__(self, exc_type, exc_value, traceback):
- if self.finished:
- return
-
- if not exc_type:
- self.set_status('done')
- elif isinstance(exc_value, KeyboardInterrupt):
- self.set_status('interrupted')
- elif isinstance(exc_value, Terminate):
- self.set_status('terminated')
- else:
- self.set_status('failed')
-
- def set_status(self, finishmessage):
- if self.finished:
- raise Exception("Status is already finished")
- self.output.write('.' + finishmessage + '\n')
- self.finished = True
-
-
-status = StatusDisplay
-
-
-class DictArgument(object):
- def __init__(self, listsep=None, valuesep='=', keytype=None, valuetype=None):
- self.listsep = listsep
- self.valuesep = valuesep
- self.keytype = keytype
- self.valuetype = valuetype
-
- def __call__(self, string):
- d = {}
- for o in string.split(self.listsep):
- try:
- k, v = o.rsplit(self.valuesep, 1)
- except ValueError:
- raise argparse.ArgumentTypeError('invalid entry `{0}`'.format(o))
-
- if self.keytype is not None:
- try:
- k = self.keytype(k)
- except ValueError:
- raise argparse.ArgumentTypeError('invalid key `{0}` for type `{1}`'.format(k, self.keytype.__name__))
-
- if self.valuetype is not None:
- try:
- v = self.valuetype(v)
- except ValueError:
- raise argparse.ArgumentTypeError('invalid value `{0}` for type `{1}`'.format(v, self.valuetype.__name__))
-
- d[k] = v
- return d
-
- def __repr__(self):
- return 'DictArgument(listsep={0}, valuesep={1}, keytype={2}, valuetype={3})'.format(repr(self.listsep), repr(self.valuesep), repr(self.keytype), repr(self.valuetype))
-
-
-def process_arguments(cmdline_args):
- parser = argparse.ArgumentParser(description='Determine the bitbake layers to use for a given machine, with sanity checks')
- parser.add_argument('-l', '--layers', default=layers_default,
- help='base layers to include. space separated. default: `{0}`'.format(layers_default))
- parser.add_argument('-o', '--optional-layers', default='',
- help='optional layers to include. space separated. These layers are included if they and their dependencies are available, but are silently left out otherwise.')
- parser.add_argument('-e', '--extra-layers', default='',
- help='extra layers to include. space separated. These layers are expected to exist, but are only included if their dependencies are already included in the configuration.')
- parser.add_argument('-x', '--excluded-layers', default='',
- help='explicit layers to excluded. space separated.')
- parser.add_argument('-O', '--override-layer-priorities', default=override_default,
- type=DictArgument(valuetype=int),
- help='override the priority of one or more layers. space separated list of layername=priority values. default: `{0}`'.format(override_default))
- parser.add_argument('-g', '--globs', default=glob_default,
- help='wildcard patterns to locate layers. colon separated. default: `{0}`'.format(glob_default))
- parser.add_argument('-p', '--paths',
- help='paths to search recursively to find layers. colon separated. equivalent to the "find" command', default='')
- parser.add_argument('-m', '--machine', help='add layer(s) providing the specified MACHINE')
- parser.add_argument('-d', '--distro', help='add layer(s) providing the specified DISTRO')
- parser.add_argument('-s', '--sdkmachine', help='add layer(s) providing the specified SDKMACHINE')
- parser.add_argument('-v', '--verbose', help='increase verbosity', action='store_true')
-
- scriptdir = os.path.dirname(__file__)
- args = parser.parse_args(cmdline_args)
-
- args.layers = args.layers.split()
- args.optional_layers = args.optional_layers.split()
- args.extra_layers = args.extra_layers.split()
- args.excluded_layers = args.excluded_layers.split()
-
- new_globs = []
- for pattern in args.globs.split(':'):
- pattern = os.path.abspath(pattern.format(scriptdir=scriptdir))
- new_globs.append(pattern)
- args.globs = new_globs
-
- new_paths = []
- if args.paths:
- for path in args.paths.split(':'):
- path = os.path.abspath(path.format(scriptdir=scriptdir))
- new_paths.append(path)
- args.paths = new_paths
-
- return args
-
-
-class LayerError(Exception):
- pass
-
-
-class Layer(object):
- def __init__(self, path, confpath, name, version, priority, pattern, depends, recommends):
- self.path = os.path.realpath(path)
- self.confpath = os.path.realpath(confpath)
- self.name = name
- self.version = version
- self.priority = priority
- self.depends = depends
- self.recommends = recommends
- self.missingdeps = set()
- self.pattern = pattern
-
- def __repr__(self):
- return '{0.__class__.__name__}({0.path!r}, {0.confpath!r},' \
- '{0.name!r}, {0.version!r}, {0.priority!r}, {0.pattern!r}, {0.depends!r}, {0.recommends!r})'.format(self)
-
- def __hash__(self):
- return hash(repr(self))
-
- @staticmethod
- def from_layerpath(layer_path, data=None):
- layers = []
-
- if data is None:
- data = bb.data.init()
- bb.parse.init_parser(data)
-
- lconf = os.path.join(layer_path, 'conf', 'layer.conf')
- ldata = data.createCopy()
- ldata.setVar('LAYERDIR', layer_path)
- try:
- ldata = bb.parse.handle(lconf, ldata, include=True)
- except BaseException as exc:
- raise LayerError(exc)
- ldata.expandVarref('LAYERDIR')
-
- bbfile_collections = (ldata.getVar('BBFILE_COLLECTIONS', True) or '').split()
- if not bbfile_collections:
- name = os.path.basename(layer_path)
- l = Layer(layer_path, lconf, name, 0, 0, None, {})
- layers.append(l)
-
- for name in bbfile_collections:
- pattern = ldata.getVar('BBFILE_PATTERN_%s' % name, True)
- priority = ldata.getVar('BBFILE_PRIORITY_%s' % name, True) or 0
- depends = ldata.getVar('LAYERDEPENDS_%s' % name, True) or ''
- version = ldata.getVar('LAYERVERSION_%s' % name, True)
- depends = bb.utils.explode_dep_versions2(depends)
- recommends = ldata.getVar('LAYERRECOMMENDS_%s' % name, True) or ''
- recommends = bb.utils.explode_dep_versions2(recommends)
-
- l = Layer(layer_path, lconf, name, version, int(priority), pattern, depends, recommends)
- layers.append(l)
-
- if layers:
- return layers
-
-
-class Layers(collections.abc.MutableSet):
- def __init__(self, iterable=None):
- """A collection of layers. Maintains lookup mappings by path and name"""
- self.layers = set()
- self.duplicates = collections.defaultdict(set)
- self.by_path = {}
- self.by_name = {}
-
- if iterable is not None:
- self |= iterable
-
- def __contains__(self, layer):
- return layer in self.layers
-
- def __iter__(self):
- return iter(self.layers)
-
- def __len__(self):
- return len(self.layers)
-
- def __repr__(self):
- return '{0.__class__.__name__}({0.layers!r})'.format(self)
-
- def __hash__(self):
- return hash(repr(self))
-
- def add(self, layer):
- if layer in self:
- return
-
- if layer.path in self.by_path:
- return
-
- if layer.name in self.by_name:
- self.duplicates[layer.name].add(self.by_name[layer.name])
- self.duplicates[layer.name].add(layer)
- return
-
- self.layers.add(layer)
- self.by_path[layer.path] = layer
- self.by_name[layer.name] = layer
-
- def add_from_path(self, layerpath, data=None):
- layerpath = os.path.realpath(layerpath)
- if layerpath in self.by_path:
- return
-
- self |= Layer.from_layerpath(layerpath, data)
-
- def discard(self, layer):
- self.layers.discard(layer)
- del self.by_path[layer.path]
- del self.by_name[layer.name]
-
- def clear(self):
- self.layers.clear()
- self.by_path.clear()
- self.by_name.clear()
-
- def priority_sorted(self):
- return sorted(self.layers, key=lambda l: (l.priority, l.name), reverse=True)
-
- def which(self, path, all=True):
- layers = []
- for layer in self.priority_sorted():
- if os.path.exists(os.path.join(layer.path, path)):
- layers.append(layer)
- return layers
-
- def get_by_name_recursive(self, name, include_recs=True, indirect_recs=False):
- """Get a layer by name and its dependencies, recursively.
-
- Returns a Layers() collection, and a list of missing dependencies."""
-
- missing = set()
- found_layers = Layers()
-
- if not include_recs:
- indirect_recs = False
-
- if name in self.duplicates:
- raise DuplicateLayers(name, self.duplicates[name])
-
- try:
- layer = self.by_name[name]
- except KeyError:
- missing.add(name)
- else:
- found_layers.add(layer)
- for dep, oplist in layer.depends.items():
- try:
- dep_found, dep_missing = self.get_by_name_recursive(dep, indirect_recs, indirect_recs)
- except KeyError:
- missing.add(dep)
- continue
-
- for _dep in dep_found:
- for opstr in oplist:
- op, depver = opstr.split()
- if _dep.version:
- try:
- res = bb.utils.vercmp_string_op(_dep.version, depver, op)
- except bb.utils.VersionStringException as vse:
- missing.add(dep)
- else:
- if not res:
- missing.add(dep)
-
- if dep not in missing:
- found_layers |= dep_found
- missing |= dep_missing
-
- if include_recs:
- for rec, oplist in layer.recommends.items():
- found = True
-
- try:
- rec_found, _ = self.get_by_name_recursive(rec, indirect_recs, indirect_recs)
- except KeyError:
- continue
-
- for _rec in rec_found:
- for opstr in oplist:
- op, recver = opstr.split()
- if _rec.version:
- try:
- res = bb.utils.vercmp_string_op(_rec.version, recver, op)
- except bb.utils.VersionStringException as vse:
- found = False
- else:
- if not res:
- found = False
-
- if found and rec not in missing:
- found_layers |= rec_found
-
- return found_layers, missing
-
-
-class DuplicateLayers(Exception):
- def __init__(self, name, layers):
- self.name = name
- self.layers = layers
-
- def __str__(self):
- return 'Duplicate layers found for %s:\n%s' % (self.name, ''.join(' %s\n' % l.path for l in self.layers))
-
-
-class LayerStatus(StatusDisplay):
- """Show status of work whose results are a set of layers."""
-
- def __init__(self, message, verbose=False, output=None):
- super(LayerStatus, self).__init__(message, output)
- self.verbose = verbose
-
- def set_layer_status(self, layers):
- layer_names = set(l.name for l in layers)
- if self.verbose:
- self.set_status('')
- for f in sorted(l.path for l in layers):
- self.output.write(' %s\n' % f)
- else:
- self.set_status(','.join(sorted(layer_names)))
-
-
-def get_layerpaths_bitbake(globs=None, paths=None):
- bitbake_path = None
- layer_paths = set()
-
- for pattern in globs:
- for glob_path in glob.glob(pattern):
- layerconf_path = os.path.join(glob_path, 'conf', 'layer.conf')
- if os.path.exists(layerconf_path):
- layer_paths.add(os.path.realpath(glob_path))
- elif not bitbake_path and os.path.exists(os.path.join(glob_path, 'bin', 'bitbake')):
- bitbake_path = os.path.join(glob_path, 'bin')
- if not os.path.exists(os.path.join(bitbake_path, '..', 'lib', 'bb')):
- bitbake_path = None
-
- for path in paths:
- for subpath in find(path, dirfilter=lambda d: d != 'lib'):
- if subpath.endswith('/conf/layer.conf'):
- layer_paths.add(os.path.realpath(os.path.dirname(os.path.dirname(subpath))))
- elif not bitbake_path and subpath.endswith('/bin/bitbake'):
- bitbake_path = os.path.dirname(subpath)
- if not os.path.exists(os.path.join(bitbake_path, '..', 'lib', 'bb')):
- bitbake_path = None
-
- return layer_paths, bitbake_path
-
-
-
-def get_layers_for(all_layers, value, varname, cfgpath, verbose=False):
- with LayerStatus("Determining layers to include for {0} '{1}'".format(varname, value), verbose=verbose) as s:
- layers = all_layers.which('conf/{0}/{1}.conf'.format(cfgpath, value))
- if not layers:
- sys.exit("No layer found for {0} `{1}`".format(varname, value))
-
- found_layers = Layers()
- for name in set(l.name for l in layers):
- layers, missing_layers = all_layers.get_by_name_recursive(name)
- found_layers |= layers
- if name in missing_layers:
- sys.exit('Layer `{0}` was not found'.format(name))
- elif missing_layers:
- sys.exit("Layer `{0}` was found, but its dependencies are missing: `{1}`".format(name, ', '.join(missing_layers)))
- s.set_layer_status(found_layers)
- return found_layers
-
-
-def determine_layers(cmdline_opts):
- args = process_arguments(cmdline_opts)
- args.layers.append('core')
-
- with status('Locating layers and bitbake'):
- layer_paths, bitbake_path = get_layerpaths_bitbake(args.globs, args.paths)
- if bitbake_path is not None:
- os.environ['PATH'] += ':' + bitbake_path
-
- setup_command_import('bitbake')
- try:
- import bb
- except (ImportError, RuntimeError) as exc:
- sys.exit("Unable to import 'bb' python package: %s" % exc)
-
- import bb.parse
- import bb.data
-
- data = bb.data.init()
- bb.parse.init_parser(data)
-
- all_layers = Layers()
- with status('Parsing layer configuration files'):
- for layer_path in layer_paths:
- try:
- all_layers.add_from_path(layer_path, data)
- except LayerError as exc:
- sys.stderr.write('Warning: error parsing layer at {}\n'.format(layer_path))
-
- for layer in list(all_layers):
- if layer.name in args.excluded_layers:
- all_layers.discard(layer)
- else:
- priority_override = args.override_layer_priorities.get(layer.name)
- if priority_override is not None:
- layer.priority = priority_override
-
- configured_layers = Layers()
- with LayerStatus('Checking for base layers', verbose=args.verbose) as s:
- found = set()
- for name in args.layers:
- if name in all_layers.by_name:
- layers, missing_layers = all_layers.get_by_name_recursive(name)
- if missing_layers:
- sys.exit("Layer `{0}` was found, but its dependencies are missing: `{1}`".format(name, ', '.join(missing_layers)))
- else:
- found.update(layers)
-
- s.set_layer_status(found)
- configured_layers |= found
-
- if args.distro and args.distro != 'nodistro':
- configured_layers |= get_layers_for(all_layers, args.distro, 'DISTRO', 'distro', args.verbose)
-
- if args.machine:
- configured_layers |= get_layers_for(all_layers, args.machine, 'MACHINE', 'machine', args.verbose)
-
- if args.sdkmachine:
- configured_layers |= get_layers_for(all_layers, args.sdkmachine, 'SDKMACHINE', 'machine-sdk', args.verbose)
-
- if args.optional_layers:
- with LayerStatus('Checking for optional layers', verbose=args.verbose) as s:
- found_optional = set()
- for name in args.optional_layers:
- if name in all_layers.by_name:
- layers, missing_layers = all_layers.get_by_name_recursive(name)
- if missing_layers:
- sys.stderr.write("Warning: optional layer `{0}` was found, but its dependencies are missing: `{1}`".format(name, ', '.join(missing_layers)))
- else:
- found_optional.update(layers)
-
- found_optional.difference_update(configured_layers)
- s.set_layer_status(found_optional)
- configured_layers |= found_optional
-
- if args.extra_layers:
- with LayerStatus('Checking for extra layers', verbose=args.verbose) as s:
- found_extra = set()
- for name in args.extra_layers:
- if name in all_layers.by_name:
- layers, missing_layers = all_layers.get_by_name_recursive(name)
- if not missing_layers:
- found_extra.update(layers)
-
- found_extra.difference_update(configured_layers)
- s.set_layer_status(found_extra)
- configured_layers |= found_extra
-
- for layer in configured_layers.priority_sorted():
- print(layer.path)
-
-
-if __name__ == '__main__':
- signal.signal(signal.SIGTERM, sigterm_exception)
- try:
- sys.exit(determine_layers(sys.argv[1:]) or 0)
- except DuplicateLayers as exc:
- sys.exit(str(exc))
- except KeyboardInterrupt:
- signal.signal(signal.SIGINT, signal.SIG_DFL)
- os.kill(os.getpid(), signal.SIGINT)
- except Terminate:
- signal.signal(signal.SIGTERM, signal.SIG_DFL)
- os.kill(os.getpid(), signal.SIGTERM)
diff --git a/scripts/bb-print-layer-data b/scripts/bb-print-layer-data
deleted file mode 100755
index afbefe93..00000000
--- a/scripts/bb-print-layer-data
+++ /dev/null
@@ -1,129 +0,0 @@
-#!/usr/bin/env python3
-#
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-#
-# Given a layer or layer.conf path, print the layer metadata
-
-import contextlib
-import os
-import signal
-import sys
-from operator import itemgetter
-
-
-class Terminate(BaseException):
- pass
-
-
-def sigterm_exception(signum, stackframe):
- raise Terminate()
-
-
-def setup_command_import(command, relpath='../lib'):
- """Set up sys.path based on the location of a binary in the PATH """
- PATH = os.getenv('PATH').split(':')
- cmd_paths = [os.path.join(path, relpath)
- for path in PATH if os.path.exists(os.path.join(path, command))]
- if not cmd_paths:
- raise ImportError("Unable to locate bb, please ensure PATH is set correctly.")
-
- sys.path[0:0] = cmd_paths
-
-
-@contextlib.contextmanager
-def status(message, outfile=sys.stderr):
- """Show the user what we're doing, and whether we succeed"""
- outfile.write('{0}..'.format(message))
- outfile.flush()
- try:
- yield
- except KeyboardInterrupt:
- outfile.write('.interrupted\n')
- raise
- except Terminate:
- outfile.write('.terminated\n')
- raise
- except BaseException:
- outfile.write('.failed\n')
- raise
- outfile.write('.done\n')
-
-
-class LayerError(Exception):
- pass
-
-
-def get_layer_data(layer_path, lconf=None, data=None):
- if lconf is None:
- lconf = os.path.join(layer_path, 'conf', 'layer.conf')
-
- if data is None:
- ldata = bb.data.init()
- bb.parse.init_parser(ldata)
- else:
- ldata = data.createCopy()
-
- ldata.setVar('LAYERDIR', layer_path)
- try:
- ldata = bb.parse.handle(lconf, ldata, include=True)
- except BaseException as exc:
- raise LayerError(exc)
- ldata.expandVarref('LAYERDIR')
-
- collections = (ldata.getVar('BBFILE_COLLECTIONS', True) or '').split()
- if not collections:
- name = os.path.basename(layer_path)
- collections = [name]
-
- for name in collections:
- priority = ldata.getVar('BBFILE_PRIORITY_%s' % name, True)
- pattern = ldata.getVar('BBFILE_PATTERN_%s' % name, True)
- depends = ldata.getVar('LAYERDEPENDS_%s' % name, True)
- yield name, priority, layer_path, pattern, depends
-
-
-def print_layer_data(cmdline_opts):
- if len(cmdline_opts) < 1:
- return "Usage: bb-print-layer-data LCONF|LAYERDIR [LCONF|LAYERDIR..]\n"
-
- setup_command_import('bitbake')
- try:
- import bb
- except ImportError as exc:
- sys.exit("Unable to import 'bb' python package: %s" % exc)
-
- import bb.parse
- import bb.data
-
- data = bb.data.init()
- bb.parse.init_parser(data)
-
- collections = set()
-
- for layer_path in cmdline_opts:
- if os.path.isdir(layer_path):
- lconf = os.path.join(layer_path, 'conf', 'layer.conf')
- else:
- lconf = layer_path
- layer_path = os.path.dirname(os.path.dirname(lconf))
-
- with status("Parsing {0}".format(lconf)):
- collections |= set(get_layer_data(layer_path, lconf, data))
-
- priority_key = lambda i: int(i[1]) if i[1] is not None else None
- for name, priority, layer_path, pattern, depends in sorted(collections, key=priority_key):
- print("{0}: {1}|{2}|{3}|{4}".format(name, priority or '', layer_path, pattern or '', depends or ''))
-
-
-if __name__ == '__main__':
- signal.signal(signal.SIGTERM, sigterm_exception)
- try:
- sys.exit(print_layer_data(sys.argv[1:]) or 0)
- except KeyboardInterrupt:
- signal.signal(signal.SIGINT, signal.SIG_DFL)
- os.kill(os.getpid(), signal.SIGINT)
- except Terminate:
- signal.signal(signal.SIGTERM, signal.SIG_DFL)
- os.kill(os.getpid(), signal.SIGTERM)
diff --git a/scripts/build-setup-environment.in b/scripts/build-setup-environment.in
deleted file mode 100644
index f326c688..00000000
--- a/scripts/build-setup-environment.in
+++ /dev/null
@@ -1,23 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-if [ -n "$BASH_SOURCE" ]; then
- BUILDDIR="$(cd "$(dirname "$BASH_SOURCE")" && pwd -P)"
-elif [ -n "$ZSH_NAME" ]; then
- BUILDDIR="$(cd "$(dirname "$0")" && pwd -P)"
-else
- BUILDDIR="$(pwd -P)"
-fi
-export TEMPLATECONF="@TEMPLATECONF@"
-OEINIT="$(find "@OEROOT@" -maxdepth 1 -name \*-init-build-env | head -n 1)"
-if [ -z "$OEINIT" ]; then
- echo >&2 "oe-init-build-env not found in @OEROOT@"
- false
-else
- . "$OEINIT" "$BUILDDIR" "@BITBAKEDIR@"
- export BB_ENV_PASSTHROUGH_ADDITIONS="$BB_ENV_PASSTHROUGH_ADDITIONS GIT_SSL_CAINFO MGLS_LICENSE_FILE LM_LICENSE_FILE"
- unset TEMPLATECONF OEINIT
- cd "$BUILDDIR"
- command -v bitbake >/dev/null 2>&1
-fi
diff --git a/scripts/capdebuginfo b/scripts/capdebuginfo
deleted file mode 100755
index 72b96b2f..00000000
--- a/scripts/capdebuginfo
+++ /dev/null
@@ -1,292 +0,0 @@
-#!/bin/bash
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0
-# ---------------------------------------------------------------------------------------------------------------------
-
-###############################################################################
-# Name: Capture/Debug Information Tool
-# Description:
-# Script to capture debug info from a MEL user's host
-#
-#
-# Copyright 2022 Siemens
-#
-# This file is licensed under the terms of the GNU General Public License
-# version 2. This program is licensed "as is" without any warranty of any
-# kind, whether express or implied.
-
-# Variables
-unset BUILDERR # Path and filename of the MEL build error log file
-unset MELDIR # Root path of the MEL installation directory
-
-HOMEDIR=${HOME}
-HOSTINFOFILE="hostinfo.txt" # File containing info captured from user's host
-OUTPUTDIRNAME="capdebuginfo" # Directory containing all info captured by script
-SCRIPT_NAME="$(basename ${BASH_SOURCE})"
-MGLS_LICENSE="MGLS_LICENSE_FILE"
-LM_LICENSE="LM_LICENSE_FILE"
-
-
-usage () {
- cat >&2 <<END
-
-Description:
- Capture debug info from a MEL user's host such as host environment and project log files.
- The Script runs only if environment of the shell is already set using setup-environment script.
-
-Modes of operation:
- With input arguments: ${SCRIPT_NAME} -e <PN>
-
- Without input arguments: ${SCRIPT_NAME}
-
-Usage: ${SCRIPT_NAME} -e <PN>
- or ${SCRIPT_NAME}
-
- -e <PN> Specify the name of package causing build failure
- -h Show this usage information
-
-END
-}
-
-
-abspath () {
- readlink -e "${1}"
-}
-
-# Process input arguments to the script
-# Input: $@
-process_cmdline_args () {
- while getopts ":e:h" opt; do
- case "${opt}" in
- e)
- # Handle getops with invalid input
- if [[ "${OPTARG}" == -* ]] ; then
- echo "Invalid input for option -"${opt}""
- shift $((OPTIND-1))
- break
- else
- BUILDERR=$(find "${BUILDDIR}/tmp/work/" -maxdepth 2 -type d -name "${OPTARG}")
- fi
- ;;
- :)
- echo "Option -"${OPTARG}" requires an argument." >&2
- ;;
- \?)
- echo "Invalid option: -"${OPTARG}"" >&2
- ;;
- h)
- usage
- exit 1
- ;;
- esac
- done
-}
-
-
-# Collect information from host
-# Input: $1=Output directory name
-# $2=Filename for host info collection
-get_hostinfo () {
- local __output="${1}/host/${2}"
-
- echo -en "\\nHost Distro Info:\\n" >> "${__output}"
- lsb_release -a >> "${__output}" 2> /dev/null
- echo -en "\\nHost System Info:\\n" >> "${__output}"
- uname -a >> "${__output}"
- echo -en "\\nHost env Info:\\n" >> "${__output}"
- printenv | sort >> "${__output}"
- echo -en "\\nHost disk space usage:\\n" >> "${__output}"
- df -h >> "${__output}"
- echo -en "\\nHost memory usage:\\n" >> "${__output}"
- free -ht >> "${__output}"
- echo -en "\\n" >> "${__output}"
-}
-
-
-# Collect license info from host
-# Input: $1=Output directory name
-# $2=Filename for host info collection
-# $3=License info variable name
-get_hostlicenseinfo () {
- local __outputdir="${1}"
- local __output=""${1}"/host/"${2}""
- local __licensename="${3}"
- local __license=$(printenv "${3}")
-
- echo -en "\\n\"${__licensename}\":\\n" >> "${__output}"
- # Check if license variable is set in shell environment
- if [ -n "${__license}" ]; then
- echo -en "\"${__license}\"\\n" >> "${__output}"
- # Process license variable string
- for i in $(echo "${__license//:/$'\\n'}"); do
- # Check if entry is a license file and exists
- if [ -f "${i}" ]; then
- # Make a copy of the license file
- cp "${i}" "${__outputdir}"/host/.
- # Check if entry is a license server
- elif [[ "${i}" == *"@"* ]]; then
- echo -en "\\n\"${i}\" is a license server\\n" >> "${__output}"
- # Entry is invalid
- else
- echo -en "\\n\"${i}\" does not seem to be a valid entry\\n" >> "${__output}"
- fi
- done
- else
- echo -en "\\n\"${__licensename}\" is not set!\\n" >> "${__output}"
- fi
-}
-
-
-# Collect prerequisite packages/libraries from host
-# Input: $1=Output directory name
-# $2=Filename for host info collection
-
-get_hostprereqsinfo () {
- local __outputdir="${1}"
- local __output="${1}/host/${2}"
- local __hostos_distid=`lsb_release -i -s`
- local __hostos_distvers=`lsb_release -r -s`
- local __pkgs
-
- echo -en "\nHost OS is ${__hostos_distid} ${__hostos_distvers}:\n" >> ${__output}
- case "${__hostos_distid}" in
- Ubuntu)
- __pkgs="bmap-tools bzip2 chrpath cvs diffstat gawk gcc git-core gzip g++ \
- libgl1-mesa-dev libglu1-mesa-dev libncurses5-dev libsdl1.2-dev \
- lsb-release make patch python python3 subversion tar texinfo \
- texi2html ubuntu-minimal ubuntu-standard zip"
- dpkg-query -W -f='${binary:Package} ${Version} ${db:Status-Status}\n' ${__pkgs} >> ${__output}
- ;;
- CentOS|RedHat*)
- __pkgs="bzip2 chrpath cvs diffstat gawk gcc gcc-c++ git glibc-devel \
- glibc-static gzip make ncurses-devel patch perl-Thread-Queue \
- python python34 python-virtualenv redhat-lsb SDL-devel sqlite \
- subversion tar tetex texinfo texi2html wget"
- rpm -q ${__pkgs} >> ${__output}
- ;;
- esac
-}
-
-# Collect MEL installation info from host
-# Input: $1=Output directory name
-# $2=Filename for host info collection
-get_melinstallinfo () {
- local __outputdir="${1}"
- local __output="${1}/host/${2}"
-
- if [ -d "${HOMEDIR}"/.mentor ]; then
- cp -a "${HOMEDIR}"/.mentor/.registry "${__outputdir}"/host/mentor-registry
- else
- echo -en "\\nNo MEL install info found!\\n" >> ${__output}
- fi
-}
-
-
-# Collect MEL project build and error logs
-# Input: $1=Output directory name
-# $2=BUILDERR
-# $3=BUILDDIR
-get_melbuildinfo () {
- local __outputdir="${1}"
- local __builderr="${2}"
- local __builddir="${3}"
-
- local __arch="$(echo "${__builderr#/*/work/}" | cut -d"/" -f1)"
- local __pkgname="$(echo "${__builderr#/*/work/}" | cut -d"/" -f2)"
- local __pkgdir="${__builddir}"/tmp/work/"${__arch}"/"${__pkgname}"
-
- cp -a "${__builddir}"/buildhistory/images/ "${__outputdir}"/mel/.
- cp -a "${__builddir}"/tmp/log/ "${__outputdir}"/mel/.
- cp -a "${__builddir}"/conf/ "${__outputdir}"/mel/.
-
- mkdir "${__outputdir}"/mel/"${__arch}"
- cp -a "${__pkgdir}" "${__outputdir}"/mel/"${__arch}"/.
-}
-
-
-########################################################################################################
-#
-# Start execution of script
-#
-
-# Check if the build environment is set or not.
-if [ ! -d "${BUILDDIR}" ]; then
- echo "Please setup the build environment first, and run the script again."
- exit 1
-else
- # Check 1st cmdline argument
- if [[ "${1}" == -* ]]; then
- # Process script input arguments
- process_cmdline_args "${@}"
-
- if [ ! -d "${BUILDERR}" ]; then
- echo -en "\\nERROR: Input argument was invalid!!!\\n\\n"
- fi
- elif [ -z "${@}" ]; then
- echo -en "\\nWARNING: No input argument was given on command line.\\n\\n"
- fi
-
- # Check for valid BUILDERR
- while [ ! -d "${BUILDERR}" ]; do
- echo "Please enter package name in which you are having error (option -e):"
- read IN1
-
- BUILDERR=$(find "${BUILDDIR}/tmp/work/" -maxdepth 2 -type d -name "${IN1}")
-
- if [ ! -d "${BUILDERR}" ]; then
- echo -en "\\nERROR (option -e): Invalid package name!!!\\n\\n"
- fi
- done
-
- for i in $(echo "$PATH" | tr ":" "\\n")
- do
- a="$(echo "$i" | grep "/bitbake/bin")"
- if [ -n "$a" ]
- then
- break
- fi
- done
-
- MELDIR="${a%%/bitbake/bin}"
-
- # Clean up artifacts from previous run of the script
- if [ -d "${OUTPUTDIRNAME}" ]; then
- rm -rf "${OUTPUTDIRNAME}"
- fi
-
- if [ -a "${OUTPUTDIRNAME}".tar.bz2 ]; then
- rm "${OUTPUTDIRNAME}".tar.bz2
- fi
-
- # Create directories for saving script outputs
- mkdir -p "${OUTPUTDIRNAME}"/host "${OUTPUTDIRNAME}"/mel
-
- # Collect host information
- get_hostinfo "${OUTPUTDIRNAME}" "${HOSTINFOFILE}"
- get_hostlicenseinfo "${OUTPUTDIRNAME}" "${HOSTINFOFILE}" "${MGLS_LICENSE}"
- get_hostlicenseinfo "${OUTPUTDIRNAME}" "${HOSTINFOFILE}" "${LM_LICENSE}"
- get_hostprereqsinfo "${OUTPUTDIRNAME}" "${HOSTINFOFILE}"
- get_melinstallinfo "${OUTPUTDIRNAME}" "${HOSTINFOFILE}"
- get_melbuildinfo "${OUTPUTDIRNAME}" "${BUILDERR}" "${BUILDDIR}"
-
- # Create tarball with info collected in output directory
- echo "Creating \"${OUTPUTDIRNAME}\".tar.bz2..."
- tar cjpf "${OUTPUTDIRNAME}".tar.bz2 "${OUTPUTDIRNAME}" 2>> "${OUTPUTDIRNAME}"/host/"${HOSTINFOFILE}"
-
- # Need to check exit status of tar and handle appropriately
- if [[ ${?} -ne 0 ]]; then
- echo -en "\\ntar errno: ${?}\\n" >> "${OUTPUTDIRNAME}"/host/"${HOSTINFOFILE}"
- cp "${OUTPUTDIRNAME}"/host/"${HOSTINFOFILE}" .
- echo "An error occurred during tar."
- echo "Please attach "${HOSTINFOFILE}" to your Support Request ticket."
- exit 1
- else
- # Remove output directory after creating tarball archive file
- if [ -d "${OUTPUTDIRNAME}" ]; then
- rm -rf "${OUTPUTDIRNAME}"
- fi
- echo "Done!!!"
- echo -en "\\nPlease attach "${OUTPUTDIRNAME}".tar.bz2 to your Support Request ticket.\\n\\n"
- fi
-fi
diff --git a/scripts/list-recipes b/scripts/list-recipes
deleted file mode 100755
index 47eff2d7..00000000
--- a/scripts/list-recipes
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-list_layers() {
- find . -mindepth 3 -maxdepth 4 -wholename \*/conf/layer.conf |
- sed 's,^\./,,; s,/conf/layer\.conf$,,'
-}
-
-list_recipes() {
- find "$1" -iname \*.bb
-}
-
-list_layers | while read -r layer; do
- if ! grep -qFx "$layer/" "$1"; then
- echo "$layer/"
- list_recipes "$layer"
- fi
-done >>"$1"
diff --git a/scripts/multi-machine b/scripts/multi-machine
deleted file mode 100755
index 58397fd7..00000000
--- a/scripts/multi-machine
+++ /dev/null
@@ -1,111 +0,0 @@
-#!/bin/bash
-#
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0
-# ---------------------------------------------------------------------------------------------------------------------
-#
-# Copyright 2022 Siemens
-#
-# This file is licensed under the terms of the GNU General Public License
-# version 2. This program is licensed "as is" without any warranty of any
-# kind, whether express or implied.
-
-usage () {
- echo >&2 "$0 [OPTIONS...] MACHINE..."
- echo >&2
- echo >&2 "Options:"
- echo >&2 " -b BUILDDIR Specify the build directory. (default: build)"
- echo >&2 " -o BITBAKE_ARGUMENTS Specify bitbake args (default: core-image-base)"
- echo >&2 " -s SETUP_ENVIRONMENT Specify the setup-environment script to use"
- echo >&2 " -a SETUP_ENV_ARGS Add additional setup-environment args"
- echo >&2 " -k Continue when one build fails"
- echo >&2 " -c Clean the TMPDIR before each build"
- echo >&2 " -h Show this usage information"
- exit 1
-}
-
-bgrm () {
- # bgrm PATH [PATH...]
- #
- # Remove the specified paths in the background, after renaming them, so
- # you're free to recreate and use those paths while they're being removed.
-
- toremove=""
- for item in "$@"; do
- if basename "$item" | grep -q "^bgrm."; then
- continue
- fi
-
- tempdir=$(mktemp -d $(dirname $item)/bgrm.XXXXXX) || exit 1
- mkdir -p $tempdir
- toremove="$toremove $tempdir"
- mv "$item" "$tempdir/"
- done
- rm -rf $toremove &
-}
-
-builddir=build
-bitbakeopts=core-image-base
-setupscript=$(dirname $0)/../setup-environment
-setupscriptargs=
-continue=0
-clean=0
-while getopts b:o:s:a:ckh opt; do
- case "$opt" in
- b)
- builddir="$OPTARG"
- ;;
- o)
- bitbakeopts="$OPTARG"
- ;;
- s)
- setupscript="$OPTARG"
- ;;
- a)
- setupscriptargs="$OPTARG"
- ;;
- c)
- clean=1
- ;;
- k)
- continue=1
- ;;
- \?|h)
- usage
- ;;
- esac
-done
-shift $(expr $OPTIND - 1)
-unset OPTIND
-
-if [ $# -eq 0 ]; then
- usage
-fi
-
-bitbakeopts="-k $bitbakeopts"
-topdir=$PWD
-for machine; do
- eval . "$setupscript -f -b $builddir $setupscriptargs $machine"
- echo "Running bitbake $bitbakeopts for $machine.."
- eval bitbake $bitbakeopts
- ret=$?
- if [ $ret -ne 0 ]; then
- if [ $continue -eq 0 ]; then
- echo >&2 "Build for $machine failed with exit code $ret, aborting"
- exit $ret
- else
- echo >&2 "Warning: build for $machine failed with exit code $ret"
- fi
- fi
- cp -a "$TMPDIR/log/." "$builddir/log/"
- if [ $clean -eq 1 ]; then
- eval $(bitbake -e | grep '^TMPDIR=')
- if [ -z "$TMPDIR" ]; then
- echo >&2 "Error: failed to extract TMPDIR from bitbake -e"
- exit 2
- fi
- bgrm $TMPDIR
- fi
- cd $topdir
- sleep 1
-done
diff --git a/scripts/patchinfo b/scripts/patchinfo
deleted file mode 100755
index f1a73028..00000000
--- a/scripts/patchinfo
+++ /dev/null
@@ -1,146 +0,0 @@
-#!/usr/bin/env python3
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-import itertools
-import json
-import re
-import subprocess
-import sys
-import traceback
-from email.parser import Parser
-from email.policy import default
-from pathlib import Path
-
-import unidiff
-
-patchnum = re.compile(r'^[0-9]*-')
-prefix = re.compile(r'(\[.*\] *)*')
-fieldline = re.compile(r'^(?P<field>[a-zA-Z]+(-[a-zA-Z]+)*): (?P<value>.*)$')
-multifields = ['CVE', 'Signed-off-by']
-modified_file_prefixes = ['a', 'b']
-
-
-class PatchError(Exception):
- pass
-
-
-class PatchParseError(PatchError):
- def __init__(self, filename, message=None):
- super().__init__(message)
- self.filename = filename
-
- def __str__(self):
- message = f'Failed to parse {self.filename}'
- while self.__cause__:
- message = message + ": " + str(self.__cause__)
- self = self.__cause__
- return message
-
-
-def parse(patchfile):
- try:
- return unidiff.PatchSet(patchfile, metadata_only=True)
- except (UnicodeDecodeError, unidiff.errors.UnidiffParseError) as exc:
- raise PatchParseError(patchfile.name) from exc
-
-
-def addinfo(info, key, value):
- if key in multifields:
- if key in info:
- info[key].append(value)
- else:
- info[key] = [value]
- else:
- info[key] = value
-
-def patchinfo(patchfile):
- """Print patch information."""
-
- errors = []
- patchpath = Path(patchfile.name)
- patchinfo = {'Filename': patchpath.name}
- patched_files = []
- subject = patchnum.sub('', patchpath.stem, 1)
- subject = subject.replace(
- '-', ' ').replace('_', ' ')
- subject = subject[0].upper() + subject[1:]
-
- try:
- patch = parse(patchfile)
- except PatchError as exc:
- errors.append(traceback.TracebackException.from_exception(exc))
-
- try:
- diffstat_l = subprocess.check_output(['diffstat', '-l', patchpath])
- except subprocess.CalledProcessError:
- pass
- else:
- patched_files = diffstat_l.decode('utf-8').splitlines()
- else:
- if patch:
- patch_info = patch[0].patch_info
- if not patch_info[0].startswith('diff '):
- filtered = list(itertools.takewhile(lambda l: l.strip()
- != '---' and not l.startswith('diff '), patch_info))
- info = ''.join(filtered[1:])
- if info:
- headers = Parser(policy=default).parsestr(info)
- for key, value in headers.items():
- addinfo(patchinfo, key, value)
-
- if headers['subject']:
- subject = headers['subject']
-
- matches = [fieldline.match(l.rstrip()) for l in filtered[1:]]
- extrafields = dict((m.group('field'), m.group('value')) for m in matches if m)
- for key, value in extrafields.items():
- if key not in headers:
- addinfo(patchinfo, key, value)
-
- for patchedfile in patch:
- fn = Path(patchedfile.target_file)
- first = fn.parts[0]
- if first in modified_file_prefixes:
- fn = fn.relative_to(first)
-
- patched_files.append(str(fn))
-
- if subject:
- subject = prefix.sub('', subject, 1)
- addinfo(patchinfo, 'Summary', subject)
-
- if patched_files:
- addinfo(patchinfo, 'Files', sorted(patched_files))
-
- return patchinfo, errors
-
-
-def main(argv=sys.argv):
- import argparse
-
- parser = argparse.ArgumentParser(
- description='Print information about the specified patches')
- parser.add_argument('patchfiles', metavar='PATCHFILE', nargs='*',
- help='Patch filename')
-
- args = parser.parse_args()
-
- ret = 0
- for filename in args.patchfiles:
- with open(filename) as patchfile:
- info, errors = patchinfo(patchfile)
- if errors:
- for error in errors:
- sys.stderr.write(str(error) + '\n')
- ret = 1
-
- print(json.dumps(info, indent=4))
-
- return ret
-
-
-if __name__ == '__main__':
- sys.exit(main() or 0)
diff --git a/scripts/release/manifest-remove-existing b/scripts/release/manifest-remove-existing
deleted file mode 100755
index 93ac235c..00000000
--- a/scripts/release/manifest-remove-existing
+++ /dev/null
@@ -1,86 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-usage () {
- echo >&2 "Usage: ${0##*/} [-r EXISTING_MANIFEST_DIR] MANIFEST_DIR"
- echo >&2
- echo >&2 "Remove all entries from all manifests in MANIFEST_DIR which"
- echo >&2 "were included in any manifests in EXISTING_MANIFEST_DIR"
- echo >&2
- echo >&2 "This is specifically intended for use in creation of MEL product updates"
-}
-
-process_arguments () {
- existing_manifest_dir=
- manifest_dir=
-
- while getopts r:h opt; do
- case "$opt" in
- r)
- existing_manifest_dir=$OPTARG
- ;;
- h)
- usage
- exit 0
- ;;
- \?)
- usage
- exit 1
- ;;
- esac
- done
- shift $((OPTIND - 1))
- if [ $# -ne 1 ]; then
- usage
- exit 1
- fi
-
- if [ ! -d "$existing_manifest_dir" ]; then
- echo >&2 "Error: EXISTING_MANIFEST_DIR must be an existing directory"
- exit 1
- fi
-
- manifest_dir="$1"
- if [ ! -d "$manifest_dir" ]; then
- echo >&2 "Error: MANIFEST_DIR must be an existing directory"
- exit 1
- fi
-
- if [ "$(echo "$existing_manifest_dir/"*)" = "$existing_manifest_dir/*" ]; then
- echo >&2 "Error: no manifests in EXISTING_MANIFEST_DIR"
- exit 1
- fi
-
- if [ "$(echo "$manifest_dir/"*)" = "$manifest_dir/*" ]; then
- echo >&2 "Error: no manifests in MANIFEST_DIR"
- exit 1
- fi
-}
-
-process_arguments "$@"
-tempdir="$(mktemp -d -t "${0##*/}.XXXXXX")" || exit 1
-trap 'rm -rf "$tempdir"' EXIT INT TERM
-
-for extension in manifest downloads; do
- cat "$existing_manifest_dir/"*.$extension 2>/dev/null | sort -u >"$tempdir/existing.$extension"
- for manifest in "$manifest_dir/"*.$extension; do
- if [ ! -e "$manifest" ]; then
- continue
- fi
- manifestname="$(basename "$manifest")"
- sort -u "$manifest" >"$tempdir/$manifestname.sorted"
- comm -13 "$tempdir/existing.$extension" "$tempdir/$manifestname.sorted" >"$tempdir/$manifestname"
- diff -u "$manifest" "$tempdir/$manifestname" >"$tempdir/$manifestname.diff"
- if [ -s "$tempdir/$manifestname.diff" ]; then
- echo >&2 "Lines were removed from $manifest"
- mv "$tempdir/$manifestname" "$manifest"
- if ! [ -s "$manifest" ]; then
- echo >&2 "Manifest $manifest was empty, removed"
- rm -f "$manifest"
- fi
- fi
- done
-done
diff --git a/scripts/release/mel-checkout b/scripts/release/mel-checkout
deleted file mode 100755
index 7f7e807a..00000000
--- a/scripts/release/mel-checkout
+++ /dev/null
@@ -1,334 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-set -eu
-
-usage () {
- cat >&2 <<END
-usage: ${0##*/} [options] BUILD_DIR [MANIFEST_FILE [EXTRA_MANIFEST_FILES..]]
-
-Create the BUILD_DIR, populate it with bitbake, layers, etc, from this MEL
-installation, and configure it via the usual setup-environment script from
-meta-mentor.
-
-If no manifest file is specified, and -n is not specified, a prompt will be
-shown to interactively select one of the manifests in the same mel
-installation as this script. If no extra manifest files are specified, and
-neither -n nor -X are specified, a prompt will be shown for each type.
-
-Options:
- -n Non-interactive mode. Do not prompt
- -X Disable inclusion of extra manifests
-END
- exit 1
-}
-
-evalf () {
- fmt="$1"
- shift
- # printf >&2 "evalf: $fmt\n" "$@"
- # eval echo >&2 "evalf: $(printf "$fmt" "$@")"
- eval "$(printf "$fmt" "$@")"
-}
-
-verify_machine () {
- workspace="$1"
- manifest_name=$(basename "$2")
- manifest_machine=$(echo "$manifest_name" | cut -d'-' -f3- | cut -d'.' -f1)
- workspace_machine=$(cat "$workspace/.machine")
- if [ "$workspace_machine" != "$manifest_machine" ]; then
- echo >&2 "Error: workspace in $workspace is already setup for $workspace_machine."
- echo >&2 "Please specify a different location if you want to setup for $manifest_machine"
- echo >&2 "or clean up $workspace before continuing."
- exit 1
- fi
-}
-
-set_machine () {
- workspace="$1"
- manifest_name=$(basename "$2")
- manifest_machine=$(echo "$manifest_name" | cut -d'-' -f3- | cut -d'.' -f1)
- echo "$manifest_machine" > "$workspace/.machine"
-}
-
-prompt_choice () {
- if [ "$1" = "-n" ]; then
- choice_non_interactive=1
- shift
- else
- choice_non_interactive=0
- fi
-
- prompt_message="$1"
- prompt_default="${2:-}"
-
- prompt_options="$(mktemp prompt-choice.XXXXXX)"
- cat >>"$prompt_options"
-
- prompt_count="$(wc -l <"$prompt_options")"
- case $prompt_count in
- 0)
- # No choices provided
- rm -f "$prompt_options"
- return 1
- ;;
- 1)
- # Only one choice
- cat "$prompt_options"
- rm -f "$prompt_options"
- return 0
- ;;
- esac
-
- if [ $choice_non_interactive -eq 1 ]; then
- printf >&2 'Error: unable to prompt for `%s` interactively\n' "$prompt_message"
- return 1
- fi
-
- if [ -n "$prompt_default" ] && \
- ! echo "$prompt_default" | grep -q '^[0-9]*'; then
- printf >&2 'Error: prompt_default value '%s' is invalid, default must be a selection number.\n' "$prompt_default"
- prompt_default=
- fi
-
- while [ -z "$prompt_value" ]; do
- prompt_num=0
- while read choice; do
- prompt_num=$((prompt_num + 1))
- evalf 'prompt_value_%s="%s"' "$prompt_num" "$choice"
- printf >&2 "%s) %s\n" "$prompt_num" "$choice"
- done <"$prompt_options"
-
- if [ -n "$prompt_default" ]; then
- printf >&2 "%s [%s]: " "$prompt_message" "$prompt_default"
- else
- printf >&2 "%s: " "$prompt_message"
- fi
- read selection </dev/tty
- if [ -n "$prompt_default" ] && [ -z "$selection" ]; then
- selection="$prompt_default"
- fi
- prompt_value="$(evalf 'echo "${prompt_value_%s}"' "$selection")"
- done
- printf "%s\n" "$prompt_value"
- rm -f "$prompt_options"
-}
-
-remove_old_versions () {
- while IFS=- read -r product version machine; do
- printf '%s\t%s\t%s\n' "$product" "$version" "$machine"
- done \
- | uniq -f2 \
- | tr "$(printf '\t')" -
-}
-
-sort_manifests () {
- "$scriptdir/version-sort" \
- | tac \
- | sort -s -t- -k3 \
- | if [ $all_versions -eq 0 ]; then remove_old_versions; else cat; fi \
- | sed '/qemu/!s/^/1 /; /qemu/s/^/0 /;' | sort -srn | sed 's/^[01] //'
-}
-
-prompt_manifest () {
- find "$1" -maxdepth 1 -type f -name \*.manifest | \
- sed 's,^.*/,,' | sort_manifests | \
- ( set +u; prompt_choice $prompt_non_interactive "$2" 1; ) | sed "s,^,$1/,"
-}
-
-process_arguments () {
- no_extra_manifests=0
- non_interactive=0
- all_versions=0
- while getopts Xnah opt; do
- case "$opt" in
- X)
- no_extra_manifests=1
- ;;
- n)
- non_interactive=1
- ;;
- a)
- all_versions=1
- ;;
- \?|h)
- usage
- return 1
- ;;
- esac
- done
-
- if ! [ -t 1 ] || ! [ -t 0 ]; then
- non_interactive=1
- fi
-
- if [ $non_interactive -eq 1 ]; then
- prompt_non_interactive=-n
- else
- prompt_non_interactive=
- fi
-}
-
-process_arguments "$@" || exit $?
-shift $((OPTIND - 1))
-
-if [ $# -eq 0 ]; then
- usage
-fi
-
-scriptdir="$(cd "$(dirname "$0")" && pwd -P)"
-installdir="$(dirname "$scriptdir")"
-
-project="$1"
-shift
-
-mkdir -p "$project"
-cd "$project"
-echo "$installdir" >"$project/.installpath"
-
-for install_subdir in ../../toolchains ../../tools; do
- if [ -d "$installdir/$install_subdir" ]; then
- ln -sf "$installdir/$install_subdir" .
- fi
-done
-
-manifest="$1"
-if [ -z "$1" ]; then
- if ! [ -e "$project/.manifest" ]; then
- prompt_manifest "$installdir/manifests" "Select manifest" >"$project/.manifest"
- if ! [ -s "$project/.manifest" ]; then
- echo >&2 "Error: no manifest found, please specify"
- rm -f "$project/.manifest"
- exit 1
- fi
- fi
- if [ -e "$project/.machine" ]; then
- verify_machine "$project" "$(cat "$project/.manifest" | head -n1)"
- fi
- set -- $(cat "$project/.manifest")
- manifest="$1"
-else
- if [ -e "$project/.machine" ]; then
- verify_machine "$project" "$manifest"
- fi
- echo "$manifest" >"$project/.manifest"
-fi
-set_machine "$project" "$manifest"
-
-if [ $no_extra_manifests -eq 1 ]; then
- set -- "$1"
-elif [ $# -lt 2 ]; then
- extra_base="$installdir/manifests/extra"
- for extra_dir in "$extra_base"/*/; do
- if [ -d "$extra_dir" ]; then
- extra_dir="${extra_dir%/}"
- name="${extra_dir#$extra_base/}"
- extra_manifest="$(prompt_manifest "$extra_dir" "Select manifest for $name")"
- if [ -z "$extra_manifest" ]; then
- echo >&2 "Error: no extra manifest for $name?"
- exit 1
- else
- set -- "$@" "$extra_manifest"
- echo "$extra_manifest" >>"$project/.manifest"
- fi
- fi
- done
-fi
-
-infofn="${manifest%.manifest}.info"
-if [ -e "$infofn" ]; then
- bspfiles_path="$(sed -n -e 's/^bspfiles_path = //p' "$infofn")"
- if [ -n "$bspfiles_path" ] && [ -e "$installdir/$bspfiles_path" ]; then
- rm -f "${bspfiles_path%/*}"
- ln -s "$installdir/$bspfiles_path" "${bspfiles_path%/*}"
- for i in xlayers.conf customer.conf; do
- if [ -e "$installdir/$bspfiles_path/$i" ]; then
- ln -s "$installdir/$bspfiles_path/$i" .
- fi
- done
- fi
-fi
-
-mkdir -p downloads
-
-for manifest; do
- printf '%s\t%s\n' "${manifest##*/}" "$manifest"
-done | (
- read -r base_manifest
- printf '%s\n' "$base_manifest"
- "$scriptdir/version-sort"
-) | cut -d"$(printf '\t')" -f2 | \
- while read -r manifest; do
- cat "$manifest" | while read -r checkout_path commit remotes; do
- if [ ! -d "$checkout_path/.git" ]; then
- git init "$checkout_path"
- fi
-
- cd "$checkout_path"
- if [ -d "$installdir/objects" ]; then
- echo "$installdir/objects" >.git/objects/info/alternates
- fi
- if [ -e "$installdir/git-bundles/$commit.bundle" ]; then
- git bundle unbundle "$installdir/git-bundles/$commit.bundle" >/dev/null
- fi
-
- echo "$remotes" | tr '\t' '\n' | while IFS== read -r name url; do
- if [ -n "$name" ]; then
- if git remote | grep -qxF "$name"; then
- git remote set-url "$name" "$url"
- else
- git remote add "$name" "$url"
- fi
- fi
- done
-
- if [ -z "$remotes" ]; then
- echo "$commit" >.git/shallow
- fi
- # Create branches for all manifests, for reference
- manifestdir="$(dirname "$manifest")"
- for otherfn in "$manifestdir/"*.manifest; do
- while read -r other_checkout_path other_commit _; do
- if [ "$other_checkout_path" = "$checkout_path" ]; then
- branch="$(basename "${otherfn%.manifest}")"
- if ! git rev-parse -q --verify "refs/heads/$branch" >/dev/null; then
- if [ -e "$installdir/git-bundles/$other_commit.bundle" ]; then
- git bundle unbundle "$installdir/git-bundles/$other_commit.bundle" >/dev/null
- fi
- git update-ref "refs/heads/$branch" "$other_commit"
- fi
- if [ -z "$remotes" ]; then
- echo "$other_commit" >>.git/shallow
- fi
- fi
- done <"$otherfn"
- done
-
- branch="$(basename "${manifest%.manifest}")"
- if ! git rev-parse -q --verify "refs/heads/$branch" >/dev/null; then
- git update-ref "refs/heads/$branch" "$commit"
- fi
- if [ "$(git rev-parse -q --verify --symbolic-full-name HEAD 2>/dev/null)" != "refs/heads/$branch" ]; then
- git checkout "$branch"
- fi
-
- cd - >/dev/null
- done
-
- downloads="${manifest%.manifest}.downloads"
- if [ -e "$downloads" ]; then
- cat "$downloads" | while read -r path checksum; do
- destdir="$(dirname "$path")"
- if [ "$destdir" != "." ]; then
- mkdir -p "downloads/$destdir"
- ln -sf "$path" downloads/
- ln -sf "${path}.done" downloads/
- fi
- ln -sf "$installdir/downloads/$checksum" "downloads/$path"
- touch "downloads/${path}.done"
- done
- fi
- done
diff --git a/scripts/release/setup-mel b/scripts/release/setup-mel
deleted file mode 100644
index 0fd8f812..00000000
--- a/scripts/release/setup-mel
+++ /dev/null
@@ -1,35 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-if [ -z "$ZSH_NAME" ] && [ "x$0" = "x./setup-mel" ]; then
- echo >&2 "Error: This script needs to be sourced. Please run as '. $0'"
-else
- if [ -n "$BASH_SOURCE" ]; then
- meldir="`dirname "$BASH_SOURCE"`"
- elif [ -n "$ZSH_NAME" ]; then
- meldir="`dirname "$0"`"
- else
- meldir="`pwd`"
- fi
- meldir=`readlink -f "$meldir"`
-
- WORKSPACEDIR="$PWD/workspace"
- for i in $(seq $#); do
- mel_arg="$(eval printf "%s" "\$$i")"
- case "$mel_arg" in
- -w)
- WORKSPACEDIR="$(eval printf "%s" "\$$(expr $i + 1)")"
- if [ -z "$WORKSPACEDIR" ]; then
- echo >&2 "-w requires an argument"
- fi
- ;;
- esac
- done
- unset mel_arg
- "$meldir/scripts/setup-workspace" "$@" && \
- cd "$WORKSPACEDIR" && \
- echo >&2 "MEL setup complete in $WORKSPACEDIR" && \
- echo >&2 "You can now source "$WORKSPACEDIR"/meta-mentor/setup-environment for setting up a build."
-fi
-# vim: set ft=sh :
diff --git a/scripts/release/setup-workspace b/scripts/release/setup-workspace
deleted file mode 100755
index 09da9dc1..00000000
--- a/scripts/release/setup-workspace
+++ /dev/null
@@ -1,115 +0,0 @@
-#!/bin/bash
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-usage () {
- echo >&2 "Usage: ${0##*/} [options]"
- echo >&2
- echo >&2 "Options:"
- echo >&2 " -w WORKSPACEDIR Specify the workspace directory to create (default: 'workspace'))"
- echo >&2 " -m MANIFEST Specify a manifest, rather than interactive selection"
- echo >&2 " -x EXTRA_MANIFEST Specify an extra manifest. To specify"
- echo >&2 " multiple, use multiple -x arguments."
- echo >&2 " -X Explicitly disable extra manifests"
- echo >&2 " -h Show this usage information"
- echo >&2
-}
-
-abspath () {
- _path="$1"
- if [ -n "${_path##/*}" ]; then
- _path="${2:-$PWD}/$1"
- fi
- echo "$_path"
-}
-
-if [ "$1" = "--help" ]; then
- usage
- exit 1
-fi
-
-WORKSPACEDIR=$PWD/workspace
-manifest=
-extra_disabled=
-extra_manifests=
-all_versions=
-while getopts w:m:x:Xah opt; do
- case "$opt" in
- w)
- WORKSPACEDIR="$OPTARG"
- if [ -z "$WORKSPACEDIR" ]; then
- echo >&2 "-w requires an argument"
- exit 1
- else
- WORKSPACEDIR="$(abspath "$WORKSPACEDIR")"
- fi
- ;;
- m)
- manifest="$OPTARG"
- if [ -z "$manifest" ]; then
- echo >&2 "-m requires an argument"
- exit 1
- else
- if [ ! -e "$manifest" ]; then
- echo >&2 "Error: manifest path $manifest does not exist"
- exit 1
- else
- manifest="$(abspath "$manifest")"
- fi
- fi
- ;;
- X)
- if [ -n "$extra_manifest" ]; then
- echo >&2 "Error: -x and -X are mutually exclusive"
- exit 1
- fi
- extra_disabled=1
- ;;
- x)
- if [ -n "$extra_disabled" ]; then
- echo >&2 "Error: -x and -X are mutually exclusive"
- exit 1
- fi
-
- extra_manifest="$OPTARG"
- if [ -z "$extra_manifest" ]; then
- echo >&2 "-x requires an argument"
- exit 1
- else
- if [ ! -e "$extra_manifest" ]; then
- echo >&2 "Error: extra_manifest path $extra_manifest does not exist"
- exit 1
- else
- extra_manifests="$extra_manifests $(abspath "$extra_manifest")"
- fi
- fi
- ;;
- a)
- all_versions=1
- ;;
- \? | h)
- usage
- exit 1
- ;;
- esac
-done
-shift $((OPTIND - 1))
-
-if [ -e "$WORKSPACEDIR" ]; then
- existing_workspace=1
-else
- existing_workspace=0
-fi
-
-scriptdir="$(dirname "$0")"
-"$scriptdir/mel-checkout" ${all_versions:+-a} ${extra_disabled:+-X} "$WORKSPACEDIR" "$manifest" $extra_manifests \
- && cd "$WORKSPACEDIR"
-if [ $? -ne 0 ]; then
- if [ $existing_workspace -eq 0 ]; then
- # New workspace, clean up on failure
- rm -r "$WORKSPACEDIR"
- fi
- exit 1
-fi
diff --git a/scripts/release/version-sort b/scripts/release/version-sort
deleted file mode 100755
index 13c89da5..00000000
--- a/scripts/release/version-sort
+++ /dev/null
@@ -1,12 +0,0 @@
-#!/usr/bin/env python3
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-import sys
-from distutils.version import LooseVersion as Version
-
-lines = sys.stdin.readlines()
-sorted_lines = sorted(lines, key=lambda l: Version(l))
-sys.stdout.write(''.join(sorted_lines))
diff --git a/scripts/setup-debian b/scripts/setup-debian
deleted file mode 100755
index 196eacb8..00000000
--- a/scripts/setup-debian
+++ /dev/null
@@ -1,54 +0,0 @@
-#!/bin/sh
-
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-set -u
-
-if [ $(id -u) -ne 0 ]; then
- echo >&2 "Verifying access to sudo, please enter your password if prompted."
- sudo -v
- if [ $? -ne 0 ]; then
- echo >&2 "Could not use sudo, exiting"
- exit 1
- fi
- exec sudo "$0" "$@"
-fi
-
-set -- \
- binutils \
- bzip2 \
- ca-certificates \
- chrpath \
- cpio \
- cpp \
- diffstat \
- file \
- g++ \
- gawk \
- gcc \
- git \
- libc-dev-bin \
- locales \
- make \
- patch \
- python3 \
- python3-distutils \
- rsync \
- wget \
- ssh
-
-# This is helpful to write images, and is in our documentation
-set -- "$@" bmap-tools
-
-echo >&2 "Installing packages.."
-apt-get update \
- && DEBIAN_FRONTEND=noninteractive \
- apt-get install -y -f --no-install-recommends "$@"
-
-echo >&2 "Generating the en_US.UTF-8 locale"
-sed -i -e 's/# en_US.UTF-8 UTF-8/en_US.UTF-8 UTF-8/' /etc/locale.gen && \
- locale-gen
-
-echo >&2 "Setup complete"
diff --git a/scripts/setup-mel-builddir b/scripts/setup-mel-builddir
deleted file mode 100755
index 5c394533..00000000
--- a/scripts/setup-mel-builddir
+++ /dev/null
@@ -1,388 +0,0 @@
-#!/bin/sh
-#
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0
-# ---------------------------------------------------------------------------------------------------------------------
-#
-# Copyright 2022 Siemens
-#
-# This file is licensed under the terms of the GNU General Public License
-# version 2. This program is licensed "as is" without any warranty of any
-# kind, whether express or implied.
-
-DISTRO="${DISTRO:-mel}"
-CORELAYERS="${CORELAYERS:-}"
-OPTIONALLAYERS="${OPTIONALLAYERS-}"
-EXTRAMELLAYERS="${EXTRAMELLAYERS-}"
-layer_priority_overrides="openembedded-layer=1"
-
-
-usage () {
- cat >&2 <<END
-Usage: $0 [OPTIONS...] [MACHINE]
-
-When operating from a MEL install, this script will use the template config
-files from the installed BSP. If multiple BSPs are installed, you must specify
-MACHINE, and the script will use the templates from that BSP.
-
-When no installed BSP is available, MACHINE is required, and this script will
-set up the build directory with a base set of layers + all layers which
-include the machine .conf file for this machine, sorted by layer recipe
-priority.
-
-If the build directory already exists and is configured, you can leave MACHINE
-unspecified, and the script will set you up for that build directory without
-changing its configuration.
-
-All layers whose directory name is update-* or meta-mentor-cve, at toplevel or
-a subdir, of the parent of meta-mentor, will be automatically included, as
-a mechanism for delivering sets of updates for releases.
-
-Options:
-
- -b BUILDDIR Specify the build directory to create (default: 'build')
- -o MELDIR Specify the root of the MEL install, where you can find bitbake
- and the layers
- -p PATHS Specify colon separated list of paths, where you can find layers
- in addition to the root of the MEL install (default: empty).
- If any path in this list contains wildcards, the list must be quoted
- to avoid wildcard substitution by the shell
- -l LAYERS Space-separated list of layer names for additional layers you
- want to be included in the configuration. This argument is
- cumulative. Both '-l "meta-foo meta-bar"' and
- '-l meta-foo -l meta-bar' are valid and include both layers.
- -f Force overwrite of existing configuration files in the build
- directory. This includes local.conf and bblayers.conf, but not
- site.conf
- -h Show this usage information
-
-END
-}
-
-prompt_choice () {
- non_interactive=0
- while getopts n opt; do
- case "$opt" in
- n)
- non_interactive=1
- ;;
- esac
- done
- shift $(expr $OPTIND - 1)
-
- prompt_message="$1"
- prompt_default="${2:-}"
-
- prompt_options="$tmpdir/prompt-choice"
- cat >"$prompt_options"
-
- prompt_count="$(wc -l <"$prompt_options")"
- case $prompt_count in
- 0)
- # No choices provided
- return 1
- ;;
- 1)
- # Only one choice
- cat "$prompt_options"
- return 0
- ;;
- esac
-
- if [ $non_interactive -eq 1 ]; then
- printf >&2 'Error: unable to prompt for `%s` interactively\n' "$prompt_message"
- return 1
- fi
-
- while [ -z "$prompt_value" ]; do
- prompt_num=0
- while read choice; do
- prompt_num=$(expr $prompt_num + 1)
- eval prompt_value_${prompt_num}="$choice"
- printf >&2 "%s) %s\n" "$prompt_num" "$choice"
- done <"$prompt_options"
- printf >&2 "%s: " "$prompt_message"
- read selection </dev/tty
- prompt_value="$(eval echo \${prompt_value_$selection})"
- done
- printf "%s\n" "$prompt_value"
-}
-
-abspath () {
- readlink -f "$1"
-}
-
-configure_builddir () {
- if [ -n "$EXCLUDEDLAYERS" ]; then
- set -- "$@" -x "$EXCLUDEDLAYERS"
- fi
- if [ "$verbose" -eq 1 ]; then
- set -- "$@" -v
- fi
-
-
- sed -i -e"s/^#*MACHINE *?*=.*/MACHINE ??= \"$MACHINE\"/" $BUILDDIR/conf/local.conf
- sed -n -i -e "s|##COREBASE##|$OEROOT|g" -e '/^BBLAYERS /{ :start; /\\$/{n; b start}; d; }; p' -e "/BBFILE_PRIORITY/d" $BUILDDIR/conf/bblayers.conf
-
- echo 'BBLAYERS ?= "\' >> $BUILDDIR/conf/bblayers.conf
- layersfile="$tmpdir/layers"
-
- # Convert layer paths to layer names for bb-determine-layers
- extralayernames=
- for layer in $extralayers; do
- if [ -d "$layer" ]; then
- layerpaths="$layerpaths:$layer"
- layer="$(PATH="$OEROOT/scripts:$OEROOT/bitbake/bin:$PATH" $(dirname "$0")/bb-print-layer-data 2>/dev/null "$layer" | cut -d: -f1)"
- fi
- extralayernames="$extralayernames $layer"
- done
-
- updatelayernames=
- for layer in $updatelayers; do
- if [ -d "$layer" ]; then
- layer="$(PATH="$OEROOT/scripts:$OEROOT/bitbake/bin:$PATH" $(dirname "$0")/bb-print-layer-data 2>/dev/null "$layer" | cut -d: -f1)"
- layerpaths="$layerpaths:$layer"
- fi
- updatelayernames="$updatelayernames $layer"
- done
-
- $layerdir/scripts/bb-determine-layers -g "$layerpaths" -l "$CORELAYERS $extralayernames" -o "$EXTRAMELLAYERS $OPTIONALLAYERS" -e "$updatelayernames" -O "$layer_priority_overrides" -m "$MACHINE" -d "$DISTRO" "$@" >$layersfile
- if [ $? -ne 0 ]; then
- echo >&2 "Error in execution of bb-determine-layers, aborting"
- return 1
- fi
- sed -e "s#^$BUILDDIR/#\${TOPDIR}/#g;" -e 's,^, ,; s,$, \\,' <$layersfile >>$BUILDDIR/conf/bblayers.conf
- echo '"' >> $BUILDDIR/conf/bblayers.conf
- configured_layers="$(PATH="$OEROOT/scripts:$BITBAKEDIR/bin:$PATH" $(dirname "$0")/bb-print-layer-data $(cat $layersfile) 2>/dev/null | cut -d: -f1 | xargs)"
-
- echo "$layer_priority_overrides" | tr " " "\n" | \
- while IFS== read -r layer priority; do
- case " $configured_layers " in
- *\ $layer\ *)
- printf 'BBFILE_PRIORITY_%s_%s = "%d"\n' "$layer" "$DISTRO" "$priority" >> $BUILDDIR/conf/bblayers.conf
- ;;
- esac
- done
-}
-
-process_arguments () {
- BUILDDIR=
- MELDIR=
- OEROOT=
- extrasearchpaths=
- extralayers=
- force_overwrite=0
- verbose=0
- while getopts b:o:p:l:fvh opt; do
- case "$opt" in
- b)
- BUILDDIR="$(abspath $OPTARG)"
- ;;
- o)
- MELDIR="$(abspath $OPTARG)"
- ;;
- p)
- extrasearchpaths="$OPTARG"
- ;;
- l)
- extralayers="$extralayers $OPTARG"
- ;;
- f)
- force_overwrite=1
- ;;
- v)
- verbose=1
- ;;
- \?|h)
- usage
- return 1
- ;;
- esac
- done
-
- if [ -z $BUILDDIR ]; then
- if [ -f conf/local.conf -o -f conf/bblayers.conf ]; then
- # Assuming we're already in the build dir
- BUILDDIR=$PWD
- else
- BUILDDIR=$PWD/build
- fi
- fi
-
- if [ -z "$MELDIR" ]; then
- MELDIR=$(dirname $layerdir)
- fi
-
- updatelayers=
- for lconf in $MELDIR/update-*/conf/layer.conf \
- $MELDIR/*/update-*/conf/layer.conf \
- $MELDIR/meta-mentor-cve/conf/layer.conf; do
- updatelayer="${lconf%/conf/layer.conf}"
- if [ -e "$updatelayer" ]; then
- updatelayers="$updatelayers $updatelayer"
- fi
- done
-
- layerpaths="*:*/*:meta*/*/*:$MELDIR/*:$MELDIR/*/*:$MELDIR/meta*/*/*${extrasearchpaths:+:}$extrasearchpaths"
-}
-
-setup_builddir () {
- process_arguments "$@" || return $?
- shift $(expr $OPTIND - 1)
-
- OEROOT="$($layerdir/scripts/bb-determine-layers -g "$layerpaths" -l core 2>/dev/null)/.." || {
- echo >&2 "Error: unable to locate core layer (oe-core) in $MELDIR, aborting"
- return 3
- }
-
- if [ $# -gt 0 ]; then
- MACHINE="$1"
- fi
-
- if [ -z "$MACHINE" ]; then
- if [ -e "$MELDIR/.machine" ]; then
- MACHINE="$(cat "$MELDIR/.machine")"
- elif [ -e "$BUILDDIR/conf/local.conf" ]; then
- MACHINE=$(sed -n 's/^MACHINE ?*= "\([^"]*\)"/\1/p' $BUILDDIR/conf/local.conf)
- fi
- fi
-
- if [ -n "$MACHINE" ]; then
- if [ -e $MELDIR/$MACHINE/binary ]; then
- # User specified machine and we have the binary content for this BSP
- TEMPLATECONF=$MELDIR/$MACHINE/conf
- fi
- else
- if [ ! -e $BUILDDIR/conf/local.conf -o ! -e $BUILDDIR/conf/bblayers.conf ] || [ -z "$MACHINE" ]; then
- if ! [ -t 1 ] || ! [ -t 0 ]; then
- non_interactive=-n
- else
- non_interactive=
- fi
- ls -1d $MELDIR/*/binary 2>/dev/null | sed "s,^$MELDIR/,,; s,/binary$,," | \
- while read machine; do
- if [ ! -e "$MELDIR/$machine/conf/local.conf.sample" ]; then
- continue
- fi
- echo "$machine"
- done | prompt_choice $non_interactive "Select BSP to use" >$tmpdir/machine || {
- echo >&2 "Error: unable to prompt for an installed MEL BSP, please specify MACHINE"
- return 1
- }
- MACHINE="$(cat "$tmpdir/machine")"
- if [ -z "$MACHINE" ]; then
- echo >&2 "Error: unable to locate installed MEL BSP, please specify MACHINE"
- return 1
- else
- TEMPLATECONF=$MELDIR/$MACHINE/conf
- fi
- fi
- fi
-
- # Pick up qemu layers from meta-mentor-bsp as we do
- # not create separate machines for them
- case ${MACHINE} in
- qemu*)
- OPTIONALLAYERS="$OPTIONALLAYERS mentor-bsp-$MACHINE"
- ;;
- esac
-
-
- if [ $force_overwrite -eq 1 ]; then
- rm -f $BUILDDIR/conf/local.conf $BUILDDIR/conf/bblayers.conf
- fi
-
- if [ -d "$BUILDDIR" ]; then
- existing_builddir=1
- else
- existing_builddir=0
- fi
-
- mkdir -p $BUILDDIR/conf
-
- if [ -z "$TEMPLATECONF" ]; then
- if [ -f "$BUILDDIR/conf/templateconf.cfg" ]; then
- TEMPLATECONF="$(cat "$BUILDDIR/conf/templateconf.cfg")"
- elif [ -e "$layerdir/conf/local.conf.sample" ]; then
- TEMPLATECONF="$layerdir/conf"
- elif [ -e "$OEROOT/.templateconf" ]; then
- . "$OEROOT/.templateconf"
- # Convert to absolute path
- TEMPLATECONF="$(cd "$(dirname "$TEMPLATECONF")" && pwd -P)/$(basename "$TEMPLATECONF")"
- else
- echo >&2 "Unable to determine TEMPLATECONF"
- return 1
- fi
- fi
-
- if [ ! -f "$BUILDDIR/conf/templateconf.cfg" ]; then
- echo "$TEMPLATECONF" >"$BUILDDIR/conf/templateconf.cfg"
- fi
-
- if [ ! -e $BUILDDIR/conf/local.conf ]; then
- cp $TEMPLATECONF/local.conf.sample $BUILDDIR/conf/local.conf
- echo "You had no local.conf file. This configuration file has therefore been"
- echo "created for you with some default values."
-
- if [ -h "$MELDIR/toolchains" ]; then
- toolchains_path="$MELDIR/toolchains"
- sedexpr='${MELDIR}/toolchains'
- else
- toolchains_path="$MELDIR/../../toolchains"
- sedexpr='${MELDIR}/../../toolchains'
- fi
- if [ -d "$toolchains_path" ]; then
- sed -i -e "s,^#\?EXTERNAL_TOOLCHAIN.*,TOOLCHAINS_PATH ?= \"$toolchains_path\"," "$BUILDDIR/conf/local.conf"
- fi
- else
- if [ -n "$MACHINE" ]; then
- echo "Configuring existing local.conf for $MACHINE"
- fi
- fi
-
- if [ ! -e $BUILDDIR/conf/bblayers.conf ]; then
- echo "MELDIR = \"$MELDIR\"" >$BUILDDIR/conf/bblayers.conf
- echo >>$BUILDDIR/conf/bblayers.conf
- cat $TEMPLATECONF/bblayers.conf.sample >>$BUILDDIR/conf/bblayers.conf
- echo "You had no bblayers.conf file. This configuration file has therefore been"
- echo "created for you with some default values."
- else
- if [ -n "$MACHINE" ]; then
- echo "Configuring existing bblayers.conf for $MACHINE"
- fi
- fi
-
- if [ -d "$MELDIR/bitbake" ]; then
- BITBAKEDIR="$MELDIR/bitbake"
- else
- BITBAKEDIR="$OEROOT/bitbake"
- fi
-
- if [ -e "$layerdir/pre-setup.$MACHINE" ]; then
- . "$layerdir/pre-setup.$MACHINE"
- fi
- PATH="$OEROOT/scripts:$BITBAKEDIR/bin:$PATH" configure_builddir || return $?
-
- cat "$scriptsdir/build-setup-environment.in" \
- | sed -e "s#@OEROOT@#$OEROOT#g" \
- -e "s#@BITBAKEDIR@#$BITBAKEDIR#g" \
- -e "s#@TEMPLATECONF@#$TEMPLATECONF#g" >"$BUILDDIR/setup-environment"
-}
-
-scriptsdir="$(cd $(dirname $0) && pwd)"
-scriptsdir="$(abspath $scriptsdir)"
-layerdir="${scriptsdir%/*}"
-
-tmpdir="$(mktemp -d -t "${0##*/}.XXXXX")" || exit 1
-trap 'rm -rf "$tmpdir"' EXIT INT TERM
-
-setup_builddir "$@" || {
- if [ "$existing_builddir" = 0 ]; then
- rm -rf "$BUILDDIR"
- fi
- exit $?
-}
-if [ -e $BUILDDIR/conf/local.conf ]; then
- sed -i -e "s/^DISTRO.*/DISTRO = \'$DISTRO\'/" $BUILDDIR/conf/local.conf
-fi
-
diff --git a/scripts/setup-rh b/scripts/setup-rh
deleted file mode 100755
index 7a5d28bf..00000000
--- a/scripts/setup-rh
+++ /dev/null
@@ -1,42 +0,0 @@
-#!/bin/sh
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0
-# ---------------------------------------------------------------------------------------------------------------------
-#
-# Copyright 2022 Siemens
-#
-# This file is licensed under the terms of the GNU General Public License
-# version 2. This program is licensed "as is" without any warranty of any
-# kind, whether express or implied.
-
-packages="python38 \
- patch diffstat git bzip2 tar \
- gzip gawk chrpath wget cpio perl file which \
- make gcc gcc-c++ rsync rpcgen \
- zstd lz4"
-
-set -e
-
-if [ "$(id -u)" != "0" ]; then
- echo "Verifying access to sudo, please enter your password if prompted."
- if ! sudo -v; then
- echo >&2 "Could not use sudo, exiting"
- exit 1
- fi
- exec sudo "$0" "$@"
-fi
-
-echo "Enabling any required repos"
-if grep -q "^Red Hat Enterprise Linux release 8" /etc/redhat-release 2>/dev/null; then
- ARCH=$(/bin/arch)
- subscription-manager repos --enable "codeready-builder-for-rhel-8-${ARCH}-rpms"
-elif grep -q "^CentOS" /etc/redhat-release 2>/dev/null; then
- dnf config-manager --set-enabled PowerTools
-fi
-
-echo "Installing packages required to build Mentor Embedded Linux Flex OS"
-dnf install --assumeyes "$@" $packages || {
- echo >&2 "Error installing our required packages, aborting"
- exit 1
-}
-echo "Setup complete"
diff --git a/scripts/setup-ubuntu b/scripts/setup-ubuntu
deleted file mode 100755
index 54bc0429..00000000
--- a/scripts/setup-ubuntu
+++ /dev/null
@@ -1,48 +0,0 @@
-#!/bin/sh
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: GPL-2.0
-# ---------------------------------------------------------------------------------------------------------------------
-#
-# Copyright 2022 Siemens
-#
-# This file is licensed under the terms of the GNU General Public License
-# version 2. This program is licensed "as is" without any warranty of any
-# kind, whether express or implied.
-
-echo "Verifying access to sudo, please enter your password if prompted."
-if [ "$(id -u)" -ne 0 ]; then
- SUDO=sudo
- $SUDO -v
- if [ $? -ne 0 ]; then
- echo >&2 "Could not use sudo, exiting"
- exit 1
- fi
-else
- SUDO=
-fi
-
-PKGS="$PKGS ubuntu-minimal ubuntu-standard make gcc g++ patch diffstat texinfo texi2html cvs subversion bzip2 tar gzip gawk chrpath libncurses5-dev git-core lsb-release python3 xvfb x11-utils rsync zstd liblz4-tool"
-
-# These are needed for the qemu-native build
-PKGS="$PKGS libgl1-mesa-dev libglu1-mesa-dev libsdl1.2-dev"
-
-# This is helpful to write images, and is in our documentation
-PKGS="$PKGS bmap-tools"
-
-# This is needed for Windows ADE
-PKGS="$PKGS zip"
-
-echo "Installing packages required to build Mentor Embedded Linux Flex OS"
-$SUDO apt-get update
-$SUDO apt-get -y install $PKGS
-
-if [ "$(uname -m)" = "x86_64" ]; then
- $SUDO dpkg --add-architecture i386
- $SUDO apt-get -y install libc6-dev-i386
- $SUDO apt-get -y install libncurses5:i386
-fi
-
-echo "Generating the en_US.UTF-8 locale"
-$SUDO locale-gen en_US.UTF-8
-
-echo "Setup complete"
diff --git a/setup-environment b/setup-environment
deleted file mode 100644
index d805d050..00000000
--- a/setup-environment
+++ /dev/null
@@ -1,136 +0,0 @@
-# ---------------------------------------------------------------------------------------------------------------------
-# SPDX-License-Identifier: MIT
-# ---------------------------------------------------------------------------------------------------------------------
-
-if [ -z "$ZSH_NAME" ] && [ "x$0" = "x./setup-environment" ]; then
- echo >&2 "Error: This script needs to be sourced. Please run as '. ./setup-environment'"
-else
- if [ -n "$BASH_SOURCE" ]; then
- layerdir="$(cd "$(dirname "$BASH_SOURCE")" && pwd -P)"
- elif [ -n "$ZSH_NAME" ]; then
- layerdir="$(cd "$(dirname "$0")" && pwd -P)"
- else
- layerdir="$(pwd -P)"
- fi
-
- export PYENV_ROOT="${PYENV_ROOT:-~/.pyenv}"
- PATH="$PYENV_ROOT/shims:$PATH"
-
- if [ -f conf/local.conf -o -f conf/bblayers.conf ]; then
- # Assuming we're already in the build dir
- BUILDDIR=$PWD
- else
- BUILDDIR=$PWD/build
- fi
-
- for i in $(seq $#); do
- setup_mel_arg="$(eval printf "%s" "\$$i")"
- case "$setup_mel_arg" in
- -b)
- BUILDDIR="$(eval printf "%s" "\$$(expr $i + 1)")"
- if [ -z "$BUILDDIR" ]; then
- echo >&2 "-b requires an argument"
- fi
- BUILDDIR="$(readlink -f "$BUILDDIR")"
- ;;
- esac
- done
-
- (
- for layercheck in $layerdir . $layerdir/..; do
- if [ -e "$layercheck/setup-environment.conf" ]; then
- . "$layercheck/setup-environment.conf"
- fi
- if [ -e "$layercheck/.setup-environment.conf" ]; then
- . "$layercheck/.setup-environment.conf"
- fi
- done
-
- OPTIONALLAYERS="${OPTIONALLAYERS-mentor-private tracing-layer}"
- # Customer directory layers handling (e.g. <customername>-custom)
- for layercheck in . $layerdir/..; do
- if [ -e "$layercheck/customer.conf" ]; then
- while read -r _customer; do
- for layercheck2 in . $layerdir/..; do
- if [ -d "$layercheck2/$_customer-custom" ]; then
- if [ -e "$layercheck2/$_customer-custom/custom.conf" ]; then
- CUSTOMERLAYERS=$(cat $layercheck2/$_customer-custom/custom.conf | sed -e '/^[ ]*#/d')
- CUSTOMERLAYERS=$(echo $CUSTOMERLAYERS | sed -e 's/\n//g')
- OPTIONALLAYERS="$OPTIONALLAYERS $CUSTOMERLAYERS"
- fi
- break
- fi
- done
- done <"$layercheck/customer.conf"
- break
- fi
- done
-
- # Hotfix layers handling
- if [ -e "$layerdir/../hotfixes/hotfix.conf" ]; then
- HOTFIXES=$(cat $layerdir/../hotfixes/hotfix.conf | sed -e '/^[ ]*#/d')
- HOTFIXES=$(echo $HOTFIXES | sed -e 's/\n//g')
- OPTIONALLAYERS="$OPTIONALLAYERS $HOTFIXES"
- fi
-
- # Extra layers handling
- if [ -e "$layerdir/../xlayers.conf" ]; then
- EXTRALAYERS=$(cat $layerdir/../xlayers.conf | sed -e '/^[ ]*#/d')
- EXTRALAYERS=$(echo $EXTRALAYERS | sed -e 's/\n//g')
- OPTIONALLAYERS="$OPTIONALLAYERS $EXTRALAYERS"
- fi
-
- export OPTIONALLAYERS EXTRAMELLAYERS EXCLUDEDLAYERS
-
- $layerdir/scripts/setup-mel-builddir "$@"
- )
- mel_setup_ret=$?
- if [ $mel_setup_ret -eq 0 ] && [ -n "$BUILDDIR" ] && [ -e "$BUILDDIR" ]; then
- . $BUILDDIR/setup-environment
-
- configured_layers() {
- tac $BUILDDIR/conf/bblayers.conf \
- | sed -n -e '/^"/,/^BBLAYERS = /{ /^BBLAYERS =/d; /^"/d; p;}' \
- | awk {'print $1'} | sed -e "s#\${TOPDIR}/#$BUILDDIR/#"
- }
-
- load_lconf_snippet() {
- if [ ! -e "$1/$2" ]; then
- return
- fi
- (
- lheadername="${1#${layerdir%/*}/}/$2"
- printf '\n## Begin %s\n\n' "$lheadername"
- cat "$1/$2"
- printf '\n## End %s\n' "$lheadername"
- ) >>conf/local.conf
- }
-
- if [ -e $layerdir/post-setup-environment ]; then
- . $layerdir/post-setup-environment
- fi
-
- if [ -e "$BUILDDIR/conf/local.conf" ] && [ -e "$BUILDDIR/conf/bblayers.conf" ]; then
- sed -i -n -e ":out; /^## Begin /{ :loop; /^## End /{ d; b out; }; n; b loop; }; p;" conf/local.conf
- SETUP_ENV_MACHINE="$(sed -n -e 's/^MACHINE *?*= *"\(.*\)"/\1/p' "$BUILDDIR/conf/local.conf")"
-
- load_lconf_snippet "$layerdir" "conf/local.conf.append"
- load_lconf_snippet "$layerdir" "conf/local.conf.append.$SETUP_ENV_MACHINE"
- configured_layers | grep -Fvx "$layerdir" | while read layer; do
- if [ -e $layer/post-setup-environment ]; then
- . $layer/post-setup-environment
- fi
- load_lconf_snippet "$layer" "conf/local.conf.append"
- load_lconf_snippet "$layer" "conf/local.conf.append.$SETUP_ENV_MACHINE"
- done
-
- . $BUILDDIR/setup-environment >/dev/null 2>&1
- fi
-
- unset SETUP_ENV_MACHINE
- unset load_lconf_snippet
- unset configured_layers
- fi
- unset layerdir setup_mel_arg
- test $mel_setup_ret -eq 0
-fi