exit status 1 'A0' was not declared in this scope

Another possibility is code in a .cpp file that isn't including Arduino.h