Yocto Realsense Building - yocto

I'm trying to build a Yocto Hardknott image with Realsense layer for IMX8MP board (Hummingboard Mate). I have received this error:
ERROR: librealsense2-2.44.0-r0 do_package: QA Issue: librealsense2:
Files/directories were installed but not shipped in any package:
/home /home/ubuntu /home/ubuntu/Documents
/home/ubuntu/Documents/librealsense2
/home/ubuntu/Documents/librealsense2/presets
/home/ubuntu/Documents/librealsense2/presets/L535 Max Range.preset
/home/ubuntu/Documents/librealsense2/presets/L535 Max Range With
Binning.preset /home/ubuntu/Documents/librealsense2/presets/L535
Medium Range.preset
/home/ubuntu/Documents/librealsense2/presets/L535 Min Range.preset
/usr/bin/rs-embed Please set FILES such that these items are packaged.
Alternatively if they are unneeded, avoid installing them or delete
them within do_install. librealsense2: 10 installed and not shipped
files. [installed-vs-shipped] ERROR: librealsense2-2.44.0-r0
do_package: Fatal QA errors found, failing task. ERROR: Logfile of
failure stored in:
/home/ubuntu/yocto_hardknott_realsense/build-xwayland-imx8mpsolidrun/tmp/work/cortexa53-crypto-poky-linux/librealsense2/2.44.0-r0/temp/log.do_package.110367
ERROR: Task
(/home/ubuntu/yocto_hardknott_realsense/sources/meta-intel-realsense/recipes-support/librealsense/librealsense2_2.44.0.bb:do_package)
failed with exit code '1'
I have used this solution:
FILES_${PN} += "${home}/*"
FILES_${PN}-dev = "${home}/* ${includedir}"
from this thread:
Yocto - Files/directories were installed but not shipped in any package
But the error is bigger:
ERROR: librealsense2-2.44.0-r0 do_package: QA Issue: librealsense2:
Files/directories were installed but not shipped in any package:
/home /home/ubuntu /home/ubuntu/Documents
/home/ubuntu/Documents/librealsense2
/home/ubuntu/Documents/librealsense2/presets
/home/ubuntu/Documents/librealsense2/presets/L535 Max Range.preset
/home/ubuntu/Documents/librealsense2/presets/L535 Max Range With
Binning.preset /home/ubuntu/Documents/librealsense2/presets/L535
Medium Range.preset
/home/ubuntu/Documents/librealsense2/presets/L535 Min Range.preset
/usr/lib/librealsense2.so /usr/lib/librealsense2-gl.so
/usr/lib/pkgconfig /usr/lib/cmake /usr/lib/pkgconfig/realsense2.pc
/usr/lib/pkgconfig/realsense2-gl.pc /usr/lib/cmake/realsense2
/usr/lib/cmake/realsense2-gl
/usr/lib/cmake/realsense2/realsense2ConfigVersion.cmake
/usr/lib/cmake/realsense2/realsense2Targets-noconfig.cmake
/usr/lib/cmake/realsense2/realsense2Targets.cmake
/usr/lib/cmake/realsense2/realsense2Config.cmake
/usr/lib/cmake/realsense2-gl/realsense2-glConfigVersion.cmake
/usr/lib/cmake/realsense2-gl/realsense2-glTargets.cmake
/usr/lib/cmake/realsense2-gl/realsense2-glConfig.cmake
/usr/lib/cmake/realsense2-gl/realsense2-glTargets-noconfig.cmake
/usr/bin/rs-embed Please set FILES such that these items are packaged.
Alternatively if they are unneeded, avoid installing them or delete
them within do_install. librealsense2: 26 installed and not shipped
files. [installed-vs-shipped] ERROR: librealsense2-2.44.0-r0
do_package: Fatal QA errors found, failing task. ERROR: Logfile of
failure stored in:
/home/ubuntu/yocto_hardknott_realsense/build-xwayland-imx8mpsolidrun/tmp/work/cortexa53-crypto-poky-linux/librealsense2/2.44.0-r0/temp/log.do_package.128195
ERROR: Task
(/home/ubuntu/yocto_hardknott_realsense/sources/meta-intel-realsense/recipes-support/librealsense/librealsense2_2.44.0.bb:do_package)
failed with exit code '1'
Where is the problem of this?
Thank you so much.
EDIT:
For this case:
FILES_${PN} += "$/home/* /usr/*"
Adding this line solves the error, my mistake, I didn't understand the command.

