diff --git a/conf/distro/lime.conf b/conf/distro/lime.conf new file mode 100644 index 0000000..b0c2d9f --- /dev/null +++ b/conf/distro/lime.conf @@ -0,0 +1,86 @@ +DISTRO = "lime" +DISTRO_NAME = "LimeLinux" +DISTRO_VERSION = "v0.1.2" +DISTRO_CODENAME = "scarthgap" +SDK_VENDOR = "-pokysdk" +SDK_VERSION = "${@d.getVar('DISTRO_VERSION').replace('snapshot-${METADATA_REVISION}', 'snapshot')}" +SDK_VERSION[vardepvalue] = "${SDK_VERSION}" + +MAINTAINER = "Imbus " + +TARGET_VENDOR = "-lime" + +LOCALCONF_VERSION = "2" + +# Override these in poky based distros +#POKY_DEFAULT_DISTRO_FEATURES = "opengl ptest multiarch wayland vulkan" +POKY_DEFAULT_EXTRA_RDEPENDS = "packagegroup-core-boot" +POKY_DEFAULT_EXTRA_RRECOMMENDS = "kernel-module-af-packet" + +DISTRO_FEATURES ?= "${DISTRO_FEATURES_DEFAULT} ${POKY_DEFAULT_DISTRO_FEATURES}" +PREFERRED_PROVIDER_virtual/kernel = "linux-bb.org" +PREFERRED_VERSION_linux-bb = "6.12%" + +#PREFERRED_VERSION_linux-yocto = "6.6%" +#PREFERRED_VERSION_linux-yocto-rt ?= "6.6%" + +IMAGE_FEATURES += "ssh-server-dropbear package-management" + +SDK_NAME = "${DISTRO}-${TCLIBC}-${SDKMACHINE}-${IMAGE_BASENAME}-${TUNE_PKGARCH}-${MACHINE}" +SDKPATHINSTALL = "/opt/${DISTRO}/${SDK_VERSION}" + +DISTRO_EXTRA_RDEPENDS += "${POKY_DEFAULT_EXTRA_RDEPENDS}" +DISTRO_EXTRA_RRECOMMENDS += "${POKY_DEFAULT_EXTRA_RRECOMMENDS}" + +TCLIBCAPPEND = "" + +PACKAGE_CLASSES ?= "package_ipk" + +SANITY_TESTED_DISTROS ?= " \ + poky-4.3 \n \ + poky-5.0 \n \ + ubuntu-20.04 \n \ + ubuntu-22.04 \n \ + ubuntu-23.04 \n \ + ubuntu-24.04 \n \ + fedora-38 \n \ + fedora-39 \n \ + fedora-40 \n \ + centosstream-8 \n \ + debian-11 \n \ + debian-12 \n \ + debian-13 \n \ + opensuseleap-15.4 \n \ + almalinux-8.8 \n \ + almalinux-8.9 \n \ + almalinux-8.10 \n \ + almalinux-9.2 \n \ + almalinux-9.4 \n \ + rocky-9 \n \ + " +# add poky sanity bbclass +INHERIT += "poky-sanity" + +# QA check settings - a little stricter than the OE-Core defaults +# (none currently necessary as we now match OE-Core) +#WARN_TO_ERROR_QA = "X" +#WARN_QA_remove = "${WARN_TO_ERROR_QA}" +#ERROR_QA_append = " ${WARN_TO_ERROR_QA}" + +require conf/distro/include/poky-world-exclude.inc +require conf/distro/include/no-static-libs.inc +require conf/distro/include/yocto-uninative.inc +require conf/distro/include/security_flags.inc +INHERIT += "uninative" + +BB_SIGNATURE_HANDLER ?= "OEEquivHash" +BB_HASHSERVE ??= "auto" + +POKY_INIT_MANAGER = "systemd" +INIT_MANAGER ?= "${POKY_INIT_MANAGER}" + +# We need debug symbols so that SPDX license manifests for the kernel work +KERNEL_EXTRA_FEATURES:append = " features/debug/debug-kernel.scc" + +# Enable creation of SPDX manifests by default +INHERIT += "create-spdx" diff --git a/conf/layer.conf b/conf/layer.conf index 31c223f..2152d1c 100644 --- a/conf/layer.conf +++ b/conf/layer.conf @@ -9,5 +9,5 @@ BBFILE_COLLECTIONS += "meta-imbus" BBFILE_PATTERN_meta-imbus = "^${LAYERDIR}/" BBFILE_PRIORITY_meta-imbus = "6" -LAYERDEPENDS_meta-imbus = "core" +LAYERDEPENDS_meta-imbus = "core meta-beagle" LAYERSERIES_COMPAT_meta-imbus = "scarthgap" diff --git a/recipes-core/base-files/base-files_3.%.bbappend b/recipes-core/base-files/base-files_3.%.bbappend index bfb7457..7a40147 100644 --- a/recipes-core/base-files/base-files_3.%.bbappend +++ b/recipes-core/base-files/base-files_3.%.bbappend @@ -1 +1,10 @@ hostname = "imbus-mini" + +FILESEXTRAPATHS:prepend := "${THISDIR}/files:" + +SRC_URI += "file://ps1-extra.sh" + +do_install:append() { + cat ${WORKDIR}/ps1-extra.sh >> ${D}${sysconfdir}/profile +} + diff --git a/recipes-core/base-files/files/issue b/recipes-core/base-files/files/issue new file mode 100644 index 0000000..4ad5809 --- /dev/null +++ b/recipes-core/base-files/files/issue @@ -0,0 +1,6 @@ + ___ _ __ __ _ _ +|_ _|_ __ ___ | |__ _ _ ___| \\/ (_)_ __ (_) + | || '_ ` _ \\| '_ \\| | | / __| |\\/| | | '_ \\| | + | || | | | | | |_) | |_| \\__ \\ | | | | | | | | +|___|_| |_| |_|_.__/ \\__,_|___/_| |_|_|_| |_|_| + diff --git a/recipes-core/base-files/files/ps1-extra.sh b/recipes-core/base-files/files/ps1-extra.sh new file mode 100644 index 0000000..38323eb --- /dev/null +++ b/recipes-core/base-files/files/ps1-extra.sh @@ -0,0 +1,5 @@ +# Custom PS1 for BusyBox ash + +if [ "$TERM" != "dumb" ]; then + PS1="\033[1;32m\u@\h:\w\$ \033[0m" +fi diff --git a/recipes-example/example/example_0.1.bb b/recipes-example/example/example_0.1.bb deleted file mode 100644 index facaae3..0000000 --- a/recipes-example/example/example_0.1.bb +++ /dev/null @@ -1,13 +0,0 @@ -SUMMARY = "bitbake-layers recipe" -DESCRIPTION = "Recipe created by bitbake-layers" -LICENSE = "MIT" - -python do_display_banner() { - bb.plain("***********************************************"); - bb.plain("* *"); - bb.plain("* Example recipe created by bitbake-layers *"); - bb.plain("* *"); - bb.plain("***********************************************"); -} - -addtask display_banner before do_build diff --git a/recipes-kernel/kernelmod-demo_git.bb b/recipes-kernel/kernelmod-demo_git.bb deleted file mode 100644 index 00c7df0..0000000 --- a/recipes-kernel/kernelmod-demo_git.bb +++ /dev/null @@ -1,26 +0,0 @@ -# Recipe created by recipetool -# This is the basis of a recipe and may need further editing in order to be fully functional. -# (Feel free to remove these comments when editing.) - -# Unable to find any files that looked like license statements. Check the accompanying -# documentation and source headers and set LICENSE and LIC_FILES_CHKSUM accordingly. -# -# NOTE: LICENSE is being set to "CLOSED" to allow you to at least start building - if -# this is not accurate with respect to the licensing of the software being built (it -# will not be in most cases) you must specify the correct value before using this -# recipe for anything other than initial testing/development! -LICENSE = "CLOSED" -LIC_FILES_CHKSUM = "" - -SRC_URI = "git://git.silversoft.se/Imbus/kernelmod_demo.git;protocol=https;branch=master" - -# Modify these as desired -PV = "1.0+git" -SRCREV = "40295d6d459c666d5f7174cce520350be8cac464" - -S = "${WORKDIR}/git" - -inherit module - -EXTRA_OEMAKE:append:task-install = " -C ${STAGING_KERNEL_DIR} M=${S}" -# Kernel path in install makefile is hardcoded - you will need to patch the makefile. Note that the variable KERNEL_SRC will be passed in as the kernel source path. diff --git a/recipes-kernel/linux/limbux_6.10.6.bb b/recipes-kernel/linux/limbux_6.10.6.bb deleted file mode 100644 index 6393d54..0000000 --- a/recipes-kernel/linux/limbux_6.10.6.bb +++ /dev/null @@ -1,72 +0,0 @@ -SUMMARY = "An example kernel recipe that uses the linux-yocto and oe-core" -# linux-yocto-custom.bb: -# -# kernel classes to apply a subset of yocto kernel management to git -# managed kernel repositories. -# -# To use linux-yocto-custom in your layer, copy this recipe (optionally -# rename it as well) and modify it appropriately for your machine. i.e.: -# -# COMPATIBLE_MACHINE:yourmachine = "yourmachine" -# -# You must also provide a Linux kernel configuration. The most direct -# method is to copy your .config to files/defconfig in your layer, -# in the same directory as the copy (and rename) of this recipe and -# add file://defconfig to your SRC_URI. -# -# To use the yocto kernel tooling to generate a BSP configuration -# using modular configuration fragments, see the yocto-bsp and -# yocto-kernel tools documentation. -# -# Warning: -# -# Building this example without providing a defconfig or BSP -# configuration will result in build or boot errors. This is not a -# bug. -# -# -# Notes: -# -# patches: patches can be merged into to the source git tree itself, -# added via the SRC_URI, or controlled via a BSP -# configuration. -# -# defconfig: When a defconfig is provided, the linux-yocto configuration -# uses the filename as a trigger to use a 'allnoconfig' baseline -# before merging the defconfig into the build. -# -# If the defconfig file was created with make_savedefconfig, -# not all options are specified, and should be restored with their -# defaults, not set to 'n'. To properly expand a defconfig like -# this, specify: KCONFIG_MODE="--alldefconfig" in the kernel -# recipe. -# -# example configuration addition: -# SRC_URI += "file://smp.cfg" -# example patch addition (for kernel v4.x only): -# SRC_URI += "file://0001-linux-version-tweak.patch" -# example feature addition (for kernel v4.x only): -# SRC_URI += "file://feature.scc" -# - -inherit kernel -require recipes-kernel/linux/linux-yocto.inc - -# Override SRC_URI in a copy of this recipe to point at a different source -# tree if you do not want to build from Linus' tree. -SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git;protocol=git;nocheckout=1;name=machine" -SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git;branch=linux-6.10.y" - -LINUX_VERSION ?= "4.2" -LINUX_VERSION_EXTENSION:append = "-custom" - -# Modify SRCREV to a different commit hash in a copy of this recipe to -# build a different release of the Linux kernel. -# tag: v4.2 64291f7db5bd8150a74ad2036f1037e6a0428df2 -SRCREV_machine="7ba498d9d1bb67bcbc2a79f19a9054cdc8b95098" - -PV = "${LINUX_VERSION}+git" - -# Override COMPATIBLE_MACHINE to include your machine in a copy of this recipe -# file. Leaving it empty here ensures an early explicit build failure. -COMPATIBLE_MACHINE = "(^$)" diff --git a/recipes-kernel/linux/linux-yocto-custom.bb b/recipes-kernel/linux/linux-yocto-custom.bb deleted file mode 100644 index 0879bb1..0000000 --- a/recipes-kernel/linux/linux-yocto-custom.bb +++ /dev/null @@ -1,71 +0,0 @@ -SUMMARY = "An example kernel recipe that uses the linux-yocto and oe-core" -# linux-yocto-custom.bb: -# -# kernel classes to apply a subset of yocto kernel management to git -# managed kernel repositories. -# -# To use linux-yocto-custom in your layer, copy this recipe (optionally -# rename it as well) and modify it appropriately for your machine. i.e.: -# -# COMPATIBLE_MACHINE:yourmachine = "yourmachine" -# -# You must also provide a Linux kernel configuration. The most direct -# method is to copy your .config to files/defconfig in your layer, -# in the same directory as the copy (and rename) of this recipe and -# add file://defconfig to your SRC_URI. -# -# To use the yocto kernel tooling to generate a BSP configuration -# using modular configuration fragments, see the yocto-bsp and -# yocto-kernel tools documentation. -# -# Warning: -# -# Building this example without providing a defconfig or BSP -# configuration will result in build or boot errors. This is not a -# bug. -# -# -# Notes: -# -# patches: patches can be merged into to the source git tree itself, -# added via the SRC_URI, or controlled via a BSP -# configuration. -# -# defconfig: When a defconfig is provided, the linux-yocto configuration -# uses the filename as a trigger to use a 'allnoconfig' baseline -# before merging the defconfig into the build. -# -# If the defconfig file was created with make_savedefconfig, -# not all options are specified, and should be restored with their -# defaults, not set to 'n'. To properly expand a defconfig like -# this, specify: KCONFIG_MODE="--alldefconfig" in the kernel -# recipe. -# -# example configuration addition: -# SRC_URI += "file://smp.cfg" -# example patch addition (for kernel v4.x only): -# SRC_URI += "file://0001-linux-version-tweak.patch" -# example feature addition (for kernel v4.x only): -# SRC_URI += "file://feature.scc" -# - -inherit kernel -require recipes-kernel/linux/linux-yocto.inc - -# Override SRC_URI in a copy of this recipe to point at a different source -# tree if you do not want to build from Linus' tree. -SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git;protocol=git;nocheckout=1;name=machine" - -LINUX_VERSION ?= "4.2" -LINUX_VERSION_EXTENSION:append = "-custom" - -# Modify SRCREV to a different commit hash in a copy of this recipe to -# build a different release of the Linux kernel. -# tag: v4.2 64291f7db5bd8150a74ad2036f1037e6a0428df2 -SRCREV_machine="64291f7db5bd8150a74ad2036f1037e6a0428df2" - -PV = "${LINUX_VERSION}+git" - -# Override COMPATIBLE_MACHINE to include your machine in a copy of this recipe -# file. Leaving it empty here ensures an early explicit build failure. -COMPATIBLE_MACHINE = "(^$)" diff --git a/recipes-writeimg/writeimg/writeimg_git.bb b/recipes-writeimg/writeimg/writeimg_git.bb new file mode 100644 index 0000000..2934ef3 --- /dev/null +++ b/recipes-writeimg/writeimg/writeimg_git.bb @@ -0,0 +1,18 @@ +LICENSE = "BSD-2-Clause" +LIC_FILES_CHKSUM = "file://${S}/LICENSE;md5=3ccfc2e9b5d66e6202a85da816667d7c" + +PV = "0.2.2" +SRC_URI = "git://git.silversoft.se/Imbus/writeimg.git;protocol=https;branch=master" + +SRCREV = "60e7179766d95cb56540759d6eea4dcd9b9a17f8" + +S = "${WORKDIR}/git" + +do_compile () { + oe_runmake +} + +do_install () { + oe_runmake install 'DESTDIR=${D}' 'PREFIX=${prefix}' +} +