I'm trying to solve an integer linear program (ILP) in which a constraint of the following kind must be met:
$x_1 \oplus x_2 \oplus \cdots \oplus x_n = 1$
where $\oplus$ is the binary xor operator.
The answer to this question shows how to represent $y = x_1 \oplus x_2$ with linear inequalities. In an answer to this question there is an attempt to generalize the representation to more than two inputs, but the two answers seem to be inconsistent, since the latter doesn't even use inequalities.
So, the question is: how can I represent $y = x_1 \oplus x_2 \oplus \cdots \oplus x_n$ as set of linear inequalities?