Configure a project with selinux enabled and run: $ make -C build refpolicy-minimum $ ls $builddir/build/refpolicy-minimum/image/etc/selinux/wr-minimum/modules/active/modules/|wc -l 395 This is incorrect since the logic for generating minimum policy doesn't work. Expected results: (17 modules) $ ls $builddir/build/refpolicy-minimum/image/etc/selinux/wr-minimum/modules/active/modules/ application.pp getty.pp libraries.pp logging.pp modutils.pp mta.pp selinuxutil.pp sysnetwork.pp userdomain.pp authlogin.pp init.pp locallogin.pp miscfiles.pp mount.pp nscd.pp storage.pp unconfined.pp