The actual problem is here:
TPhoto = class(TCamera)
var
// focusdistance : real;
private
You commented out focusdistance.
But that variable is the ONLY one in the var section.
So you also need to comment out the var keyword itself otherwise you are still in the var section when the code continues.
/edit/ Mmmmm. It seems that an empty var is accepted by the compiler.
@georgje can you do the following.
In Lazarus choose Project > Publish project.
Choose a destination directory and remove the "res" from the filter.
Then click ok. It will create a zip with all the relevant files.
Attach it to a post here.
/edit 2/ Rats. I see .res is always included. Grrrr. If the zip is too large, please remove the .res manually.