User:Sam/Portage help/Understanding REQUIRED USE

Dissecting REQUIRED_USE
A REQUIRED_USE constraint message looks something like this:

The following REQUIRED_USE flag constraints are unsatisfied: foo? ( bar )

The above constraints are a subset of the following complete expression: foo? ( bar ) baz? ( ... ) ...

There are two parts to the constraint message:


 * 1) The unsatisfied constraints.
 * 2) * This is the part to pay attention to, and it gives the changes that are required to proceed.
 * 3) The full USE constraints for the package.
 * 4) * This is just to give the surrounding context for the above and should not be used to pick out USE flag changes. If it's not listed in the first section, then the constraints are already satisfied.

Example 1
Here's a typical example of a REQUIRED_USE error/conflict:

Let's break this down a bit. The key part is: The following REQUIRED_USE flag constraints are unsatisfied: wayland? ( gles2 )

i.e. "If the wayland USE flag is enabled for media-libs/libsdl2, you must enable the gles2 flag for it as well."

Example 2
Here's another example:

Let's break this down a bit. The key part is: The following REQUIRED_USE flag constraints are unsatisfied: device-mapper-only? ( !lvm2create-initrd !sanlock !thin ) static-libs? ( static !udev )

There's two parts to this:


 * 1) If the device-mapper-only USE flag is enabled for sys-fs/lvm2, you must turn off the lvm2create-initrd, sanlock, thin flags
 * 2) If the static-libs USE flag is enabled, you must have the static flag on and the udev flag off.