I found another bug within the Amiga FPC package. Yes, unfortunately, I have forgotten what the others were. These are the worst possible things to debug!
In the unit intuition.pas,
FUNCTION AddGList(window : pWindow; gadget : pGadget; position : ULONG; numGad : LONGINT; requester : pRequester) : WORD;
BEGIN
ASM
MOVE.L A6,-(A7)
MOVEA.L window,A0
MOVEA.L gadget,A1
MOVE.L position,D0
MOVE.L numGad,D1
MOVEA.L requester,A2
MOVEA.L _IntuitionBase,A6
JSR -438(A6)
MOVEA.L (A7)+,A6
MOVE.L D0,@RESULT
END;
END;
Should be:
FUNCTION AddGList(Window:pWindow;Gadget:pGadget;Position:Word;NumGad:Integer;Requester:pRequester):Word;
BEGIN
ASM
MOVE.L A6,-(A7)
MOVEA.L window,A0
MOVEA.L gadget,A1
MOVE.W position,D0
MOVE.W numGad,D1
MOVEA.L requester,A2
MOVEA.L _IntuitionBase,A6
JSR -438(A6)
MOVEA.L (A7)+,A6
MOVE.L D0,@RESULT
END
END;