If the fpjsonrtti is a leaf unit (not used by anything else in the FPC (and/or Lazarus in the case of Lazarus) tree:
- compile the units in some directory.
- find the units directory e.g. (fpc/units/i386_win32) and replace the fpjsonrtti.o|ppu with the one generated from the new compile.
If it is not a leaf procedure, put the source in the FPC source dir and rebuild the whole of FPC and Lazarus.
While the quick fix solutions that Thaddy proposes can work, it leads to precompiled copies of units in random places, and this can lead to confusing errors later.
I always try to avoid situations where I have multiple .o/.ppu or sources in the path, and that seriously decreases the number of "strange" problems.