PMS says in section 12.1.1 (see URL): * sed must be available, and must support all forms of invocations valid for GNU sed version 4 or later. * patch must be available, and must support all inputs valid for GNU patch, version as listed in table 12.1. * find and xargs must be available, and must support all forms of invocations valid for GNU findutils version 4.4 or later. Only for EAPIs listed in table 12.1 as requiring GNU find. This implies that in BSD the commands should be mapped to the gsed, gpatch, gfind and gxargs versions. However, ebuild-helpers/bsd/ contains only a wrapper for sed but not for the other commands.
This could potentially cause problems for build systems that assume a BSD userland. In the context of ebuild/eclass code, it's handled in gentoo/profiles/default/bsd/fbsd/profile.bashrc by these aliases: > type -P gmake > /dev/null && alias make=gmake > type -P gpatch > /dev/null && alias patch=gpatch > type -P gsed > /dev/null && alias sed=gsed > type -P gawk > /dev/null && alias awk=gawk > type -P gfind > /dev/null && alias find=gfind > type -P gxargs > /dev/null && alias xargs=gxargs
Maybe PMS should allow for sed, patch, find, and xargs bash aliases? That will be the safest approach, I suppose.
PMS does not even guarantee that aliases are expanded. Also from the wording it is clear that the package manager (and not profiles) must make sure that the commands are the GNU versions. (In reply to Zac Medico from comment #1) > > type -P gmake > /dev/null && alias make=gmake > > type -P gpatch > /dev/null && alias patch=gpatch > > type -P gsed > /dev/null && alias sed=gsed > > type -P gawk > /dev/null && alias awk=gawk > > type -P gfind > /dev/null && alias find=gfind > > type -P gxargs > /dev/null && alias xargs=gxargs This is very unreliable, as aliases won't be exported to subshells. (For example, bug 574626 shows that it doesn't work.)
G/FBSD is dead.