I am not very familiar with Linux (I am using Lazarus/FPC only under Windows and there is prebuild package, which can be downloaded from above mentioned ftp site).
I think, that you must set in Lazarus Environment/Options paths to FPC 2.5.1 directories ... may be, someone other can be more precise.