I have a gentoo overlay which has been added to http://gpo.zugaina.org/. One of my ebuilds recMD5 now shows the use flag elibc_FreeBSD even though I didn't add it. I am also running into it for a hadoop package. It looks like all I need to do is add the use flag for the package but I would like to know what its purpose is.
I am also getting an error with
euse -E elibc_FreeBSD
ERROR: Use flag "elibc_FreeBSD" is masked and should not be added to make.conf.
Best Answer
A Bit Of Background
Historically speaking some users of FreeBSD have not gotten along with users of the Linuxes. For many years, until Linux from Scratch, and it's children of whom Gentoo is one, users could not get true source code on their system, unless they chose to use the FreeBSD Ports System. For that reason FreeBSD users viewed themselves as superior, but as Gentoo and Portage matured, the stage was set for the battle pictured below(and the G is backwards, I know):
Much like Portage uses the
ebuild
construct, ports have the same rules. I linked dependency checking because that's the biggest one. If you look at Chapter 5, Section 5, you can see that ports management could be considered by some anything from an annoyance to a headache. As such the flag and project I explain below attempts to alleviate the issue by replacing the ports mechanism with portage. See How The Flag Works for more.Why Gentoo is Called a Meta Distribution
Please read GLEP:22, part of the Gentoo Linux Enhancement Project, in which the Specification Section states:
elibc
is short for Environment_LIBC which points to the LIBC keyword fragment. LIBC is Linux's implementation of a C Standards Library. Since the Standards Library is dependent upon all of the Keywords quoted above, it is set on system-wide basis, and through variable inheritance, a package basis in Gentoo (see/etc/portage/make.profile
which is a symlink to/usr/portage/profiles
, which is set usingeselect profiles
).To produce the above LIBC, my profile contains or inherits:
It's the keywording and enviroment variable USE Flags explained in this GLEP, that make Gentoo so powerful. This system is the main reason I chose Gentoo as my primary distribution, and also the reason I will read and/or attempt to answer every question here tagged
/gentoo
.Once the Keywords and Environment Variables are mixed with the per package USE Flags, the Meta Distribution is created. While there isn't an infinite number of ways a package can be compiled, I can guarantee that every package on a Gentoo system has been affected by a USE Flag in one way or another.
How The Flag Works
To install FreeBSD, you need to use the Handbook provided by FreeBSD to install FreeBSD, and then inside a fresh install use the Gentoo FreeBSD instructions at the Wiki. Doing so adds the following functionality to FreeBSD:
The maintainer of the two packages your question was concerned with has added the option to compile the package on a FreeBSD system. If you aren't on a FreeBSD system then this change doesn't affect you. This was indicated by portage telling you that the flag was masked. You don't need to change anything. For a brief, and I do mean brief, explanation of the difference between FreeBSD and Linux, see HTG Explains: What’s the Difference Between Linux and BSD?.