10.4.11 is the last operating system to support Classic, access to Mac OS 9 applications on an iMac G5.
10.6.8 is the last operating system to support Rosetta, access to applications for Mac OS X on the PowerPC CPU.
10.8 doesn't even support all the same applications as 10.7.4 or earlier. iPhoto 8.1.2 is one of them. It is crucial you correctly identify your Mac and whether or not you depend on Mac OS 9, PowerPC, Universal, or Intel Mac applications.