--snip--
I had same issues when compiling for windows using MingW64; my work around to fix this was to:
edit the gmpecc.c
strike out #include "gmpecc.h"
and remove the code starting with void Point_Doubling...
...
and place it all in keysubtracter.c after :
mpz_t min_range,max_range,diff,TWO,base_key,sum_key,dst_key;
gmp_randstate_t state;
I just tested it and it works for my Debian environment. Nice fix @WanderingPhilospher.