Declare more classes/functions as ABCAPI
Fix compiler error