For this case:
FILES_${PN} += "$/home/* /usr/*"
Adding this line solves the error, my mistake, I didn't understand the command.

Related

NixOS - Issue packaging neovim plugin from github

I'm trying to add a neovim plugin that doesn't exist in nixpkgs yet (modes.nvim), but having trouble getting it to work.
I'm using NixOS 22.05, and Home Manager, and I am using the following to build this plugin:
pkgs.vimUtils.buildVimPlugin {
name = "modes-nvim";
src = pkgs.fetchFromGitHub {
owner = "mvllow";
repo = "modes.nvim";
rev = "3188692abf02a8838ec75e59d68c2ce3e4323f5c";
sha256 = "sha256-2QDpwQ9+F5t5gTR1KLVzRrvriwo5JUHatZEJnc0ojV8=";
};
}
Initially, I used lib.pkgs.fakeSha256 to get a "mismatched hash" error, and copy/pasted the has from that error message, so I think it's correct, though other things I've seen on the internet seem to have the SHA256 as a hex string, so not sure what's going on there.
When I run home-manager switch, I get the following error:
these 12 derivations will be built:
/nix/store/pna2lzjc3q56z59b2kfazzxi8m6swp8d-vimplugin-modes-nvim.drv
/nix/store/mnj1d881d8s57yj3y8wjy7i9nl3m089f-vimplugin-modes-nvim.drv
/nix/store/5l8vqvx2bbawkkj92s8qd0p5hw16pcmq-vim-pack-dir.drv
/nix/store/jgqf68sd50s79pydzs9154p509l5109v-hm_nviminit.vim.drv
/nix/store/rq8f75qr9ahrfr0hvp51inn19088bz5p-manifest.vim.drv
/nix/store/hbzm2xr6nv8mr2l9nrlf742fqdmw9nv3-neovim-0.7.2.drv
/nix/store/zks47ifk7njz1s8y7hvq357ac8z6azkd-neovim-0.7.2-fish-completions.drv
/nix/store/rkaa094vvyjcyy4v1zkh4f8xz64vqxas-cameron-fish-completions.drv
/nix/store/0073403x9b4wv13gm7a6bqy4765pi8g5-home-manager-files.drv
/nix/store/lxwpbhb6ryhwrff4cjyniff11843cf9x-home-manager-path.drv
/nix/store/xbbn44253wjh90md4hqrrc2wfpafkc55-activation-script.drv
/nix/store/ijwmv897xc2wlr1ij4a30vk4z154ikbf-home-manager-generation.drv
building '/nix/store/pna2lzjc3q56z59b2kfazzxi8m6swp8d-vimplugin-modes-nvim.drv'...
Sourcing vim-command-check-hook.sh
Using vimCommandCheckHook
Sourcing vim-gen-doc-hook
unpacking sources
unpacking source archive /nix/store/fcxyif8piqar9w9ynmi6ym71hw6zsy7a-source
source root is source
patching sources
configuring
no configure script, doing nothing
building
build flags: SHELL=/nix/store/iffl6dlplhv22i2xy7n1w51a5r631kmi-bash-5.1-p16/bin/bash
test -r dependencies/pack/vendor/start/plenary.nvim || git clone --depth=1 https://github.com/nvim-lua/plenary.nvim.git dependencies/pack/vendor/start/plenary.nvim
/nix/store/iffl6dlplhv22i2xy7n1w51a5r631kmi-bash-5.1-p16/bin/bash: line 1: git: command not found
make: *** [Makefile:7: install_dependencies] Error 127
error: builder for '/nix/store/pna2lzjc3q56z59b2kfazzxi8m6swp8d-vimplugin-modes-nvim.drv' failed with exit code 2;
last 10 log lines:
> unpacking source archive /nix/store/fcxyif8piqar9w9ynmi6ym71hw6zsy7a-source
> source root is source
> patching sources
> configuring
> no configure script, doing nothing
> building
> build flags: SHELL=/nix/store/iffl6dlplhv22i2xy7n1w51a5r631kmi-bash-5.1-p16/bin/bash
> test -r dependencies/pack/vendor/start/plenary.nvim || git clone --depth=1 https://github.com/nvim-lua/plenary.nvim.git dependencies/pack/vendor/start/plenary.nvim
> /nix/store/iffl6dlplhv22i2xy7n1w51a5r631kmi-bash-5.1-p16/bin/bash: line 1: git: command not found
> make: *** [Makefile:7: install_dependencies] Error 127
For full logs, run 'nix log /nix/store/pna2lzjc3q56z59b2kfazzxi8m6swp8d-vimplugin-modes-nvim.drv'.
error: 1 dependencies of derivation '/nix/store/mnj1d881d8s57yj3y8wjy7i9nl3m089f-vimplugin-modes-nvim.drv' failed to build
error: 1 dependencies of derivation '/nix/store/5l8vqvx2bbawkkj92s8qd0p5hw16pcmq-vim-pack-dir.drv' failed to build
error: 1 dependencies of derivation '/nix/store/jgqf68sd50s79pydzs9154p509l5109v-hm_nviminit.vim.drv' failed to build
error: 1 dependencies of derivation '/nix/store/rq8f75qr9ahrfr0hvp51inn19088bz5p-manifest.vim.drv' failed to build
error: 1 dependencies of derivation '/nix/store/0073403x9b4wv13gm7a6bqy4765pi8g5-home-manager-files.drv' failed to build
error: 1 dependencies of derivation '/nix/store/hbzm2xr6nv8mr2l9nrlf742fqdmw9nv3-neovim-0.7.2.drv' failed to build
error: 1 dependencies of derivation '/nix/store/ijwmv897xc2wlr1ij4a30vk4z154ikbf-home-manager-generation.drv' failed to build
It appears to be failing due to git not being found. Of course, I have git installed for me, but perhaps this command is being run in an environment that doesn't have access to my installed packages.
I'm very new to Nix and NixOS, so I'm not really sure how to begin fixing this issue. I've searched online for answers, but haven't found anything about this issue. Any advice is much appreciated.

