'Cannot represent relocation type BFD_RELOC_X86_64_GOTPC64

I get this error whenever I try to use -mcmodel=large does anyone know why this is?

I am on Windows 10 using gcc 10.2.0



Solution 1:[1]

I think this was because I was passing it as a compiler flag instead of a linker flag.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Andrew Katson