added code that can find the base of the program image reliably with and without pie