How to solve error on docker:layers_calculator to compute the Merkle tree on private tangle?

I want to setup a private tangle on my own virtual machine with Ubuntu 18.04, 4GB RAM and 20GB memory.
I have follow this instructions: https://docs.iota.org/docs/compass/0.1/how-to-guides/set-up-a-private-tangle. Every command works fine until reach this one: bazel run //docker:layers_calculator.
It shows an error as follows:
Starting local Bazel server and connecting to it...
ERROR: /home/istabraq/compass/third-party/maven_deps.bzl:3:5: Traceback (most recent call last):
File "/home/istabraq/compass/WORKSPACE", line 42
maven_jars()
File "/home/istabraq/compass/third-party/maven_deps.bzl", line 3, in maven_jars
native.maven_jar(<4 more arguments>)
type 'struct' has no method maven_jar()
ERROR: error loading package '': Encountered error while reading extension file 'protobuf_deps.bzl': no such package '#com_google_protobuf_deps//': error loading package 'external': Could not load //external package
ERROR: error loading package '': Encountered error while reading extension file 'protobuf_deps.bzl': no such package '#com_google_protobuf_deps//': error loading package 'external': Could not load //external package
INFO: Elapsed time: 4.743s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded)
FAILED: Build did NOT complete successfully (0 packages loaded)
How can I solve this problem? what I have missed?
read carefully the message given after running bazel installer:
Make sure you have "/home/yourusername/bin" in your path. You can also activate bash completion by adding the following line to your :
source /home/yourusername/.bazel/bin/bazel-complete.bash
You can check with: "bazel info" or "bazel version"
Unfortunately, there are further errors:
https://github.com/iotaledger/compass/issues/142
I have solve this issue by using this commands:
Step 3: Set up your environment
If you ran the Bazel installer with the --user flag as above, the Bazel executable is installed in your $HOME/bin directory. It’s a good idea to add this directory to your default paths, as follows:
export PATH="$PATH:$HOME/bin"
You can also add this command to your ~/.bashrc or ~/.zshrc file to make it permanent.
reference:
https://docs.bazel.build/versions/master/install-ubuntu.html

