Re: How to use two recipes to satisfy different PROVIDES -- gpu support
Gutierrez, Hernan Ildefonso (Boise R&D, FW) <hernan_gutierrez@...>
Raj,
toggle quoted messageShow quoted text
Thanks for your response. I figured two issues I had in my original recipe. (after your response and other queries I did) a) virtual/libgl is not provided by my recipe, and I was claiming to provide it. b) I read that mesa has to provide some of the libraries, even if you have a GPU, so I added DEPENDS += "mesa" c) I also found that there is a way to remove the conflicts in the provide by doing a patch to mesa, (mesa_%.bbappend) and inside that recipe, you can do a PROVIDES_remove += "virtual/ligegl .... etc." Thanks, --Hernan
-----Original Message-----
|
|
raspberrypi3 static library linking
fwag
Hello everyone, I'm using a raspberry pi 3 with meta-raspberrypi meta layer. I have created a meta-layer (meta-kp) with two recipes directories:
My layer can be downloaded here: meta-kp I've added in IMAGE_INSTALL_append both the recipe pifacedigital and helloworldstatic. I'm able to compile the image rpi-basic-image, but after booting the image if I try to execute the application pifacedigital_cmd it prompts out the following error: Instead helloworldstatic (recipes-example) binary properly works. Have you ever faced some similar issue ? Thanks in advance for your help
|
|
aarch64-poky-linux-gcc error during compilation
vaishnavi tn <send2meena@...>
Hello,
I am trying to include mlpack (with python bindings) to my yocto build. I get the following error while building the python bindings: =========================================== aarch64-poky-linux-gcc -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -O2 -pipe -g -feliminate-unused-debug-types -fPIC -I/builds/build-h3/tmp/sysroots/x86_64-linux/usr/lib/python2.7/site-packages/numpy/core/include -I/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/ -I/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/git/src -I/builds/build-h3/tmp/sysroots/h3ulcb/usr/include -I/builds/build-h3/tmp/sysroots/h3ulcb/usr/include -I/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/.. -I/builds/build-h3/tmp/sysroots/h3ulcb/usr/include/python2.7 -c /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/sparse_coding.cpp -o build/temp.linux-x86_64-2.7/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/sparse_coding.o -DBINDING_TYPE=BINDING_TYPE_PYX -std=c++11 -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wall -Wextra -ftemplate-depth=1000 -O3 -fopenmp aarch64-poky-linux-gcc: error: : No such file or directory aarch64-poky-linux-gcc: error: : No such file or directory error: command 'aarch64-poky-linux-gcc' failed with exit status 1 src/mlpack/methods/sparse_coding/CMakeFiles/build_pyx_sparse_coding.dir/build.make:60: recipe for target 'src/mlpack/methods/sparse_coding/CMakeFiles/build_pyx_sparse_coding' failed make[2]: *** [src/mlpack/methods/sparse_coding/CMakeFiles/build_pyx_sparse_coding] Error 1 make[2]: Leaving directory '/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build' CMakeFiles/Makefile2:6651: recipe for target 'src/mlpack/methods/sparse_coding/CMakeFiles/build_pyx_sparse_coding.dir/all' failed make[1]: *** [src/mlpack/methods/sparse_coding/CMakeFiles/build_pyx_sparse_coding.dir/all] Error 2 make[1]: *** Waiting for unfinished jobs.... /builds/build-h3/tmp/sysroots/x86_64-linux/usr/lib/python2.7/site-packages/setuptools-36.2.7-py2.7.egg/setuptools/dist.py:350: UserWarning: The version specified ('3.0.x') is an invalid version, this may not work as expected with newer versions of setuptools, pip, and PyPI. Please see PEP 440 for more details. running build_ext cythoning /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/preprocess_split.pyx to /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/preprocess_split.cpp building 'mlpack.preprocess_split' extension aarch64-poky-linux-gcc -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -DNDEBUG -g -O3 -Wall -Wstrict-prototypes -O2 -pipe -g -feliminate-unused-debug-types -fPIC -I/builds/build-h3/tmp/sysroots/x86_64-linux/usr/lib/python2.7/site-packages/numpy/core/include -I/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/ -I/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/git/src -I/builds/build-h3/tmp/sysroots/h3ulcb/usr/include -I/builds/build-h3/tmp/sysroots/h3ulcb/usr/include -I/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/.. -I/builds/build-h3/tmp/sysroots/h3ulcb/usr/include/python2.7 -c /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/preprocess_split.cpp -o build/temp.linux-x86_64-2.7/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/preprocess_split.o -DBINDING_TYPE=BINDING_TYPE_PYX -std=c++11 -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wall -Wextra -ftemplate-depth=1000 -O3 -fopenmp aarch64-poky-linux-gcc: error: : No such file or directory aarch64-poky-linux-gcc: error: : No such file or directory error: command 'aarch64-poky-linux-gcc' failed with exit status 1 src/mlpack/methods/preprocess/CMakeFiles/build_pyx_preprocess_split.dir/build.make:60: recipe for target 'src/mlpack/methods/preprocess/CMakeFiles/build_pyx_preprocess_split' failed make[2]: *** [src/mlpack/methods/preprocess/CMakeFiles/build_pyx_preprocess_split] Error 1 make[2]: Leaving directory '/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build' CMakeFiles/Makefile2:1387: recipe for target 'src/mlpack/methods/preprocess/CMakeFiles/build_pyx_preprocess_split.dir/all' failed make[1]: *** [src/mlpack/methods/preprocess/CMakeFiles/build_pyx_preprocess_split.dir/all] Error 2 [ 89%] Linking CXX executable ../../../../bin/generate_pyx_softmax_regression cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/softmax_regression && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_link_script CMakeFiles/generate_pyx_softmax_regression.dir/link.txt --verbose=1 /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/aarch64-poky-linux/aarch64-poky-linux-g++ -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wall -Wextra -ftemplate-depth=1000 -O3 -fopenmp -O2 -pipe -g -feliminate-unused-debug-types -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -DNDEBUG -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed CMakeFiles/generate_pyx_softmax_regression.dir/__/__/bindings/python/generate_pyx_softmax_regression.cpp.o CMakeFiles/generate_pyx_softmax_regression.dir/__/__/bindings/python/print_pyx.cpp.o -o ../../../../bin/generate_pyx_softmax_regression -rdynamic ../../../../lib/libmlpack.so.2.0 -lrt -larmadillo -lboost_program_options-mt -lboost_unit_test_framework -lboost_serialization-mt cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/softmax_regression && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -DGENERATE_PYX_PROGRAM=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_softmax_regression -DPYX_OUTPUT_FILE=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/softmax_regression.pyx -P /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/git/CMake/GeneratePYX.cmake /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_softmax_regression: /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_softmax_regression: cannot execute binary file make[2]: Leaving directory '/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build' [ 89%] Built target generate_pyx_softmax_regression [ 89%] Linking CXX executable ../../../../bin/generate_pyx_knn cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/neighbor_search && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_link_script CMakeFiles/generate_pyx_knn.dir/link.txt --verbose=1 /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/aarch64-poky-linux/aarch64-poky-linux-g++ -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wall -Wextra -ftemplate-depth=1000 -O3 -fopenmp -O2 -pipe -g -feliminate-unused-debug-types -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -DNDEBUG -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed CMakeFiles/generate_pyx_knn.dir/__/__/bindings/python/generate_pyx_knn.cpp.o CMakeFiles/generate_pyx_knn.dir/__/__/bindings/python/print_pyx.cpp.o -o ../../../../bin/generate_pyx_knn -rdynamic ../../../../lib/libmlpack.so.2.0 -lrt -larmadillo -lboost_program_options-mt -lboost_unit_test_framework -lboost_serialization-mt cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/neighbor_search && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -DGENERATE_PYX_PROGRAM=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_knn -DPYX_OUTPUT_FILE=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/knn.pyx -P /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/git/CMake/GeneratePYX.cmake /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_knn: /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_knn: cannot execute binary file make[2]: Leaving directory '/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build' [ 89%] Built target generate_pyx_knn [ 89%] Linking CXX executable ../../../../bin/generate_pyx_kfn cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/neighbor_search && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_link_script CMakeFiles/generate_pyx_kfn.dir/link.txt --verbose=1 /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/aarch64-poky-linux/aarch64-poky-linux-g++ -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wall -Wextra -ftemplate-depth=1000 -O3 -fopenmp -O2 -pipe -g -feliminate-unused-debug-types -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -DNDEBUG -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed CMakeFiles/generate_pyx_kfn.dir/__/__/bindings/python/generate_pyx_kfn.cpp.o CMakeFiles/generate_pyx_kfn.dir/__/__/bindings/python/print_pyx.cpp.o -o ../../../../bin/generate_pyx_kfn -rdynamic ../../../../lib/libmlpack.so.2.0 -lrt -larmadillo -lboost_program_options-mt -lboost_unit_test_framework -lboost_serialization-mt cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/neighbor_search && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -DGENERATE_PYX_PROGRAM=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_kfn -DPYX_OUTPUT_FILE=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/kfn.pyx -P /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/git/CMake/GeneratePYX.cmake /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_kfn: /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_kfn: cannot execute binary file make[2]: Leaving directory '/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build' [ 89%] Built target generate_pyx_kfn [ 89%] Linking CXX executable ../../../../bin/generate_pyx_krann cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/rann && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -E cmake_link_script CMakeFiles/generate_pyx_krann.dir/link.txt --verbose=1 /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/aarch64-poky-linux/aarch64-poky-linux-g++ -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wall -Wextra -ftemplate-depth=1000 -O3 -fopenmp -O2 -pipe -g -feliminate-unused-debug-types -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -DNDEBUG -march=armv8-a -mtune=cortex-a57.cortex-a53 --sysroot=/builds/build-h3/tmp/sysroots/h3ulcb -O2 -pipe -g -feliminate-unused-debug-types -fvisibility-inlines-hidden -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed -Wl,-O1 -Wl,--hash-style=gnu -Wl,--as-needed CMakeFiles/generate_pyx_krann.dir/__/__/bindings/python/generate_pyx_krann.cpp.o CMakeFiles/generate_pyx_krann.dir/__/__/bindings/python/print_pyx.cpp.o -o ../../../../bin/generate_pyx_krann -rdynamic ../../../../lib/libmlpack.so.2.0 -lrt -larmadillo -lboost_program_options-mt -lboost_unit_test_framework -lboost_serialization-mt cd /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/methods/rann && /builds/build-h3/tmp/sysroots/x86_64-linux/usr/bin/cmake -DGENERATE_PYX_PROGRAM=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_krann -DPYX_OUTPUT_FILE=/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/src/mlpack/bindings/python/mlpack/krann.pyx -P /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/git/CMake/GeneratePYX.cmake /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_krann: /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build/bin/generate_pyx_krann: cannot execute binary file make[2]: Leaving directory '/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build' [ 89%] Built target generate_pyx_krann make[1]: Leaving directory '/builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/build' Makefile:141: recipe for target 'all' failed make: *** [all] Error 2 ERROR: oe_runmake failed ERROR: Function failed: do_compile (log file is located at /builds/build-h3/tmp/work/aarch64-poky-linux/mlpack/git-r0/temp/log.do_compile.17361) =========================================== My recipe looks like this: =========================================== DEPENDS = "boost armadillo python-native python-setuptools-native python-pandas-native python-numpy-native python-cython-native python-pytest-runner-native doxygen-native" LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=3cee6555b8c975c14d29687fe7e78038" SRC_URI = "git://github.com/mlpack/mlpack.git;protocol=https \ " SRCREV = "b8ee319818e6213da4b92cb69dab94b956795401" S = "${WORKDIR}/git" inherit cmake pythonnative EXTRA_OECMAKE = "-DDEBUG:BOOL=OFF \ -DPROFILE:BOOL=OFF \ -DBUILD_TESTS:BOOL=OFF \ -DCMAKE_BUILD_TYPE:STRING=Release \ -DCMAKE_SKIP_INSTALL_RPATH:BOOL=YES \ -DCMAKE_SKIP_RPATH:BOOL=YES \ -DPY_PANDAS:PATH=${STAGING_LIBDIR_NATIVE}/python2.7/site-packages/pandas \ " do_compile_prepend() { export STAGING_LIBDIR="${STAGING_LIBDIR}" export STAGING_INCDIR="${STAGING_INCDIR}" } =========================================== Is there something else that needs to be included in my recipe? Or is the build environment missing something? I'm a novice. So any pointers would really help. Thanks!
|
|
Re: Yocto Image with custom directory layout
Ayoub Zaki <ayoub.zaki@...>
Hi,
Thank you Stefano, it did the trick :-)It looks like you inherit "core-image" instead of just "image". I canOn 12.10.2017 19:07, Ayoub Zaki wrote:I tried that but it does pull other packages even if I set in my image:Hi,Should be possible if your image installs only your specific recipes Cheers -- Ayoub Zaki Embedded Systems Consultant Vaihinger Straße 2/1 D-71634 Ludwigsburg Tel. : +4971415074546 Mobile : +4917662901545 Email : ayoub.zaki@... Homepage : https://embexus.com
|
|
rocko problem with external cross compilation
Marek Belisko
Hi,
we're bumping our layer to latest master (rocko). Previously we use for development purposes only flow like: - build image and use sysroot + toolchain for cross compilation (we use cmake where we setup toolchain file with correct paths and compile our application) But when try to use same approach for image build via rocko it always fail when doing external cross compilation (errors about that cannot compile simple program -> I checked path for gcc and g++ and they are correct). Any ideas what to look for appreciated. Thanks a lot. BR, marek -- as simple and primitive as possible ------------------------------------------------- Marek Belisko - OPEN-NANDRA Freelance Developer Ruska Nova Ves 219 | Presov, 08005 Slovak Republic Tel: +421 915 052 184 skype: marekwhite twitter: #opennandra web: http://open-nandra.com
|
|
[meta-selinux][PATCH] refpolicy: fix boot failure with systemd + mls
wenzong.fan@...
From: Wenzong Fan <wenzong.fan@...>
* Allow kernel_t to lower file level * Allow kernel_t to set process level Signed-off-by: Wenzong Fan <wenzong.fan@...> --- ...-kernel_t-mls-trusted-for-lowering-file-l.patch | 74 ++++++++++++++++++++++ ...-kernel_t-mls-trusted-for-setting-process.patch | 43 +++++++++++++ .../refpolicy/refpolicy_2.20170204.inc | 2 + 3 files changed, 119 insertions(+) create mode 100644 recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-lowering-file-l.patch create mode 100644 recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-setting-process.patch diff --git a/recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-lowering-file-l.patch b/recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-lowering-file-l.patch new file mode 100644 index 0000000..a3b4803 --- /dev/null +++ b/recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-lowering-file-l.patch @@ -0,0 +1,74 @@ +From 04643644acfa30eaa0a2f7902ea48cf79f571f6d Mon Sep 17 00:00:00 2001 +From: Wenzong Fan <wenzong.fan@...> +Date: Fri, 13 Oct 2017 07:20:40 +0000 +Subject: [PATCH] poky-policy: kernel_t mls trusted for lowering file level + +The boot process hangs with the error while using MLS policy: + + [!!!!!!] Failed to mount API filesystems, freezing. + [ 4.085349] systemd[1]: Freezing execution. + +Make kernel_t mls trusted for lowering the level of files to fix below +avc denials and remove the hang issue. + + op=security_validate_transition seresult=denied \ + oldcontext=system_u:object_r:device_t:s15:c0.c1023 \ + newcontext=system_u:object_r:device_t:s0 \ + taskcontext=system_u:system_r:kernel_t:s15:c0.c1023 tclass=dir + systemd[1]: Unable to fix SELinux security context of /dev: Operation not permitted + + avc: denied { create } for pid=1 comm="systemd" name="shm" \ + scontext=system_u:system_r:kernel_t:s15:c0.c1023 \ + tcontext=system_u:object_r:tmpfs_t:s0 tclass=dir permissive=0 + systemd[1]: Failed to mount tmpfs at /dev/shm: No such file or directory + + avc: denied { create } for pid=1 comm="systemd" name="pts" \ + scontext=system_u:system_r:kernel_t:s15:c0.c1023 \ + tcontext=system_u:object_r:devpts_t:s0-s15:c0.c1023 tclass=dir permissive=0 + + op=security_validate_transition seresult=denied \ + oldcontext=system_u:object_r:unlabeled_t:s0 \ + newcontext=system_u:object_r:var_run_t:s0-s15:c0.c1023 \ + taskcontext=system_u:system_r:kernel_t:s15:c0.c1023 tclass=dir + + op=security_validate_transition seresult=denied \ + oldcontext=system_u:object_r:tmpfs_t:s15:c0.c1023 \ + newcontext=system_u:object_r:var_run_t:s0-s15:c0.c1023 \ + taskcontext=system_u:system_r:kernel_t:s15:c0.c1023 tclass=dir + systemd[1]: Unable to fix SELinux security context of /run: Operation not permitted + + op=security_validate_transition seresult=denied \ + oldcontext=system_u:object_r:tmpfs_t:s15:c0.c1023 \ + newcontext=system_u:object_r:cgroup_t:s0 \ + taskcontext=system_u:system_r:kernel_t:s15:c0.c1023 tclass=dir + systemd[1]: Unable to fix SELinux security context of /sys/fs/cgroup: Operation not permitted + + avc: denied { create } for pid=1 comm="systemd" name="pstore" \ + scontext=system_u:system_r:kernel_t:s15:c0.c1023 \ + tcontext=system_u:object_r:pstore_t:s0 tclass=dir permissive=0 + +Reference: https://bugzilla.redhat.com/show_bug.cgi?id=667370 + +Upstream-Status: Pending + +Signed-off-by: Wenzong Fan <wenzong.fan@...> +--- + policy/modules/kernel/kernel.te | 2 ++ + 1 file changed, 2 insertions(+) + +diff --git a/policy/modules/kernel/kernel.te b/policy/modules/kernel/kernel.te +index 4794f29..363381c 100644 +--- a/policy/modules/kernel/kernel.te ++++ b/policy/modules/kernel/kernel.te +@@ -328,6 +328,8 @@ mls_file_write_all_levels(kernel_t) + mls_file_read_all_levels(kernel_t) + mls_socket_write_all_levels(kernel_t) + mls_fd_use_all_levels(kernel_t) ++# https://bugzilla.redhat.com/show_bug.cgi?id=667370 ++mls_file_downgrade(kernel_t) + + ifdef(`distro_redhat',` + # Bugzilla 222337 +-- +2.13.3 + diff --git a/recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-setting-process.patch b/recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-setting-process.patch new file mode 100644 index 0000000..530b30d --- /dev/null +++ b/recipes-security/refpolicy/refpolicy-2.20170204/poky-policy-kernel_t-mls-trusted-for-setting-process.patch @@ -0,0 +1,43 @@ +From 5a47be14ff03ae0d959908ad39b429787670d40e Mon Sep 17 00:00:00 2001 +From: Wenzong Fan <wenzong.fan@...> +Date: Fri, 13 Oct 2017 08:16:18 +0000 +Subject: [PATCH] poky-policy: kernel_t mls trusted for setting process level + +Because of selinux-init.service always checks the label of init +process to determine if the system needs to be re-labeled and re- +booted, a failed transition will cause the target falls into loop +of re-label & re-boot. + +Make kernel_t MLS trusted for setting the level of processes it +executes to fix below avc denial and remove the error: + + avc: denied { dyntransition } for pid=1 comm="systemd" \ + scontext=system_u:system_r:kernel_t:s15:c0.c1023 \ + tcontext=system_u:system_r:init_t:s0-s15:c0.c1023 \ + tclass=process permissive=0 + + systemd[1]: Failed to transition into init label \ + 'system_u:system_r:init_t:s0-s15:c0.c1023', ignoring. + +Upstream-Status: Pending + +Signed-off-by: Wenzong Fan <wenzong.fan@...> +--- + policy/modules/kernel/kernel.te | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/policy/modules/kernel/kernel.te b/policy/modules/kernel/kernel.te +index 363381c..8105b91 100644 +--- a/policy/modules/kernel/kernel.te ++++ b/policy/modules/kernel/kernel.te +@@ -328,6 +328,7 @@ mls_file_write_all_levels(kernel_t) + mls_file_read_all_levels(kernel_t) + mls_socket_write_all_levels(kernel_t) + mls_fd_use_all_levels(kernel_t) ++mls_process_set_level(kernel_t) + # https://bugzilla.redhat.com/show_bug.cgi?id=667370 + mls_file_downgrade(kernel_t) + +-- +2.13.3 + diff --git a/recipes-security/refpolicy/refpolicy_2.20170204.inc b/recipes-security/refpolicy/refpolicy_2.20170204.inc index 51c5050..06e8c08 100644 --- a/recipes-security/refpolicy/refpolicy_2.20170204.inc +++ b/recipes-security/refpolicy/refpolicy_2.20170204.inc @@ -53,6 +53,8 @@ SRC_URI += " \ file://poky-policy-fix-setfiles-statvfs-get-file-count.patch \ file://poky-policy-fix-dmesg-to-use-dev-kmsg.patch \ file://ftp-add-ftpd_t-to-mlsfilewrite.patch \ + file://poky-policy-kernel_t-mls-trusted-for-lowering-file-l.patch \ + file://poky-policy-kernel_t-mls-trusted-for-setting-process.patch \ " # Backport from upstream -- 2.13.0
|
|
Re: possible to append or patch existing machine .conf file?
Bernd <prof7bit@...>
I have now combined the last 2 answers:
toggle quoted messageShow quoted text
I did not want to put more customization than machine and distro into my local.conf and since I already have my own distro conf I have now put the include conf/machine/${MACHINE}-extra.conf into my own distro conf file and made colibri-vf-extra.conf, both files are now inside my own layer folder and under my project's version control so it won't get lost. This works. Thank you 2017-10-13 10:56 GMT+02:00 Bernd <prof7bit@...>:
sorry, the gmail user interface sent the reply not to the list by
|
|
Re: Yocto Image with custom directory layout
Stefano Babic
On 12/10/2017 20:47, Ayoub Zaki wrote:
Hi,It looks like you inherit "core-image" instead of just "image". I can confirm that this work, I have this simple recipe: # Copyright (C) 2017 Stefano Babic <sbabic@...> # Released under the MIT license (see COPYING.MIT for the terms) DESCRIPTION = "Image with user processes" LICENSE = "CLOSED" SECTION = "Application" inherit image IMAGE_INSTALL = " \ projects-firmware \ " And project firmware has just the layout I want. Regards, Stefano -- ===================================================================== DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic@... =====================================================================
|
|
Yocto Project Developer Day at ELCE in Prague
Jeff Osier-Mixon <jefro@...>
The Yocto Project is a Bronze sponsor of the Embedded Linux Conference in Prague, starting on 23 October, and we also provide a conference add-on as we have for the past several years - Yocto Project Developer Day. DevDay is an inexpensive one-day event that enables you to learn about the project in either the Introductory track, a detailed technical introduction to the project taught by Linux Foundation professional trainers, or the Advanced track, a collection of intermediate and advanced level hands-on presentations taught by maintainers and other principals in the Yocto Project. This day is a chance for intensive training as well as one-on-one contact with the developers who create and maintain the Yocto Project. In addition, each attendee will receive a development board, with three to choose from. Lunch is provided. For more details and a link to register, see the DevDay page at Even if you don't attend DevDay, be sure to stop and say hello at the booth at ELCE! Jeff Osier-Mixon - Open Source Community Manager, Intel Corporation
|
|
Re: How do I patch binutils for the SDK
Paul D. DeRocco
From: John ErnbergI had a feeling I was doing something dumb. Thanks. -- Ciao, Paul D. DeRocco Paul mailto:pderocco@...
|
|
Re: How do I patch binutils for the SDK
John Ernberg <john.ernberg@...>
On 10/13/2017 05:52 AM, Paul D. DeRocco wrote:
Looks like you're overriding SRC_URI instead of appending it. Try withFrom: Khem Raj [mailto:raj.khem@...]Yocto's Bugzilla isn't recognizing my password, and when it says that it's '+=' instead of just '='. file://gas_as.h.patch \// John
|
|
Re: How do I patch binutils for the SDK
Paul D. DeRocco
From: Khem Raj [mailto:raj.khem@...]mitdiff_plain;h=> 39865a7f420ab4ca4dec6ed27339618a5d5dc366;hp=fe22022617a7122491aa83c893a10a8d861cde73 That didn't change anything. (Pyro is using 2.28, BTW.) The crosssdk recipe is built in x86_64-linux/binutils-crosssdk-x86_64-pokysdk-linux/2.28-r0/git. All I see in there are a couple of quilt directories containing my patch files, no source files. So I decided to run a devshell. Since that doesn't happen until after the patches are supplied, that failed, too. So I removed the .bbappend and ran the devshell. There they were, a half-bazillion nice source files, including the gas directory. So I put the .bbappend back and ran the devshell again, and the first thing it did was clean that directory, after which the patches failed again. I have no clue how this build system works. Is the source directory supposed to be where the files are patched? What cleans the source directory? I notice that after any build, there never seem to be any source files hanging around. -- Ciao, Paul D. DeRocco Paul mailto:pderocco@...
|
|
Re: How do I patch binutils for the SDK
On Thu, Oct 12, 2017 at 8:52 PM, Paul D. DeRocco <pderocco@...> wrote:
you can just make 1 patch downloadFrom: Khem Raj [mailto:raj.khem@...]Yocto's Bugzilla isn't recognizing my password, and when it says that it's https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;a=commitdiff_plain;h=39865a7f420ab4ca4dec6ed27339618a5d5dc366;hp=fe22022617a7122491aa83c893a10a8d861cde73 and delete the hunk which contains changeslog entry and rest should apply cleanly. And add it to SRC_URI in binutils-2.29.inc and the patches from that Bugzilla page are in a binutils directory. The
|
|
Re: How do I patch binutils for the SDK
Paul D. DeRocco
From: Khem Raj [mailto:raj.khem@...]Yocto's Bugzilla isn't recognizing my password, and when it says that it's emailed me a password change message, it doesn't show up. However, the four small patches are in the Sourceware binutils-gdb GIT repo, at the link I mentioned: https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=39865a7f420ab4c a4dec6ed27339618a5d5dc366 Just to verify, my binutils-crosssdk_%.bbappend file contains: FILESEXTRAPATHS_prepend := "${THISDIR}/binutils:" SRC_URI = " \ file://gas_as.h.patch \ file://gas_ChangeLog.patch \ file://gas_input-scrub.c.patch \ file://gas_listing.c.patch \ " and the patches from that Bugzilla page are in a binutils directory. The errors I get indicate that the patches are being attempted, but aren't matching up with any source files. -- Ciao, Paul D. DeRocco Paul mailto:pderocco@...
|
|
Re: How to use two recipes to satisfy different PROVIDES -- gpu support
On Thu, Oct 12, 2017 at 03:33:53AM +0000, Gutierrez, Hernan Ildefonso (Boise R&D, FW) wrote:
Raj,you can also look at meta-raspberrypi
|
|
[meta-security][PATCH] openscape: fix ptest compile errors and update
update to 1.2.15
plus ERROR: openscap-1.2.14-r0 do_package_qa: QA Issue: /usr/lib/openscap/ptest/tests/probes/process58/all.sh contained in package openscap-ptest requires /bin/bash, but no providers found in RDEPENDS_openscap-ptest? [file-rdeps] ERROR: openscap-1.2.14-r0 do_package_qa: QA Issue: /usr/lib/openscap/ptest/tests/xmldiff.pl contained in package openscap-ptest requires /usr/bin/perl, but no providers found in RDEPENDS_openscap-ptest? [file-rdeps] ERROR: openscap-1.2.14-r0 do_package_qa: QA Issue: /usr/lib/openscap/ptest/tests/nist/test_worker.py contained in package openscap-ptest requires /usr/bin/python2, but no providers found in RDEPENDS_openscap-ptest? [file-rdeps] Signed-off-by: Armin Kuster <akuster808@...> --- .../openscap/{openscap_1.2.14.bb => openscap_1.2.15.bb} | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) rename meta-security-compliance/recipes-openscap/openscap/{openscap_1.2.14.bb => openscap_1.2.15.bb} (94%) diff --git a/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.14.bb b/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.15.bb similarity index 94% rename from meta-security-compliance/recipes-openscap/openscap/openscap_1.2.14.bb rename to meta-security-compliance/recipes-openscap/openscap/openscap_1.2.15.bb index 0d26959..4dacfa2 100644 --- a/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.14.bb +++ b/meta-security-compliance/recipes-openscap/openscap/openscap_1.2.15.bb @@ -11,7 +11,7 @@ DEPENDS = "autoconf-archive pkgconfig gconf procps curl libxml2 rpm \ DEPENDS_class-native = "autoconf-archive-native pkgconfig-native swig-native curl-native libxml2-native libxslt-native dpkg-native libgcrypt-native nss-native" -SRCREV = "7a924c0eea10d05f512660192c8c4aef447801a6" +SRCREV = "240930d42611983c65ecae16dbca3248ce130921" SRC_URI = "git://github.com/akuster/openscap.git;branch=oe \ file://crypto_pkgconfig.patch \ file://run-ptest \ @@ -66,6 +66,7 @@ do_install_append_class-native () { TESTDIR = "tests" do_compile_ptest() { + sed -i 's:python2:python:' ${S}/${TESTDIR}/nist/test_worker.py echo 'buildtest-TESTS: $(check)' >> ${TESTDIR}/Makefile oe_runmake -C ${TESTDIR} buildtest-TESTS } @@ -78,5 +79,6 @@ do_install_ptest() { FILES_${PN} += "${PYTHON_SITEPACKAGES_DIR}" RDEPENDS_${PN} += "libxml2 python libgcc" +RDEPENDS_${PN}-ptest = "bash perl python" BBCLASSEXTEND = "native" -- 2.7.4
|
|
Re: How do I patch binutils for the SDK
On Thu, Oct 12, 2017 at 06:23:03AM +0000, Paul D. DeRocco wrote:
I found a bug in the GNU assembler that makes it produce corruptedYou can apply the patch to all binutils variants, its fine. Send a patch or if you want, file a ticket in bugzilla and we will take care.
|
|
devtool sdk-install <recipe>
Aaron_Wright@...
I'm confused as to how the devtool sdk-install
command is supposed to work. Take for example:
devtool sdk-install cxxtest This installs all the /usr/lib and /usr/include stuff into the sysroot, but doesn't install the /usr/bin stuff required to actually use cxxtest. So should I install nativesdk-cxxtest instead? Still doesn't work, but I was just curious about the nativesdk- prefix. cxxtest-native doesn't work either. Does the cxxtest recipe need a SYSROOT_DIRS_append = " ${bindir}" in order to get the /usr/bin files installed in the eSDK when someone installs it? PS - often devtool sdk-install <recipe> will act like it is working and then print an error at the end: NOTE: Tasks Summary: Attempted 105 tasks of which 71 didn't need to be rerun and all succeeded. ERROR: Failed to install nativesdk-cxxtest - unavailable PPS - a google search for devtool sdk-install returns nothing, so hopefully the mailing list can help.
|
|
Using kernel fitimage with initramfs
Manjukumar Harthikote Matha <MANJUKUM@...>
Hi All,
Had a question about kernel-fitimage.bbclass. I am enabling the fitimage using KERNEL_CLASSES += "kernel-fitimage" and KERNEL_IMAGETYPE = "fitImage". It works and I see fitimage in my deploy directory without any issues. However when I enable initramfs along with fitimage, using INITRAMFS_IMAGE = "core-image-minimal" and INITRAMFS_IMAGE_BUNDLE = "1", kernel build fails. It's mostly from kernel.bbclass because it tries to deploy fitimage https://github.com/openembedded/openembedded-core/blob/master/meta/classes/kernel.bbclass#L639 Am I using this featurecorrectly? anyone else facing same issue? Below is a initial patch which I did to get me across the error, but I am not sure if this is the correct answer. diff --git a/meta/classes/kernel.bbclass b/meta/classes/kernel.bbclass index 756707a..d5342b4 100644 --- a/meta/classes/kernel.bbclass +++ b/meta/classes/kernel.bbclass @@ -208,14 +208,16 @@ do_bundle_initramfs () { # Backing up kernel image relies on its type(regular file or symbolic link) tmp_path="" for type in ${KERNEL_IMAGETYPES} ; do - if [ -h ${KERNEL_OUTPUT_DIR}/$type ] ; then - linkpath=`readlink -n ${KERNEL_OUTPUT_DIR}/$type` - realpath=`readlink -fn ${KERNEL_OUTPUT_DIR}/$type` - mv -f $realpath $realpath.bak - tmp_path=$tmp_path" "$type"#"$linkpath"#"$realpath - elif [ -f ${KERNEL_OUTPUT_DIR}/$type ]; then - mv -f ${KERNEL_OUTPUT_DIR}/$type ${KERNEL_OUTPUT_DIR}/$type.bak - tmp_path=$tmp_path" "$type"##" + if [ "$type" != "fitImage" ]; then + if [ -h ${KERNEL_OUTPUT_DIR}/$type ] ; then + linkpath=`readlink -n ${KERNEL_OUTPUT_DIR}/$type` + realpath=`readlink -fn ${KERNEL_OUTPUT_DIR}/$type` + mv -f $realpath $realpath.bak + tmp_path=$tmp_path" "$type"#"$linkpath"#"$realpath + elif [ -f ${KERNEL_OUTPUT_DIR}/$type ]; then + mv -f ${KERNEL_OUTPUT_DIR}/$type ${KERNEL_OUTPUT_DIR}/$type.bak + tmp_path=$tmp_path" "$type"##" + fi fi done use_alternate_initrd=CONFIG_INITRAMFS_SOURCE=${B}/usr/${INITRAMFS_IMAGE_NAME}.cpio @@ -627,8 +629,10 @@ MODULE_TARBALL_DEPLOY ?= "1" kernel_do_deploy() { for type in ${KERNEL_IMAGETYPES} ; do - base_name=${type}-${KERNEL_IMAGE_BASE_NAME} - install -m 0644 ${KERNEL_OUTPUT_DIR}/${type} ${DEPLOYDIR}/${base_name}.bin + if [ "$type" != "fitImage" ]; then + base_name=${type}-${KERNEL_IMAGE_BASE_NAME} + install -m 0644 ${KERNEL_OUTPUT_DIR}/${type} ${DEPLOYDIR}/${base_name}.bin + fi done if [ ${MODULE_TARBALL_DEPLOY} = "1" ] && (grep -q -i -e '^CONFIG_MODULES=y$' .config); then mkdir -p ${D}/lib @@ -637,21 +641,25 @@ kernel_do_deploy() { fi for type in ${KERNEL_IMAGETYPES} ; do - base_name=${type}-${KERNEL_IMAGE_BASE_NAME} - symlink_name=${type}-${KERNEL_IMAGE_SYMLINK_NAME} - ln -sf ${base_name}.bin ${DEPLOYDIR}/${symlink_name}.bin - ln -sf ${base_name}.bin ${DEPLOYDIR}/${type} + if [ "$type" != "fitImage" ]; then + base_name=${type}-${KERNEL_IMAGE_BASE_NAME} + symlink_name=${type}-${KERNEL_IMAGE_SYMLINK_NAME} + ln -sf ${base_name}.bin ${DEPLOYDIR}/${symlink_name}.bin + ln -sf ${base_name}.bin ${DEPLOYDIR}/${type} + fi done cd ${B} # Update deploy directory for type in ${KERNEL_IMAGETYPES} ; do - if [ -e "${KERNEL_OUTPUT_DIR}/${type}.initramfs" ]; then - echo "Copying deploy ${type} kernel-initramfs image and setting up links..." - initramfs_base_name=${type}-${INITRAMFS_BASE_NAME} - initramfs_symlink_name=${type}-initramfs-${MACHINE} - install -m 0644 ${KERNEL_OUTPUT_DIR}/${type}.initramfs ${DEPLOYDIR}/${initramfs_base_name}.bin - ln -sf ${initramfs_base_name}.bin ${DEPLOYDIR}/${initramfs_symlink_name}.bin + if [ "$type" != "fitImage" ]; then + if [ -e "${KERNEL_OUTPUT_DIR}/${type}.initramfs" ]; then + echo "Copying deploy ${type} kernel-initramfs image and setting up links..." + initramfs_base_name=${type}-${INITRAMFS_BASE_NAME} + initramfs_symlink_name=${type}-initramfs-${MACHINE} + install -m 0644 ${KERNEL_OUTPUT_DIR}/${type}.initramfs ${DEPLOYDIR}/${initramfs_base_name}.bin + ln -sf ${initramfs_base_name}.bin ${DEPLOYDIR}/${initramfs_symlink_name}.bin + fi fi done } Thanks, Manju
|
|
Re: Yocto Image with custom directory layout
Josef Holzmayr <holzmayr@...>
Hi
On 12.10.2017 20:47, Ayoub Zaki wrote: Hi,Probably you're inheriting from some more complex image class that pulls in the undesired packages. Have you already checked bitbake -e to see how the variables get expanded? Greetz -- Josef Holzmayr Software Developer Embedded Systems Tel: +49 8444 9204-48 Fax: +49 8444 9204-50 R-S-I Elektrotechnik GmbH & Co. KG Woelkestrasse 11 D-85301 Schweitenkirchen www.rsi-elektrotechnik.de ——————————————— Amtsgericht Ingolstadt – GmbH: HRB 191328 – KG: HRA 170393 Geschäftsführer: Dr.-Ing. Michael Sorg, Dipl.-Ing. Franz Sorg Ust-IdNr: DE 128592548 _____________________________________________________________ Amtsgericht Ingolstadt - GmbH: HRB 191328 - KG: HRA 170363 Geschäftsführer: Dr.-Ing. Michael Sorg, Dipl.-Ing. Franz Sorg USt-IdNr.: DE 128592548
|
|