Well, labor economics gets complicated more so than general microeconomics. Theoretically, pure competition in the labor market produces a more efficient equilibrium as well when the marginal revenue product of a worker equals his indifference point between the marginal utility of labor and leisure. People work exactly as much as they want and they are paid exactly what they are worth.
The first obvious problem is that marginal revenue product is extremely difficult to measure, and even when it is not, a company's financial performance is not always cleared tied in any meaningful way to labor productivity due to macroeconomic factors. This is fine if we have perfect labor mobility, because like in drankin's hypotheticals, if a company is no longer able to pay what a worker feels he is worth, he can leave. More realistically, there are a huge number of factors constraining labor mobility, such as non-transferable institutional knowledge, moving expenses, and the reality that workers have families that may not want to move or may not be able to move. This is why the federal government subsidizes moving expenses and corporate training expenses, to increase labor mobility and theoretically bring the labor market closer to an efficient equilibrium.
The other problems are usually related to the social costs of unemployment and underemployment, which are born by everybody even if just in the form of neighborhood blight due to homelessness and panhandling in a society that does absolutely nothing to combat it. This is why we have minimum wage laws, subsidized housing, and things like the EITC to make labor worth more to a worker even at low wages. Ideally, though, I think drankin is right that the best way to tackle the problem is to move these costs (since they are social costs) from the employer to society at large. Let employers fire people when they will and pay wages as low as they wish, but subsidize this via direct wealth transfers to individual laborers. The problem there is, even though it's cheaper and more efficient to directly transfer wealth than it is to indirectly subsidize through wage laws and labor protection, it's politically unsellable to just give money to people because it's seen as welfare and unfair to people who are worth more to their employers, who don't realize they're going to pay for it one way or another regardless.
Unfortunately, a place like France kind of employs the worst of both approaches, heavily subsidizing unemployment while also making it near impossible to lose a job, which combine to create historically stable high unemployment and a more systematic and persistent transfer of wealth from workers to non-workers.
To address you specific example, though, I think if in 10 years a company finds it cheaper to move its operations completely, it should be able to do so. Protecting workers at the expense of harming business competitiveness ends up hurting everyone in the long run. However, we shouldn't ignore all of the people that lose their jobs. We should probably pay their moving expenses in full, pay fairly generous but short-term unemployment benefits, and aid them in retraining if that is necessary. But it's better to bear that cost as a social cost than to force businesses to bear it, harming their competitiveness. The problem, again, is that it's probably politically unsellable in the US to be that generous to the unemployed even if it actually allows businesses to be more competitive and make both goods and services and labor markets more efficient. Republicans would attack it as subsidizing laziness and giving an incentive not to work and Democrats would attack it as subsidizing the offshoring of American jobs when in reality it's just allowing businesses to operate more efficiently and freely without destroying the lives of workers.