SYSTEMD_SERVICE_swupdate value swupdate.service does not exist

I am trying to build swupdate image by running bitbake swupdate-image but getting following errors,
ERROR: swupdate-2019.04-r0 do_package: SYSTEMD_SERVICE_swupdate value swupdate.service does not exist
ERROR: swupdate-2019.04-r0 do_package:
ERROR: swupdate-2019.04-r0 do_package: Function failed: systemd_populate_packages
ERROR: Logfile of failure stored in: /home/panther2/warrior/build/tmp/work/corei7-64-poky-linux/swupdate/2019.04-r0/temp/log.do_package.22017
ERROR: Task (/home/panther2/warrior/sources/meta-swupdate/recipes-support/swupdate/swupdate_2019.04.bb:do_package) failed with exit code '1'
I am building for warrior yocto branch. Error indicates that swupdate.service does not exist but swupdate.service does exist under meta-swupdate/recipes-support/swupdate/swupdate. Any help is really appreciated. Thanks for your time.
swupdate-image is a rescue system - it generates a Ramdisk. Care was taken about footprint - it runs then with SystemV and not with systemd. If you want to buid swupdate-image with systemd as init, add your own swupdate-image.bbappend and rearrange the list of packages.

QA Issue: libvncserver: Files/directories were installed but not shipped in any package:

While generating sato image by bitbake core-iamge-sato, I am getting following errors
ERROR: libvncserver-0.9.12+gitAUTOINC+c0a23857a5-r0 do_package: QA Issue: libvncserver: Files/directories were installed but not shipped in any package:
/usr/lib/libvncclient.so
/usr/lib/libvncserver.so
/usr/lib/libvncserver.so.1
/usr/lib/libvncclient.so.0.9.12
/usr/lib/libvncclient.so.1
/usr/lib/libvncserver.so.0.9.12
/usr/lib/pkgconfig
/usr/lib/pkgconfig/libvncclient.pc
/usr/lib/pkgconfig/libvncserver.pc
Please set FILES such that these items are packaged. Alternatively if they are unneeded, avoid installing them or delete them within do_install.
libvncserver: 9 installed and not shipped files. [installed-vs-shipped]
ERROR: libvncserver-0.9.12+gitAUTOINC+c0a23857a5-r0 do_package: Fatal QA errors found, failing task.
ERROR: libvncserver-0.9.12+gitAUTOINC+c0a23857a5-r0 do_package:
ERROR: libvncserver-0.9.12+gitAUTOINC+c0a23857a5-r0 do_package: Function failed: do_package
ERROR: Logfile of failure stored in: /home/panther2/warrior/build/tmp/work/corei7-64-poky-linux/libvncserver/0.9.12+gitAUTOINC+c0a23857a5-r0/temp/log.do_package.101719
ERROR: Task (/home/panther2/warrior/sources/meta-openembedded/meta-oe/recipes-graphics/libvncserver/libvncserver_git.bb:do_package) failed with exit code '1'
I am building for warrior branch. As a solution I tried adding following lines in libvncserver_git.bb but nothing worked out. Can anyone help?
FILES_${PN} += " \
${libdir}/libvncclient.so \
${libdir}/libvncserver.so \
${libdir}/libvncserver.so.1 \
${libdir}/libvncclient.so.0.9.12 \
${libdir}/libvncclient.so.1 \
${libdir}/libvncserver.so.0.9.12 \
${libdir}/pkgconfig \
${libdir}/pkgconfig/libvncclient.pc \
${libdir}/pkgconfig/libvncserver.pc \
"
Thank you for your time.
Background: you're using a configuration where $libdir isn't /usr/lib (multilib, probably) but the upstream doesn't care and installs to /usr/lib anyway, which is a bug upstream.
As suggested in comment, I have resolved the error by replacing recipe file from master branch(libvncserver_0.9.12.bb). I was using warrior branch recipe libvncserver_git.bb which causes error.

