"What you say here is absurd! It makes no sense to say "A society that does not violate the principle of fair equality of opportunity can hardly manage to discriminate people in relation to their skin color (that is, treat skin color as a relevant qualification for a social position) if it is also, at the same time, a society that satisfies the difference principle", as you do. For the principle of fair equality of opportunity already rules out the possibility of discrimination on the basis of skin color and one does not need to consider distributive consequences at all. In Rawls, fair equality of opportunity has lexical priority over the difference principle."
This appears correct. But there are some logical difficulties. Rawls's explanation of the principle is the following:
The problem is how one defines what counts as an ability or as a skill in the first place. According to Rawls, the fact that someone has a valuable talent or ability is not a mere "natural" fact: whether something counts as a talent depends from what a society values; and what a society values depends from the kind of institutions that govern it. In a society that is governed by just institution different things would count as talents, than in a society governed by unjust ones.
Those with similar abilities and skills should have similar life chances. More specifically, assuming that there is a distribution of natural assets, those who are at the same level of talent and ability, and have the same willingness to use them, should have the same prospects of success regardless of their initial place in the social system.
It might be claimed that it makes no sense to call skin color an "ability" or a "skill". But what counts as "ability" or "skill" depends very much on the sort of interactions people have. Consider beauty for example: is beauty a "skill"? Well, for certain jobs it certainly counts as one. Now consider a society of white racists where black people are a tiny minority: people in this society might consider blacks not to be beautiful. In a racist society there might be jobs for which beauty is a skill, and since black people are considered ugly (that is, are ugly, relative to that society), black people will not be qualified for positions where beauty is considered a qualification. In this society, black and white people do not have equal chances to occupy the same social positions. This is certainly a bad thing. But is it a violation of fair equality of opportunity, as Rawls defines it? Can one move an objection against it solely by considering the principle of fair equality of opportunity?
If one takes into account imaginary psychologies, the point becomes even clearer. Imagine creatures for whom a strong reactions of fear and disgust against people with a different color of skin is hard-wired, so that it is always more difficult for them to cooperate with a person of a different skin. It follows that in a firm where black people are the majority, the hiring of a white person would be ceteribus paribus less productive than the hiring of a black one. If a majority of black people works in the the majority of firms (just because they are the majority of the population, let us suppose), then a white person would have less chances than a black person to occupy the same social position. In such a society, would this fact constitute a violation of fair equality of opportunity? Would it not be more appropriate to say, for that society, that blackness counts as a skill or as an ability, namely, the ability to cooperate without creating disgust or fear?
The point can be made in a different way: Rawls says that the principle of fair equality of opportunity has lexical priority over the difference principle. What does this means? By lexical priority is usually meant that the principle that has lexical priority has to be satisfied before the other one. Now consider the principle of fair equality of opportunity: what can it mean that it must be satisfied before the difference principle? Perhaps it means that institutions should be designed, first, in such a way that those with similar talents and willingness to apply them will have an equal chance to occupy the same (or similar) social positions; and that one must make sure that this is the case before one considers whether the basic institutional structure of society satisfies the difference principle. The problem with this interpretation is that, in a Rawlsian perspective, it is impossible to say who are people that have similar talents before institutions are in place so that freely interacting people bounded by these institutions can define what they can value as talents in the first place. This is because whether a characteristic counts as a talent or not depends from the decisions taken freely by people legitimately interacting within the boundaries set by just institutions. So there is no way to identify talents prior to the design of a just basic structure. And a just basic structure is one that, among other things, satisfies the difference principle. So, what can count as a talent or as an ability in a JUST society is determined also by the overall shape of its institutions: a talent or an ability in a just society is whatever people end up valuing as a talent or as an ability if they live in a society where individual freedoms are respected, where people with equal talents have equal chances to obtain similar positions, and where cooperation works to the advantage of the worst off members of society (the difference principle).
Since one cannot know what is a talent or an ability before one has designed institutions, the satisfaction of the principle of fair equality of opportunity must be understood as the satisfaction of a formal condition: for anything that counts as an ability or a talent in a given society, people who are born with the same ability or talent and manifest the same willingness to use them should have equal chance to obtain similar social positions, no matter their starting place in society. What I am pointing out is that it is impossible to determine whether the principle of fair equality of opportunity is satisfied by a given institutional arrangement independently from considering whether the difference principle is satisfied.
Let us come back to discrimination against black people. I made an example of a society where black people are considered ugly. In this society it is not clear that a black man's reduced opportunity to occupy places where beautiful people are sought constitutes a violation of fair equality of opportunity. However, it is quite unlikely that a just society can ever be like this. The color of the skin is not correlated to other trait that lead to high marginal productivity, such as organization skills, fantasy, determination, intelligence etc. A productive society is one where people who have such skills occupy places of responsibility and power. It must be a society that treats organization skills, intelligence, determination, etc as talents and abilities. In a regime of fair equality of opportunity, if the population is equally divided into black and whites, this society will have as many black as white people in positions of responsibility and power (since fair equality guarantees that people that have the same talents and will will occupy similar positions, and skin color is not correlated to these talents and will). In such a society it is very psychologically unlikely that people can develop the racist attitudes that bring them to find black people ugly.
What the example shows is that we can discover violations of fair equality of opportunity only after what counts as a talent is defined. But what counts as a talent in a society depends from what will be treated as a valid qualification for a place of responsibility and power in a society where equal liberties and both fair equality of opportunity and the difference people are respected. Only certain combinations of attitudes towards what counts as a talent or as an ability are compatible with all these conditions simultaneously. This ensures for example that discrimination on the basis of skin color will never be legitimate in a just society.
Does that mean that the principle of fair equality of opportunity cannot be lexically prior to the difference principle? I do not agree. I believe that the lexical priority of the principle of fair equality of opportunity over the difference principle must be understood as the priority of a formal "side-constrain". What it tells us is that among all the basic structures of society that satisfy the difference principle (and the equal liberties) the only legitimate ones are those where people that have similar talents (whatever talents are, in those society) have the same chances to occupy similar positions. If people of equal talents and will do not have the same chances of getting to similar positions, despite the class in which they are born and develop until the age of reasons, than that society is unjust, no matter whether cooperation goes to the advantage of the worst off individuals. Notice that to test whether this condition is satisfied one begins by checking whether cooperation satisfies the difference principle (and the equal freedoms) and then rules out as illegitimate all those societies where people that are similar in what counts as a talent or as a qualification in those societies do not have equal chances to occupy similar positions. This is the sense in which fair equality of opportunity has lexical priority.