I checked for INCOMPATIBLE_LICENSE FLAG in distro configuration of my image 
recipe but could not find it. The only place where INCOMPATIBLE_LICENSE is used 
is in gnutls recipe. I tried using IMAGE_ALLOW_PACKAGES_pn-custom-base-image = 
"coreutils" but found no luck.
Can it be the case that coreutils is already present in rootfs and selinux 
recipe is trying to install it again. I cannot figure out how to build 
coreutils with selinux enabled.
What should be the correct way for building coreutils with selinux enabled and 
adding it to the image if LICENSE is not an issue.

________________________________
From: Khem Raj <raj.k...@gmail.com>
Sent: Friday, January 13, 2023 10:38 PM
To: Kamal Kishor <kamal.kis...@vestel.com.hk>
Cc: yocto@lists.yoctoproject.org <yocto@lists.yoctoproject.org>
Subject: Re: [yocto] meta-selinux: ERROR: nothing provides coreutils needed by 
packagegroup-core-selinux

On Fri, Jan 13, 2023 at 6:32 AM Kamal Kishor <kamal.kis...@vestel.com.hk> wrote:
>
> Hi,
> I was trying to integrate meta-selinux layer with thud branch on our existing 
> yocto build. I followed all the steps which are mentioned in README and 
> SElinux-FAQ but I am facing an error in do_rootfs step.
> The error is shown below:
>
> ERROR: custom-base-image-1.0-r0 do_rootfs: Unable to install packages. 
> Command 
> '/mnt/EVC-TI-06.03.00.106/tisdk/build/arago-tmp-external-arm-toolchain/work/am437x_hs_evm-linux-gnueabi/custom-base-image/1.0-r0/recipe-sysroot-native/usr/bin/opkg
>  --volatile-cache -f 
> /mnt/EVC-TI-06.03.00.106/tisdk/build/arago-tmp-external-arm-toolchain/work/am437x_hs_evm-linux-gnueabi/custom-base-image/1.0-r0/opkg.conf
>  -t 
> /mnt/EVC-TI-06.03.00.106/tisdk/build/arago-tmp-external-arm-toolchain/work/am437x_hs_evm-linux-gnueabi/custom-base-image/1.0-r0/temp/ipktemp/
>  -o 
> /mnt/EVC-TI-06.03.00.106/tisdk/build/arago-tmp-external-arm-toolchain/work/am437x_hs_evm-linux-gnueabi/custom-base-image/1.0-r0/rootfs
>   --force_postinstall    install agentv3-evc10 base-passwd czmq dropbear 
> e2fsprogs-resize2fs eichrecht gattlib gosuncn-cm ifmetric 
> kernel-module-mt7663 kernel-module-mt7668 kernel-module-mt7668-bt libmodbus5 
> libtcti-device-dev libtcti-device-staticdev libtcti-device0 
> libtcti-socket-dev libtcti-socket-staticdev libtcti-socket0 libtss2 
> libtss2-dev libtss2-staticdev libwebsockets19 midmeter modbustcp ocpp-evc10 
> openssh-sftp-server opkg ostree packagegroup-arago-base 
> packagegroup-arago-base-tisdk packagegroup-arago-console 
> packagegroup-arago-qte packagegroup-arago-tisdk-connectivity 
> packagegroup-arago-tisdk-crypto packagegroup-arago-tisdk-graphics 
> packagegroup-core-boot packagegroup-core-selinux parted procps psplash 
> pybluez python3-aws-iot-device-sdk-python python3-bcrypt python3-flask 
> python3-flask-login python3-flask-restful python3-flask-sqlalchemy 
> python3-marshmallow python3-modbus-tk python3-pycryptodome python3-pyjwt 
> python3-pyserial python3-pyzmq python3-requests python3-sqlalchemy quectel-cm 
> resourcemgr rest-webasto restv2 run-postinsts shadow smartcharge tpm2.0-tools 
> tzdata ui-evc10 uidreader webconfigv3 wpa zeromq' returned 1:
> Collected errors:
>  * Solver encountered 1 problem(s):
>  * Problem 1/1:
>  *   - nothing provides coreutils needed by 
> packagegroup-core-selinux-1.0-r0.armv7at2hf-neon

Does your distro policy inhibit GPL-3.0 ? if so then the error is right.

>  *
>  * Solution 1:
>  *   - do not ask to install a package providing packagegroup-core-selinux
>
>
>
> ERROR: custom-base-image-1.0-r0 do_rootfs: Function failed: do_rootfs
> ERROR: Logfile of failure stored in: 
> /mnt/EVC-TI-06.03.00.106/tisdk/build/arago-tmp-external-arm-toolchain/work/am437x_hs_evm-linux-gnueabi/custom-base-image/1.0-r0/temp/log.do_rootfs.21704
> ERROR: Task 
> (/mnt/EVC-TI-06.03.00.106/tisdk/sources/meta-custom/recipes-core/images/custom-base-image.bb:do_rootfs)
>  failed with exit code '1'
>
>
> To avoid the error, I added RDEPENDS_packagegroup-core-selinux_remove = 
> "coreutils" to local.conf. After that the build is successfull.
> But I am not sure if this will break selinux functionality. Please provide me 
> with some insights on this.

If your distro does not want coreutils then you may have to look
through other options to get selinux working. I am not sure if
upstream meta-security tests this option
by default.

>
> Attached here is the log file for your reference. Please let me know if you 
> need any information from me.
>
> Thanks & Regards
> Kamal Pandey
>
>
> 
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#58995): https://lists.yoctoproject.org/g/yocto/message/58995
Mute This Topic: https://lists.yoctoproject.org/mt/96246573/21656
Group Owner: yocto+ow...@lists.yoctoproject.org
Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub 
[arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to