Failed do_rootfs for agl-demo-platform

I am building Yocto for AGL image (for more details: automotivelinux.org).
The below error occurred during the build progress (do_rootfs).
In packagegroup-agl-demo-platform.bb, declared packagegroup-agl-image-ivi as a runtime dependent package.
RDEPENDS_${PN} += "\
packagegroup-agl-image-ivi \
"
I can build successfully the packagegroup-agl-image-ivi separately. But when building the whole agl-demo-platform image, happened as follows:
ERROR: agl-demo-platform-1.0-r0 do_rootfs: Unable to install packages. Command '/LTSI4.9/LTSI4.4/build/tmp/work/m3ulcb-agl-linux/agl-demo-platform/1.0-r0/opkg.conf -t /LTSI4.9/build/tmp/work/m3ulcb-agl-linux/agl-demo-platform/1.0-r0/temp/ipktemp/ -o /LTSI4.9/build/tmp/work/m3ulcb-agl-linux/agl-demo-platform/1.0-r0/rootfs --force_postinstall --prefer-arch-to-version install
run-postinsts
screen
kernel-modules
packagegroup-agl-devel
packagegroup-core-eclipse-debug
mc packagegroup-core-tools-profile
kernel-module-vsp2 kernel-module-pvrsrvkm
kernel-module-vspm-if
opkg packagegroup-core-tools-debug
psplash kernel-module-vspm
packagegroup-core-ssh-openssh
packagegroup-agl-demo-platform
omx-user-module kernel-devicetree'
returned 1:
Solver encountered 1 problem(s):
Problem 1/1:
- package packagegroup-agl-demo-platform-1.0-r0.all requires packagegroup-agl-image-ivi, but none of the providers can be installed
Solution 1:
- do not ask to install a package providing packagegroup-agl-demo-platform
ERROR: agl-demo-platform-1.0-r0 do_rootfs: Function failed: do_rootfs
ERROR: Logfile of failure stored in: /LTSI4.9/build/tmp/work/m3ulcb-agl-linux/agl-demo-platform/1.0-r0/temp/log.do_rootfs.14498
ERROR: Task (/LTSI4.9/meta-agl-demo/recipes-platform/images/agl-demo-platform.bb:do_rootfs) failed with exit code '1'
Can anyone help me out in this case ?
I tried 02 ways as follows. They did work.
First method, I cleaned all relative packages and rebuild the whole image.
$ bitbake -c cleanall -c cleansstate <recipes>
recipes consisted of all dependent & runtime dependent packages. But it was a little bit confused to inexperienced users to determine which ones.
Second method, I wiped out the build/tmp/, cache/, sstate-cache/ folders, and re-build all Yocto packages.
There were nothing happening any more. It was really a bad idea if be in critical period of time, but if have free time, be helpful.