commit ebf07c1f7583b6c0eac5eefabf3415f1815f40cc Author: Alexandre Bard Date: Fri Dec 18 10:06:32 2020 +0100 Adding base layers and configurations BugzID: 69469 diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..01428f4 --- /dev/null +++ b/.gitignore @@ -0,0 +1,6 @@ +build/bitbake* +build/cache +build/tmp +build/downloads +build/sstate-cache +build/buildhistory diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..47c75d1 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,27 @@ +[submodule "bitbake"] + path = bitbake + url = git://git.openembedded.org/bitbake.git + branch = 1.42 +[submodule "openembedded-core"] + path = openembedded-core + url = git://git.openembedded.org/openembedded-core + branch = warrior +[submodule "meta-openembedded"] + path = meta-openembedded + url = git://git.openembedded.org/meta-openembedded + branch = warrior +[submodule "meta-updater"] + path = meta-updater + url = https://github.com/advancedtelematic/meta-updater.git + branch = warrior +[submodule "meta-netmodule-bsp"] + path = meta-netmodule-bsp + url = git@gitlab.com:netmodule/yoctoproject/meta-netmodule-bsp.git + branch = warrior +[submodule "meta-netmodule-distro"] + path = meta-netmodule-distro + url = git@gitlab.com:netmodule/yoctoproject/meta-netmodule-distro.git + branch = warrior +[submodule "meta-netmodule-wlan"] + path = meta-netmodule-wlan + url = git@gitlab.com:netmodule/yoctoproject/meta-netmodule-wlan.git diff --git a/bitbake b/bitbake new file mode 160000 index 0000000..b4860b2 --- /dev/null +++ b/bitbake @@ -0,0 +1 @@ +Subproject commit b4860b292406698f3c8af9a3708a09df21c96300 diff --git a/build/conf/bblayers.conf b/build/conf/bblayers.conf new file mode 100644 index 0000000..8076340 --- /dev/null +++ b/build/conf/bblayers.conf @@ -0,0 +1,20 @@ +# LAYER_CONF_VERSION is increased each time build/conf/bblayers.conf +# changes incompatibly +LCONF_VERSION = "7" + +BBPATH = "${TOPDIR}" +BBFILES ?= "" + +YOCTOROOT = "${@os.path.abspath(os.path.join("${TOPDIR}", os.pardir))}" + +BBLAYERS ?= " \ + ${YOCTOROOT}/openembedded-core/meta \ + ${YOCTOROOT}/meta-netmodule-wlan \ + ${YOCTOROOT}/meta-netmodule-bsp \ + ${YOCTOROOT}/meta-netmodule-distro \ + ${YOCTOROOT}/meta-openembedded/meta-python \ + ${YOCTOROOT}/meta-openembedded/meta-oe \ + ${YOCTOROOT}/meta-openembedded/meta-networking \ + ${YOCTOROOT}/meta-openembedded/meta-filesystems \ + ${YOCTOROOT}/meta-updater \ + " diff --git a/build/conf/local.conf b/build/conf/local.conf new file mode 100644 index 0000000..a8cafef --- /dev/null +++ b/build/conf/local.conf @@ -0,0 +1,41 @@ +BB_NUMBER_THREADS ?= "4" +PARALLEL_MAKE ?= "-j 4" +PACKAGE_CLASSES ?= "package_rpm" +USER_CLASSES ?= "buildstats image-mklibs image-prelink" +PATCHRESOLVE = "noop" +BB_DISKMON_DIRS = "\ + STOPTASKS,${TMPDIR},1G,100K \ + STOPTASKS,${DL_DIR},1G,100K \ + STOPTASKS,${SSTATE_DIR},1G,100K \ + STOPTASKS,/tmp,100M,100K \ + ABORT,${TMPDIR},100M,1K \ + ABORT,${DL_DIR},100M,1K \ + ABORT,${SSTATE_DIR},100M,1K \ + ABORT,/tmp,10M,1K" +ASSUME_PROVIDED += "libsdl-native" +CONF_VERSION = "1" +EXTRA_IMAGE_FEATURES_append = " debug-tweaks" + +ERROR_QA_remove += "version-going-backwards" +#WARN_QA_append += "version-going-backwards" +#https://www.yoctoproject.org/docs/2.5.2/ref-manual/ref-manual.html#ref-classes-insane + +#PRSERV_HOST = "localhost:0" + +# Add licences file to the rootfs +COPY_LIC_MANIFEST = "1" +COPY_LIC_DIRS = "1" +LICENSE_CREATE_PACKAGE = "1" + +YOCTOROOT = "${@os.path.abspath(os.path.join("${TOPDIR}", os.pardir))}" + +PREMIRRORS_prepend = "\ + git://.*/.* file://${YOCTOROOT}/sla-mirror/ \n \ + ftp://.*/.* file://${YOCTOROOT}/sla-mirror/ \n \ + http://.*/.* file://${YOCTOROOT}/sla-mirror/ \n \ + https://.*/.* file://${YOCTOROOT}/sla-mirror/ \n" + +include distro_version.inc +include release_revisions.inc +include public-mirrors.inc +include proprietary-dev-tools.inc diff --git a/build/conf/proprietary-dev-tools.inc b/build/conf/proprietary-dev-tools.inc new file mode 100644 index 0000000..70cea5e --- /dev/null +++ b/build/conf/proprietary-dev-tools.inc @@ -0,0 +1,7 @@ +# These tools are not publicly available be usually included +# in the development image + +IMAGE_INSTALL_remove += "scripts-nm \ + sys-mon \ + battery-test \ +" diff --git a/build/conf/public-mirrors.inc b/build/conf/public-mirrors.inc new file mode 100644 index 0000000..1ab209b --- /dev/null +++ b/build/conf/public-mirrors.inc @@ -0,0 +1,27 @@ +# Changing internal SRC_URI to public + +## Bootloaders +UBOOT_TI_SRC = "git://gitlab.com/netmodule/bootloader/netmodule-uboot.git;user=git;branch=2016.05/standard/am335x;protocol=ssh;" +SRC_URI_pn-u-boot-am335x-nrhw16-v2 = "${UBOOT_TI_SRC}" +SRC_URI_pn-u-boot-am335x-nrhw20-v1 = "${UBOOT_TI_SRC}" +SRC_URI_pn-u-boot-am335x-nmhw21 = "${UBOOT_TI_SRC}" +SRC_URI_pn-u-boot-am335x-nmhw24 = "${UBOOT_TI_SRC}" +SRC_URI_pn-u-boot-am335x-hw25 = "${UBOOT_TI_SRC}" + +SRC_URI_pn-u-boot-armada-385-nrhw18-v2 = "git://gitlab.com/netmodule/bootloader/netmodule-uboot.git;user=git;branch=2017.11/standard/armada-385;protocol=ssh;" + +SRC_URI_pn-u-boot-imx8-nmhw23 = "git://gitlab.com/netmodule/bootloader/netmodule-uboot.git;user=git;branch=2018.03/imx/imx8-mek;protocol=ssh" + +## Kernel +KERNEL_SRC = "git://gitlab.com/netmodule/kernel/linux-netmodule.git;user=git;branch=4.19/standard/base;protocol=ssh" +SRC_URI_pn-linux-netmodule = "${KERNEL_SRC}" +SRC_URI_pn-linux-netmodule-initramfs = "${KERNEL_SRC}" + + +# Removing AUTOREV from uneeded recipes pointing to internal repos +## distro layer +SRCREV_pn-battery-test = "0" + +## bsp layer +SRCREV_pn-dt-overlay = "0" + diff --git a/build/conf/release_revisions.inc b/build/conf/release_revisions.inc new file mode 100644 index 0000000..2d8748f --- /dev/null +++ b/build/conf/release_revisions.inc @@ -0,0 +1,25 @@ +SRCREV_pn-linux-netmodule = "4683b46a6d736f0d67db8a5a3bb1dfe645f13c82" +SRCREV_pn-linux-netmodule-initramfs = "4683b46a6d736f0d67db8a5a3bb1dfe645f13c82" +# HW23 +SRCREV_pn-linux-netmodule_imx8-nmhw23 = "22f9c3c6448cbfafb5e7a1bf539ba7ba688fde7d" +SRCREV_pn-linux-netmodule-initramfs_imx8_nmhw23 = "22f9c3c6448cbfafb5e7a1bf539ba7ba688fde7d" + +SRCREV_pn-u-boot-am335x-nrhw20-v1 = "e8475b4f809c25f22e2be74b98661568ac8c06e0" +SRCREV_pn-u-boot-am335x-nmhw21 = "e8475b4f809c25f22e2be74b98661568ac8c06e0" +SRCREV_pn-u-boot-imx8-nmhw23 = "7f6a031a0806f9a18976373d3988031cb2934277" +SRCREV_pn-u-boot-am335x-nmhw24 = "e8475b4f809c25f22e2be74b98661568ac8c06e0" +SRCREV_pn-u-boot-am335x-hw25 = "e8475b4f809c25f22e2be74b98661568ac8c06e0" + +SRCREV_pn-imx-boot = "dd0234001713623c79be92b60fa88bc07b07f24f" +SRCREV_pn-imx-atf = "413e93e10ee4838e9a68b190f1468722f6385e0e" + +SRCREV_pn-nmhw-fwupdate = "029491bec8c971195af208da8687a4661bf90e2b" +SRCREV_pn-bootloader-config = "e45c8d44451bd8b8b8987eb4330095359eddcf84" +SRCREV_pn-gnss-mgr = "98e82bbb97a7852c9b1723f2187b80aeec7ee7c3" +SRCREV_pn-udev-rules-nmhw = "f7969eaac9cc9db546295f185b2b7e54cc409da9" +SRCREV_pn-nmubxlib = "745231869cafe4ad00a4be4273684f6ed4fc4006" +SRCREV_pn-wlconf-bin = "cf9bfca0a80f02eb4a4245ab0144f8e956e24b95" +SRCREV_pn-wwan-config = "bb7051835245d8f1b51792757bc1c7aa29416d1f" +SRCREV_pn-modemmanager = "fb94f003f5c03eafd2c62ac977e536d6489ad6b3" +SRCREV_pn-speedtest-cli = "c58ad3367bf27f4b4a4d5b1bca29ebd574731c5d" +SRCREV_pn-gpsd = "ed1babcb32b5d8ac5989c9b76f3691570e12fad5" diff --git a/build/conf/templateconf.cfg b/build/conf/templateconf.cfg new file mode 100644 index 0000000..f948736 --- /dev/null +++ b/build/conf/templateconf.cfg @@ -0,0 +1 @@ +../meta-netmodule-distro/conf diff --git a/env.common b/env.common new file mode 100644 index 0000000..c85fa9c --- /dev/null +++ b/env.common @@ -0,0 +1,21 @@ +set -a # exports all variables + +# exporting DISTRO* +DISTRO_OSTREE=$DISTRO_OSTREE +DISTRO_TYPE=$DISTRO_TYPE +DISTRO=netmodule-linux$DISTRO_OSTREE$DISTRO_TYPE + +if [ -z "$MACHINE" ]; then + . ./machine_select +fi + +MACHINE_TYPE=$(echo $MACHINE | rev | cut -f2- -d- | rev) + +echo Building for machine $MACHINE, distro: $DISTRO + +OSTREE_OSNAME=nm-linux + +BB_ENV_EXTRAWHITE="$BB_ENV_EXTRAWHITE MACHINE_TYPE DISTRO_OSTREE DISTRO_TYPE" + +TEMPLATECONF="../meta-netmodule-distro/conf" +. ./openembedded-core/oe-init-build-env diff --git a/env.image b/env.image new file mode 100644 index 0000000..f574ac9 --- /dev/null +++ b/env.image @@ -0,0 +1,4 @@ +DISTRO_OSTREE="" +DISTRO_TYPE="" + +. ./env.common diff --git a/env.image-minimal b/env.image-minimal new file mode 100644 index 0000000..828cf81 --- /dev/null +++ b/env.image-minimal @@ -0,0 +1,4 @@ +DISTRO_OSTREE="" +DISTRO_TYPE="-minimal" + +. ./env.common diff --git a/env.image-ostree b/env.image-ostree new file mode 100644 index 0000000..dcca0bd --- /dev/null +++ b/env.image-ostree @@ -0,0 +1,4 @@ +DISTRO_OSTREE="-ostree" +DISTRO_TYPE="" + +. ./env.common diff --git a/machine_select b/machine_select new file mode 100755 index 0000000..afa5c4e --- /dev/null +++ b/machine_select @@ -0,0 +1,58 @@ +#!/usr/bin/env sh +if [[ $_ == "$0" ]]; then + echo "This script must be sourced to set the MACHINE variable environment" + exit 1 +fi + + +PS3='Please choose a machine: ' +HW16="hw16 - NB800" +HW18="hw18 - NB1800" +HW20="hw20 - NB1601" +HW21="hw21 - VCU1" +HW23="hw23 - VCU2" +HW24="hw24 - NB800 facelift" +HW25="hw25 - TC Router" +HW26="hw26 - NG800" + +set -a +select opt in "$HW16" "$HW18" "$HW20" "$HW21" "$HW23" "$HW24" "$HW25" "$HW26" +do + case $opt in + "$HW16") + MACHINE=am335x-nrhw16 + break + ;; + "$HW18") + MACHINE=armada-385-nrhw18 + break + ;; + "$HW20") + MACHINE=am335x-nrhw20 + break + ;; + "$HW21") + MACHINE=am335x-nmhw21 + break + ;; + "$HW23") + MACHINE=imx8-nmhw23 + break + ;; + "$HW24") + MACHINE=am335x-nmhw24 + break + ;; + "$HW25") + MACHINE=am335x-hw25 + break + ;; + "$HW26") + MACHINE=am335x-hw26 + break + ;; + *) echo "invalid option $opt";; + esac +done + +echo $MACHINE diff --git a/meta-netmodule-bsp b/meta-netmodule-bsp new file mode 160000 index 0000000..2680c89 --- /dev/null +++ b/meta-netmodule-bsp @@ -0,0 +1 @@ +Subproject commit 2680c89a0897af4fd820ec074176445a62f4a863 diff --git a/meta-netmodule-distro b/meta-netmodule-distro new file mode 160000 index 0000000..18b81ba --- /dev/null +++ b/meta-netmodule-distro @@ -0,0 +1 @@ +Subproject commit 18b81bac4847990cddfbdf7c69812ec2c6ba83d8 diff --git a/meta-netmodule-wlan b/meta-netmodule-wlan new file mode 160000 index 0000000..77b3edc --- /dev/null +++ b/meta-netmodule-wlan @@ -0,0 +1 @@ +Subproject commit 77b3edc5edb9084dc5f96cc76d44c1f7044bae80 diff --git a/meta-openembedded b/meta-openembedded new file mode 160000 index 0000000..a24acf9 --- /dev/null +++ b/meta-openembedded @@ -0,0 +1 @@ +Subproject commit a24acf94d48d635eca668ea34598c6e5c857e3f8 diff --git a/meta-updater b/meta-updater new file mode 160000 index 0000000..0d5c911 --- /dev/null +++ b/meta-updater @@ -0,0 +1 @@ +Subproject commit 0d5c911120c02f0851e497f1fde02f515e557e3e diff --git a/openembedded-core b/openembedded-core new file mode 160000 index 0000000..856674d --- /dev/null +++ b/openembedded-core @@ -0,0 +1 @@ +Subproject commit 856674d6f75e2b99ae961d5ab869ff071ff5c362