To create an ActiveX control (i.e., a more or less graphical control that runs in the space of another process), Delphi uses several techniques: from the RIDL descriptor to then generate the appropriate TLB, and obviously to the link with the operating system.
Obviously, all methods, properties, fields, and so on must comply with the Microsoft COM standard.
Delphi automatically manages every single option, allowing you to fine-tune every single definition.
In the past, I worked extensively on developing complex COM objects for third-party integration (often in C#) because with Delphi, it was relatively simple and effective.
Furthermore, having "very fine-grained" control in Delphi allowed me to update the component with new features while maintaining perfect compatibility with older applications.
If you need some advice (unless someone has already developed some tools in FPC/Lazarus), use Delphi CE to develop something and then try porting it to Lazarus/FPC. Maintenance can then be done manually directly in Lazarus; it involves copying/editing individual fields in the TLB file(s).
Microsoft has significantly advanced the technology, introducing SXS (side-by-side), which allows you to use the ActiveX component without even having to register it.
For ActiveX (called "in-process"), the component must be developed with the same technology (64-bit for 64-bit apps and 32-bit for 32-bit apps), while for COM technology (called "out-process"), you can develop a server (that's what it's called in technical terms) with any technology and use it with any app.
This is summarized in a nutshell.
I don't currently know how actively Microsoft supports ActiveX and COM.