Dear Community,
I was able to add the Network Manager into the Yocto Hardknott by adding following lines into the <build-folder>/ conf/local.conf :
IMAGE_INSTALL_remove += " ofono connman connman-gnome connman-conf"
IMAGE_INSTALL_remove += " packagegroup-core-tools-testapps"
PACKAGE_EXCLUDE += "ofono connman connman-gnome connman-conf"
PACKAGE_EXCLUDE += "connman-client connman-tools"
PACKAGE_EXCLUDE += "packagegroup-core-tools-testapps"
DISTRO_FEATURES_remove = " 3g"
IMAGE_INSTALL_append = " networkmanager networkmanager-nmcli modemmanager"
IMAGE_INSTALL_append = " networkmanager-bash-completion"
PACKAGECONFIG_append_pn-networkmanager = " modemmanager ppp"
On the newer Yocto BSP Mickledore-LF6.1.22, I did nearly the same :
IMAGE_INSTALL:remove = " ofono connman connman-gnome connman-conf"
IMAGE_INSTALL:remove = " packagegroup-core-tools-testapps"
PACKAGE_EXCLUDE += "ofono connman connman-gnome connman-conf"
PACKAGE_EXCLUDE += "connman-client connman-tools"
PACKAGE_EXCLUDE += "packagegroup-core-tools-testapps"
DISTRO_FEATURES:remove = " 3g"
IMAGE_INSTALL:append = " networkmanager networkmanager-nmcli modemmanager"
#IMAGE_INSTALL:append = " networkmanager-bash-completion"
PACKAGECONFIG:append_pn-networkmanager = " modemmanager ppp"
with an exception that networkmanager-bash-completion is NOT appended as it generated error during the bitbaking. The nmcli is installed but not working (i.e. it does not show the available network interface with nmcli con show command) however. Current behavior :
root@viperimx8mp:~# nmcli con show
NAME UUID TYPE DEVICE
lo 132bd08f-c6db-41f4-86b8-60bf6345ad56 loopback lo
Expected behavior (in older BSP Hardknott LF-5.10.72) :
root@viperimx8mp:~# nmcli con show
NAME UUID TYPE DEVICE
Wired connection 1 fca1ee92-220b-393a-af88-32613a404fe6 ethernet eth0
Could you advise, please ?
Best Regards,
Khang
Hi @khang_letruong!
Thank you for contacting NXP Support!
If you plan to use systemd-networkd as the primary network configuration utility, you should remove connman first (when using a console-only image, you won't need to remove connman-gnome). You can use the package manager to remove the package from pre-built images by invoking.
in local.conf
# Remove connman
IMAGE_INSTALL:remove = " connman"
IMAGE_INSTALL:remove = " connman-client"
IMAGE_INSTALL:remove = " connman-gnome"
IMAGE_INSTALL:remove = " connman-plugin-wifi"
IMAGE_INSTALL:remove = " connman-plugin-ethernet"
IMAGE_INSTALL:remove = " connman-plugin-loopback"
# Add NetworkManager
IMAGE_INSTALL:append = " networkmanager"
IMAGE_INSTALL:append = " modemmanager"
Best Regards!
Chavira
Hi @Chavira ,
Unfortunately with your suggestion, I also have same issue as described here : https://community.nxp.com/t5/i-MX-Processors/MICKELDORE-6-1-36-how-to-add-bitbake-recipe-for-Network...
Regards,
Khang
Hi @khang_letruong!
Sorry for the late response.
I can add the packages to my evk board.
The steps that I following are the next:
1: Compile the image only removing conman:
On local.conf:
# Remove connman
IMAGE_INSTALL:remove = " connman"
IMAGE_INSTALL:remove = " connman-client"
IMAGE_INSTALL:remove = " connman-gnome"
IMAGE_INSTALL:remove = " connman-plugin-wifi"
IMAGE_INSTALL:remove = " connman-plugin-ethernet"
IMAGE_INSTALL:remove = " connman-plugin-loopback"
# Add NetworkManager
#IMAGE_INSTALL:append = " networkmanager"
#IMAGE_INSTALL:append = " modemmanager"
2: After the image is generated you have to clean the image:
Bitbake -c clean <Image>
3: Add the packages to local.conf:
On local.conf:
# Remove connman
IMAGE_INSTALL:remove = " connman"
IMAGE_INSTALL:remove = " connman-client"
IMAGE_INSTALL:remove = " connman-gnome"
IMAGE_INSTALL:remove = " connman-plugin-wifi"
IMAGE_INSTALL:remove = " connman-plugin-ethernet"
IMAGE_INSTALL:remove = " connman-plugin-loopback"
# Add NetworkManager
IMAGE_INSTALL:append = " networkmanager"
IMAGE_INSTALL:append = " modemmanager"
4: compile the image to generate the final image with the added packages:
Bitbake <Image>
Best Regards!
Chavira
Hi @Chavira,
I tried your suggestion but there's still following error :
ERROR: imx-image-full-1.0-r0 do_rootfs: Unable to install packages. Command '/workdir/realtime7-imx-yocto-bsp-6_1_22-2_0_0/build-xwayland/tmp/work/imx8mpevk-poky-linux/imx-image-full/1.0-r0/recipe-sysroot-native/usr/bin/apt-get install --allow-downgrades --allow-remove-essential --allow-change-held-packages --allow-unauthenticated --no-remove apt curl docker dpkg firmwared imx-g2d-samples jailhouse modemmanager networkmanager opencv-apps opencv-samples optee-client optee-os os-release packagegroup-base-extended packagegroup-core-boot packagegroup-core-full-cmdline packagegroup-core-nfs-server packagegroup-core-sdk packagegroup-core-ssh-openssh packagegroup-core-standalone-sdk-target packagegroup-core-tools-debug packagegroup-core-tools-profile packagegroup-core-tools-testapps packagegroup-core-weston packagegroup-fsl-gstreamer1.0 packagegroup-fsl-gstreamer1.0-full packagegroup-fsl-optee-imx packagegroup-fsl-tools-audio packagegroup-fsl-tools-benchmark packagegroup-fsl-tools-gpu packagegroup-fsl-tools-gpu-external packagegroup-fsl-tools-testapps packagegroup-imx-isp packagegroup-imx-ml packagegroup-imx-security packagegroup-qt6-imx packagegroup-security-parsec packagegroup-security-tpm2 packagegroup-tools-bluetooth ppp python3-opencv run-postinsts softhsm swtpm tzdata weston-xwayland xterm' returned 100:
Reading package lists...
Building dependency tree...
Reading state information...
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
connman : Conflicts: networkmanager but 1.30.4-r0 is to be installed
Recommends: connman-conf but it is not installable
E: Unable to correct problems, you have held broken packages.
ERROR: Logfile of failure stored in: /workdir/realtime7-imx-yocto-bsp-6_1_22-2_0_0/build-xwayland/tmp/work/imx8mpevk-poky-linux/imx-image-full/1.0-r0/temp/log.do_rootfs.1861
ERROR: Task (/workdir/realtime7-imx-yocto-bsp-6_1_22-2_0_0/sources/meta-imx/meta-sdk/dynamic-layers/qt6-layer/recipes-fsl/images/imx-image-full.bb:do_rootfs) failed with exit code '1'
My conf/local.conf :
# Remove connman
IMAGE_INSTALL:remove = " connman"
IMAGE_INSTALL:remove = " connman-client"
IMAGE_INSTALL:remove = " connman-gnome"
IMAGE_INSTALL:remove = " connman-plugin-wifi"
IMAGE_INSTALL:remove = " connman-plugin-ethernet"
IMAGE_INSTALL:remove = " connman-plugin-loopback"
# Add NetworkManager
IMAGE_INSTALL:append = " networkmanager"
IMAGE_INSTALL:append = " modemmanager ppp"
Best Regards,
Khang
Hi!
I got the same error the first time because I compiled the image without removing Connman first.
Please, try to delete your Yocto Project and follow the steps I provide before.
Best Regards!
Alejandro
Hi @Chavira ,
Should I remove Connection Manager from and add Network Manager into the conf/local.conf at the same time or should I bitbake with Connection Manager removed first then re-bitbake with Network Manager added later?
Regards,
Khang
Hello @khang_letruong ,
I got the same error.
I found the below package also contain the connman. So, remove the connman's package in the .bb file.
poky/meta/recipes-core/packagegroups/packagegroup-core-tools-testapps.bb
Then build the image again. The build will be succeed.
Hi @khang_letruong!
Yes, you have to compile the image deleting Connection Manager and then, do a clean, and finally add the packages to add Network Manager.
1: Compile the image only removing conman:
On local.conf:
# Remove connman
IMAGE_INSTALL:remove = " connman"
IMAGE_INSTALL:remove = " connman-client"
IMAGE_INSTALL:remove = " connman-gnome"
IMAGE_INSTALL:remove = " connman-plugin-wifi"
IMAGE_INSTALL:remove = " connman-plugin-ethernet"
IMAGE_INSTALL:remove = " connman-plugin-loopback"
# Add NetworkManager
#IMAGE_INSTALL:append = " networkmanager"
#IMAGE_INSTALL:append = " modemmanager"
2: After the image is generated you have to clean the image:
Bitbake -c clean <Image>
3: Add the packages to local.conf:
On local.conf:
# Remove connman
IMAGE_INSTALL:remove = " connman"
IMAGE_INSTALL:remove = " connman-client"
IMAGE_INSTALL:remove = " connman-gnome"
IMAGE_INSTALL:remove = " connman-plugin-wifi"
IMAGE_INSTALL:remove = " connman-plugin-ethernet"
IMAGE_INSTALL:remove = " connman-plugin-loopback"
# Add NetworkManager
IMAGE_INSTALL:append = " networkmanager"
IMAGE_INSTALL:append = " modemmanager"
4: compile the image to generate the final image with the added packages:
Bitbake <Image>
Best Regards!
Alejandro
Hi Alejandro,
Thanks for confirming the steps with the fresh yocto environment (after removing the build folder). That was however what I did so far in the following video but the error still persists : https://drive.google.com/file/d/1RTXGPiNOFMYx6835cYJzHVzsizojIMtj/view?usp=share_link
Best Regards,
Khang