Some implibs contain code that indirectly includes winnt.h, which in turn contains NtGetCurrentTeb. On arm64 that is implemented by reading a global register variable. Gcc is perfectly fine with that, but clang complains that x18 is not a reserved register on linux.
Signed-off-by: Sasha Finkelstein fnkl.kernel@gmail.com