*** failed to commit transaction: The to be activated package "binutils-2.31.1-2-x86_64.hpkg" does already exist

Hello,
I’m trying to install gcc but I have the message : *** failed to commit transaction: The to be activated package “binutils-2.31.1-2-x86_64.hpkg” does already exist
Can someone help me?

This can happen when the package is indeed existing but not activated.
You can veriffy that going to /boot/system/packages and searching the package in question. If it is there, then open activated packages.txt file located in same directory and search for the package name in the list. If the package name doesn’t appear in the list, you can delete the package safely (or move it momentarily to another place if you prefer). Then you can retry the install.

You can remove the binutils package in /system/packages/

Thank you for your quick response.