Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 952104

Summary: sec-policy/selinux-makewhatis-2.20240916-r1 emerge fails due to unpopulated /usr/share/selinux/mcs
Product: Gentoo Linux Reporter: herespam1
Component: SELinuxAssignee: SE Linux Bugs <selinux>
Status: UNCONFIRMED ---    
Severity: major CC: gentoo, rp, vyedmic
Priority: Normal    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: logs and environment info

Description herespam1 2025-03-26 18:32:35 UTC
Created attachment 922958 [details]
logs and environment info

I am installing a new gentoo hardened system (the profile is [33]  default/linux/amd64/23.0/no-multilib/hardened/selinux (stable)) and am unable to complete the installation due to grub depending on sec-policy/selinux-makewhatis and this in turn failing to build. Full details are in the attached file.

I am seeing the following error:

Makefile:8: /usr/share/selinux/mcs/include/Makefile: No such file or directory

This appears to be due to /usr/share/selinux/mcs not existing.

The issue has also been reproduced by another user on the #gentoo-hardened irc channel.
Comment 1 rp 2025-04-01 02:16:07 UTC
(In reply to herespam1 from comment #0)
> Created attachment 922958 [details]
> logs and environment info
> 
> I am installing a new gentoo hardened system (the profile is [33] 
> default/linux/amd64/23.0/no-multilib/hardened/selinux (stable)) and am
> unable to complete the installation due to grub depending on
> sec-policy/selinux-makewhatis and this in turn failing to build. Full
> details are in the attached file.
> 
> I am seeing the following error:
> 
> Makefile:8: /usr/share/selinux/mcs/include/Makefile: No such file or
> directory
> 
> This appears to be due to /usr/share/selinux/mcs not existing.
> 
> The issue has also been reproduced by another user on the #gentoo-hardened
> irc channel.

Hello,

Not a fix, but this workaround worked for me: reinstall selinux-base . This fixed the same problem I was having.
Comment 2 Martin Kuchta 2025-04-02 08:46:05 UTC
I have the same problem with sec-policy/selinux-kerberos-2.20240916-r1

Re-emerging selinux-base does not change anything.
Comment 3 Christian Schmidt 2025-04-09 19:51:17 UTC
Same issue with selinux-logrotate-2.20240916-r1
Comment 4 Christian Schmidt 2025-04-09 20:10:06 UTC
(In reply to Christian Schmidt from comment #3)
> Same issue with selinux-logrotate-2.20240916-r1

Except here emerge -1 sec-policy/selinux-base-2.20240916-r1 worked to create the needed Makefile. Check if you have POLICY_TYPES set in /etc/portage/make.conf and if it is, remove it, or ensure it contains mcs.