Re: [yocto] do_install_append syntax error
Ok my god. Got it. It works now. Thanks Raj! -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#62144): https://lists.yoctoproject.org/g/yocto/message/62144 Mute This Topic: https://lists.yoctoproject.org/mt/103724054/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[yocto] do_install_append syntax error
Hello, I am adding a systemd service. It always complains > > >> Variable do_install_append contains an operation using the old override >> syntax. Please convert this layer/metadata before attempting to use with a >> newer bitbake. > > Already changed _ to :. Anyone can help with this? Thanks! Crane The recipe is like this: > > > > SUMMARY = " init service at boot" > > > > LICENSE = "CLOSED" > > > > > > > > inherit systemd > > > > > > > > SRC_URI += "file://farview.service" > > > > S = "${WORKDIR}" > > > > > > > > SYSTEMD_AUTO_ENABLE:${PN} = "enable" > > > > SYSTEMD_PACKAGES = "${PN}" > > > > SYSTEDD_SERVICE:${PN} = "farview.service" > > > > > > > > do_install_append() { > > > > install -d ${D}${systemd_system_unitdir} > > > > install -m 0644 ${WORKDIR}/farview.service ${D}${systemd_system_unitdir} > > > > } > > > > > > > > FILES:{PN} += "${systemd_system_unitdir}/farview.service" > > > > REQUIRED_DISTRO_FEATURES = " systemd " > > > -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#62142): https://lists.yoctoproject.org/g/yocto/message/62142 Mute This Topic: https://lists.yoctoproject.org/mt/103724054/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] EXTRA_USERS_PARAMS doesn't work to generate password for root and add new users
On Tue, Aug 29, 2023 at 03:08 AM, Mauro wrote: > > extrauser class is designed to add or modify users at image level, then it > must be used in image recipes or in a .conf file. [1] > > useradd class is designed to create users at package level, then it must > be used in normal (not image) recipes only. [2] > > [1] https://docs.yoctoproject.org/ref-manual/classes.html#extrausers > [2] https://docs.yoctoproject.org/ref-manual/classes.html#useradd Thanks Manro for sharing these links. Now I see a big pool of classes that can be used. Eventually I found that why it doesn't work for me to add EXTRA_USER_PARAMS in image recipe is that I used this line: INHERIT += "extrausers" instead of this line: inherit extrausers to use the class extrausers. But at the beginning there was an error when using "inherit extrauser". Now it works fine. I couldn't figure out why. But anyway it works this way now. Regards, Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60924): https://lists.yoctoproject.org/g/yocto/message/60924 Mute This Topic: https://lists.yoctoproject.org/mt/100887124/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] EXTRA_USERS_PARAMS doesn't work to generate password for root and add new users
On Thu, Aug 24, 2023 at 04:21 AM, Mauro wrote: > > To Crane: please try to build the image and test it, don't stop at Yocto > variables analysis step. Thanks Mauro so much. Indeed, it is not relevant the value of the variable, but where it is assigned. It doesn't work to assign these values in image recipe, but works in local.conf. I am wondering what's the different in assigning the value in different locations. Maybe it is relevant to the building sequence. If it is assigned later, it is useless. Is there any rule to follow? Or it is just from experience? Another question I think of is how you guys source control local.conf. It looks it might be much different from project to project. Thanks! Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60896): https://lists.yoctoproject.org/g/yocto/message/60896 Mute This Topic: https://lists.yoctoproject.org/mt/100887124/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] EXTRA_USERS_PARAMS doesn't work to generate password for root and add new users
On Wed, Aug 23, 2023 at 03:45 AM, Mauro wrote: > > You can put the encrypted password (the result of the "openssl passwd -6 > root" command) directly in the variable, taking care to put a "\" before > the three "$" contained in the string. Something like this: > > EXTRA_USERS_PARAMS=" usermod -p > '\$6\$CEM0hANiVS9VXN8N\$Q9XK1KTpq2faq2fNbSRLNeeA4mmQsl8g1Gwl3QnTPlRPb5ljCAa./bbhffcthXxUen4jSFL6HKGQPlHZNQkfA/' > root; useradd -p > '\$6\$5wVybJkbuowR0iMi\$tnEJEEbXbcRfksKRSt7rjlY1hRERrjqFOlCaa0s1ivISxAHT7MFdcnZvVbRHgkqRSYzA1oLUxtR0LuvDTMPR5/' > crane; " Tried as well. And a \ is added automatically in front of $, so no need to add it. But still not working. There must be something else missing. Anyway to debug in this case? -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60858): https://lists.yoctoproject.org/g/yocto/message/60858 Mute This Topic: https://lists.yoctoproject.org/mt/100887124/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] EXTRA_USERS_PARAMS doesn't work to generate password for root and add new users
On Tue, Aug 22, 2023 at 11:36 AM, Mauro wrote: > > Try with this: > > EXTRA_USERS_PARAMS=" usermod -p '$(openssl passwd -6 root)' root; useradd > -p '$(openssl passwd -6 2023)' crane; " Not working. Here is the value of the variable becoming: EXTRA_USERS_PARAMS=" usermod -p '\$(openssl passwd -6 root)' root; useradd -p '\$(openssl passwd -6 2023)' crane; " One \ is added before $ symbol. -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60853): https://lists.yoctoproject.org/g/yocto/message/60853 Mute This Topic: https://lists.yoctoproject.org/mt/100887124/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] EXTRA_USERS_PARAMS doesn't work to generate password for root and add new users
Here is the variable value: EXTRA_USERS_PARAMS=" usermod -p 'openssl passwd -6 root' root; useradd -p 'openssl passwd -6 2023' crane; " Actually no need to add \ before $ symbol. \ is already added as below: EXTRA_USERS_PARAMS=" usermod -p '\$6\$9UMdfjsa9kYD4oQB\$a3jUptBObMgh8palvzovMriEp8X0d/7xHHOj7WdcBKXvhcUvOBOzFTAdl3.NDi.CGwMtpwfB3J6dvxRQN.iUq.' root; useradd -p '\$6\$IfrdWN4tMhCHSL6E\$NS3/r/qO3kSKNh0PVtqmrocLAxbdkUZu3cYg7czkMy9Y42le02G92hgxRVvsFogjCufY4BRdjRdaW77K/kT170' crane; " -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60851): https://lists.yoctoproject.org/g/yocto/message/60851 Mute This Topic: https://lists.yoctoproject.org/mt/100887124/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] EXTRA_USERS_PARAMS doesn't work to generate password for root and add new users
Thanks Mauro for your input. I referred two posts from Koan Software in my work. One is to use devtool to modify recipe and another one is to add system service to image. Very clearly explained. Thanks! Good point. I tried, but in my case it looks still not generating the password and also no new user added. And I am afraid that the $ symbol in the encrypted password string might prevent it from being applied. I tried to add \ before $ symbol. And it's also not working. Wondering what else might be still missing. -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60850): https://lists.yoctoproject.org/g/yocto/message/60850 Mute This Topic: https://lists.yoctoproject.org/mt/100887124/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[yocto] EXTRA_USERS_PARAMS doesn't work to generate password for root and add new users
Hello, I am trying to generate a password for root and add a new user. Here is the code in the image recipe: IMAGE_FEATURES:remove = "debug-tweaks" INHERIT += "extrausers" EXTRA_USERS_PARAMS += "usermod -P root root; useradd -P 2023 crane" When using "inherit extrausers", there is an error of "usermod command did not succeed." When checking the parameter, the result is: EXTRA_USERS_PARAMS=" usermod -P root root; useradd -P 2023 crane; " The image does requires a password for root, but doesn't generate anything in /etc/shadow and doesn't add new user in /etc/shadow as well. I am wondering what might be missing. Can anyone give me any clue? Thanks! Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60846): https://lists.yoctoproject.org/g/yocto/message/60846 Mute This Topic: https://lists.yoctoproject.org/mt/100887124/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
Finally find the correct way to do that. Do "bitbake -c devshell " and then in the folder created use "git format-patch" to create the patch file. This way, the patch can be applied. -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60827): https://lists.yoctoproject.org/g/yocto/message/60827 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
You mean S folder? Yes, to be specific, it is S folder. The reason I just mentioned WORKDIR was to compare with the irrelevant folder where "diff -ruN" is used to create the patch. Or you mean something else? -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60754): https://lists.yoctoproject.org/g/yocto/message/60754 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
Now the issue is with the patch itself. The patch is created by using "diff -ruN" is not working. The error is "no file to patch". I can understand this as the file compared to in the patch doesn't exist in the $(WORKDIR). I changed to use "git format-patch" in the $(WORKDIR) to generate the patch. But still not working. The error is "does not apply (enforce with -f)". And applying -f option got the same error. Where is the problem? The way to create the patch or apply the patch. -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60748): https://lists.yoctoproject.org/g/yocto/message/60748 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
Thanks Raj! I forgot where I copied this piece of code. I just copied and didn't check and believed it. This is the problem! -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60747): https://lists.yoctoproject.org/g/yocto/message/60747 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
Thanks Daniel for your input. Yes I tried and it works to find the patch now. It should be in curly braces. I am wondering why it couldn't be identified by checking the environment FILESEXTRAPATHS. Not matter round braces or curly braces are used, the value of this variable keeps the same as below: crane@Ubuntu2204:~/yocto-pi/build$ bitbake -e farview-image-base | grep ^FILESEXTRAPATHS= FILESEXTRAPATHS="__default:" crane@Ubuntu2204:~/yocto-pi/build$ bitbake -e farview-image-base | grep ^FILESEXTRAPATHS= FILESEXTRAPATHS="__default:" crane@Ubuntu2204:~/yocto-pi/build$ -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60744): https://lists.yoctoproject.org/g/yocto/message/60744 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
crane@Ubuntu2204:~/yocto-pi/sources/meta-farview/recipes-bsp/bootfiles$ ls files rpi-config_git.bbappend crane@Ubuntu2204:~/yocto-pi/sources/meta-farview/recipes-bsp/bootfiles$ ls files/ 0001-disable-bluetooth-and-enable-uart0.patch rpi-cmdline.patch rpi-config.patch crane@Ubuntu2204:~/yocto-pi/sources/meta-farview/recipes-bsp/bootfiles$ -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60742): https://lists.yoctoproject.org/g/yocto/message/60742 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
The error is this when bitbaking only the recipe for rpi-config: "WARNING: rpi-config-git-r5 do_fetch: Failed to fetch URL file://0001-disable-bluetooth-and-enable-uart0.patch, attempting MIRRORS if available ERROR: rpi-config-git-r5 do_fetch: Fetcher failure: Unable to find file file://0001-disable-bluetooth-and-enable-uart0.patch anywhere. The paths that were searched were: " The listed searching paths don't include the custom layer where the patch is placed. The complete error info is in the attached file "bitbake rpi-config.txt". When bitbaking the recipe for the image, the error is the same. The complete error info is in attached file "bitbake image.txt". crane@Ubuntu2204:~/yocto-pi/build$ bitbake rpi-config Loading cache: 100% |#| Time: 0:00:00 Loaded 1681 entries from dependency cache. WARNING: /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config_git.bb: Unable to get checksum for rpi-config SRC_URI entry 0001-disable-bluetooth-and-enable-uart0.patch: file could not be found Parsing recipes: 100% |###| Time: 0:00:00 Parsing of 919 .bb files complete (918 cached, 1 parsed). 1680 targets, 74 skipped, 0 masked, 0 errors. NOTE: Resolving any missing task queue dependencies Build Configuration: BB_VERSION = "2.0.0" BUILD_SYS= "x86_64-linux" NATIVELSBSTRING = "universal" TARGET_SYS = "arm-poky-linux-gnueabi" MACHINE = "farview-rpi3" DISTRO = "poky" DISTRO_VERSION = "4.0.11" TUNE_FEATURES= "arm vfp cortexa7 neon vfpv4 thumb callconvention-hard" TARGET_FPU = "hard" meta meta-poky meta-yocto-bsp = "kirkstone:cc3287637c30080333d89a368e40473dfffb2fb7" meta-raspberrypi = "kirkstone:43683cb14b6afc144619335b3a2353b70762ff3e" meta-farview = "master:7443f88de16e764173d0103474066d2af2138af2" Initialising tasks: 100% || Time: 0:00:00 Sstate summary: Wanted 4 Local 0 Mirrors 0 Missed 4 Current 36 (0% match, 90% complete) Removing 4 stale sstate objects for arch farview_rpi3: 100% |#| Time: 0:00:00 NOTE: Executing Tasks WARNING: rpi-config-git-r5 do_fetch: Failed to fetch URL file://0001-disable-bluetooth-and-enable-uart0.patch, attempting MIRRORS if available ERROR: rpi-config-git-r5 do_fetch: Fetcher failure: Unable to find file file://0001-disable-bluetooth-and-enable-uart0.patch anywhere. The paths that were searched were: $(THISDIR)/files/poky /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config-git/poky /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config/poky /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/files/poky $(THISDIR)/files/farview-rpi3 /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config-git/farview-rpi3 /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config/farview-rpi3 /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/files/farview-rpi3 $(THISDIR)/files/raspberrypi3 /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config-git/raspberrypi3 /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config/raspberrypi3 /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/files/raspberrypi3 $(THISDIR)/files/armv7ve /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config-git/armv7ve /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config/armv7ve /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/files/armv7ve $(THISDIR)/files/rpi /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config-git/rpi /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config/rpi /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/files/rpi $(THISDIR)/files/arm /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config-git/arm /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config/arm /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/files/arm $(THISDIR)/files/ /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config-git/ /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/rpi-config/ /home/crane/yocto-pi/sources/meta-raspberrypi/recipes-bsp/bootfiles/files/ /home/crane/yocto-pi/build/downloads ERROR: r
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
The recipe append name I used is rpi-config_git.bbappend. It is placed in meta-custom/recipes-bsp/bootfiles/ The layer conf of the custom layer is like this: # We have a conf and classes directory, add to BBPATH BBPATH .= ":${LAYERDIR}" # We have recipes-* directories, add to BBFILES BBFILES += "${LAYERDIR}/recipes-*/*/*.bb \ ${LAYERDIR}/recipes-*/*/*.bbappend" BBFILE_COLLECTIONS += "meta-farview" BBFILE_PATTERN_meta-farview = "^${LAYERDIR}/" BBFILE_PRIORITY_meta-farview = "19" LAYERDEPENDS_meta-farview = "core" LAYERSERIES_COMPAT_meta-farview = "kirkstone" -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60731): https://lists.yoctoproject.org/g/yocto/message/60731 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
Thanks Raj for your quick reply. For config.txt, the recipe I am referring to is rpi-config_git.bb in meta-respberrypi layer. This is the one I am testing now. Further on, I will add recipe appends for rpi-cmdline.bb. To change /etc/inittab, I still need to find which recipe to append. Thanks! Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60729): https://lists.yoctoproject.org/g/yocto/message/60729 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[yocto] How to add a few lines in config.txt in Yocto project for Raspberry Pi
Hello, I would like to write a .bbappend for config.txt, cmdline.txt and /etc/inittab in my custom layer to make some changes. The recipe append for config.txt is created like this: FILESEXTRAPATHS:prepend := "$(THISDIR)/files:" SRC_URI += "file://rpi-config.patch" The paths of the recipe and patch are in the custom layer's bblayer.conf. But Bitbake doesn't search the custom layer for the recipe append. Is it a proper way to do that? If yes, what might be missing in the configuration? Thanks! Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60727): https://lists.yoctoproject.org/g/yocto/message/60727 Mute This Topic: https://lists.yoctoproject.org/mt/100614184/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] the way to create patch for Linux kernel configuration
Finally found two ways to do this and worked in my case: 1. use bitbake -c diffconfig to create a fragment config and then add the fragment config to a .bbappend 2. add an out-of-tree defconfig in .bb The documentation says out-of-tree defconfig takes precedence. But in my case KBUILD_DEFCONFIG is used and the out-of-tree defconfig is dropped. No idea why. I have to use KBUILD_DEFCONFIG:remove to clear it. -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60717): https://lists.yoctoproject.org/g/yocto/message/60717 Mute This Topic: https://lists.yoctoproject.org/mt/100557707/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[yocto] the way to create patch for Linux kernel configuration
Hello, How do you create a patch for Linux kernel configuration in a customized layer on top of an initial patch. It is a patch based on the original defconfig from vendor meta layer? I tried different ways, but none of them work. The initial .bbappend is like this. I would like to make further changes on top of that. SRCREV = "0086da6acd41600d47b87b05874f99704216426f" FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" SRC_URI += "\ file://devtool-fragment.cfg \ " 1. use devtool to modify the current kernel configuration After using devtool menuconfig to modify the kernel configuration, the .config is updated. But, here is a big BUT, after using devtool build to build kernel image, the kernel image is still built using the defconfig originally from the vendor meta layer meta-raspberrypi. If using devtool update-recipe to create a patch any way, then do devtool reset and use bitbake to build the kernel image, the result is the same (the kernel image uses original defconfig). 2. use git format-patch to create a patch file and then add the patch file into .bbappend. Say, a patch 0001-update-kernel-config-to-enable-uart-console.patch is added into files folder. Then add one line in .bbappend file like this: SRCREV = "0086da6acd41600d47b87b05874f99704216426f" FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" SRC_URI += "\ file://devtool-fragment.cfg \ file://0001-update-kernel-config-to-enable-uart-console.patch \ " But this way, the patch couldn't be applied at all. An error is caused. 3. Tried to use git to create a patch in different folder Most of tries got the same result. One of them seems applied. But from the result, it is actually not applied. So, which way should work? Anything missing in what I did. Thanks for your help! Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60712): https://lists.yoctoproject.org/g/yocto/message/60712 Mute This Topic: https://lists.yoctoproject.org/mt/100557707/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
Re: [yocto] Yocto on Raspberry Pi 3: Error when building image from a machine conf in a new layer
Yes it work. It looks simply copying the contents to the new one doesn't work. Thanks! Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60702): https://lists.yoctoproject.org/g/yocto/message/60702 Mute This Topic: https://lists.yoctoproject.org/mt/100519055/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-
[yocto] Yocto on Raspberry Pi 3: Error when building image from a machine conf in a new layer
Hello, I am using Yocto to build a image for Raspberry Pi 3. I don't see a specific group for RaspberryPi and hope to get help from here. I am using Kirkstone commit and didn't download meta-openembedded as it doesn't say it is needed in README. And it works to build a image. Now I would like to add a new machine in the my customized layer to make some changes based on the original machine configuration. So I copied raspberrypi3.conf from meta-raspberrypi to my new layer first. But bitbake displays errors as below: === crane@Ubuntu2204:~/yocto-pi/build$ bitbake -k farview-image-base Loading cache: 100% |#| Time: 0:00:00 Loaded 657 entries from dependency cache. WARNING: /home/crane/yocto-pi/sources/poky/meta/recipes-extended/images/core-image-testcontroller.bb: Exception during build_dependencies for IMAGE_BOOT_FILES WARNING: /home/crane/yocto-pi/sources/poky/meta/recipes-extended/images/core-image-testcontroller.bb: Error during finalise of /home/crane/yocto-pi/sources/poky/meta/recipes-extended/images/core-image-testcontroller.bb ERROR: ExpansionError during parsing /home/crane/yocto-pi/sources/poky/meta/recipes-extended/images/core-image-testcontroller.bb Traceback (most recent call last): File "Var ", line 1, in File "/home/crane/yocto-pi/sources/meta-raspberrypi/conf/machine/include/rpi-base.inc", line 134, in make_dtb_boot_files(d=): > return ' '.join([transform(dtb) for dtb in alldtbs.split(' ') if dtb]) bb.data_smart.ExpansionError: Failure expanding variable IMAGE_BOOT_FILES, expression was bootfiles/* ${@make_dtb_boot_files(d)} ${@bb.utils.contains('RPI_USE_U_BOOT', '1', 'zImage u-boot.bin;kernel7.img boot.scr', 'zImage;kernel7.img', d)} which triggered exception TypeError: sequence item 61: expected str instance, NoneType found The variable dependency chain for the failure is: IMAGE_BOOT_FILES ERROR: Parsing halted due to errors, see error messages above Summary: There were 2 WARNING messages. Summary: There were 2 ERROR messages, returning a non-zero exit code. crane@Ubuntu2204:~/yocto-pi/build$ = I don't understand why it tries to parse core-image-testcontroller.bb, which I don't intentionally use at all. I am afraid that the process to create a new machine is not correct. Does anyone can help with understanding what is missing here? Or it is not the correct way to create a new machine for raspberrypi? Thanks! Crane -=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#60700): https://lists.yoctoproject.org/g/yocto/message/60700 Mute This Topic: https://lists.yoctoproject.org/mt/100519055/21656 Group Owner: yocto+ow...@lists.yoctoproject.org Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-