Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix macOS compilation with FPC >= 3.2.0 #14

Open
wants to merge 1 commit into
base: GL-version
Choose a base branch
from

Conversation

michaliskambi
Copy link

Since FPC 3.2.0, one has to use ObjCBool instead of Boolean, otherwise GLPT compilation fails at various overrides because the methods are declared in ancestor with ObjCBool (not compatible with Pascal Boolean).

E.g. in latest FPC, packages/cocoaint/src/appkit/NSWindow.inc defines

function initWithContentRect_styleMask_backing_defer (contentRect: NSRect; aStyle: NSUInteger; bufferingType: NSBackingStoreType; flag: ObjCBOOL): instancetype; message 'initWithContentRect:styleMask:backing:defer:';

In GLPT, this should be overridden with flag: ObjCBool, not flag: Boolean.

See https://fpcwiki.coderetro.net/User_Changes_3.2.0#objcbase .

Since FPC 3.2.0, one has to use `ObjCBool` instead of `Boolean`, otherwise GLPT compilation fails at various overrides because the methods are declared in ancestor with `ObjCBool` (not compatible with Pascal `Boolean`).

E.g. in latest FPC, `packages/cocoaint/src/appkit/NSWindow.inc` defines

```
function initWithContentRect_styleMask_backing_defer (contentRect: NSRect; aStyle: NSUInteger; bufferingType: NSBackingStoreType; flag: ObjCBOOL): instancetype; message 'initWithContentRect:styleMask:backing:defer:';
```

In GLPT, this should be overridden with `flag: ObjCBool`, not `flag: Boolean`.

See https://fpcwiki.coderetro.net/User_Changes_3.2.0#objcbase .
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant