Problem
As you have discovered, Gentoo only allows one Profile Setup at a time. As you can see from my eselect profile list
:
[1] default/linux/amd64/13.0
[2] default/linux/amd64/13.0/selinux
[3] default/linux/amd64/13.0/desktop
[4] default/linux/amd64/13.0/desktop/gnome
[5] default/linux/amd64/13.0/desktop/gnome/systemd
[6] default/linux/amd64/13.0/desktop/kde *
[7] default/linux/amd64/13.0/desktop/kde/systemd
[8] default/linux/amd64/13.0/desktop/plasma
[9] default/linux/amd64/13.0/desktop/plasma/systemd
[10] default/linux/amd64/13.0/developer
[11] default/linux/amd64/13.0/no-multilib
[12] default/linux/amd64/13.0/systemd
[13] default/linux/amd64/13.0/x32
[14] hardened/linux/amd64
[15] hardened/linux/amd64/selinux
[16] hardened/linux/amd64/no-multilib
[17] hardened/linux/amd64/no-multilib/selinux
[18] hardened/linux/amd64/x32
[19] hardened/linux/musl/amd64
[20] hardened/linux/musl/amd64/x32
[21] default/linux/uclibc/amd64
[22] hardened/linux/uclibc/amd64
Solution
Having set your profile to hardened (14 on my list), we now need to examine the files for the KDE Profile: (note that this takes a bit of writing without a text editor):
cd /usr/portage/profiles/targets/desktop/kde
nano -w make.defaults
nano -w parent
- You should now see files in
/usr/portage/profiles/targets/desktop/
.
nano -w make.defaults
Using Scratch Paper, copy down the USE Flags from Step 2, and opening parent
in Step 3 reveals ..
, which now means we travel one directory up. Copy the USE Flags from Step 5. As the final step, issue emerge -v app-portage/ufed && ufed
. You can now set the USE Flags you copied down in /etc/portage/make.conf
. You may want to repeat the process for:
/usr/portage/profiles/desktop/kde/package.use
/usr/portage/profiles/desktop/package.use
by placing the packages listed in those two files into /etc/portage/package.use
.
During Syncs, files in /etc/portage
will not be overwritten and the USE Flags in /etc/portage/make.conf
will mimic the behavior you are trying to achieve. See the Portage Files Section in the Handbook for more information. In essence, your Portage overrides in /etc/portage
will add to your hardened profile, as Portage uses your configuration before it reads your selected profile. I know it's a pain as the USE Flags in the profiles package.use
files can be updated with each sync, so you will need to see if any are added after each sync. Generally, the profile files aren't updated very often.
Best Answer
Although the question was asked 27 days ago, maybe someone is still interested in an answer:
equery (included in app-portage/gentoolkit) can be used to get the reason why a package (PKG) was masked:
For more information on the available options and how to read the output just have a look at the man page of equery.