[Lazarus] GTK3 widgets on macOS?
Ryan Joseph
genericptr at gmail.com
Mon Nov 25 20:18:50 CET 2019
> On Nov 25, 2019, at 2:07 PM, Sven Barth via lazarus <lazarus at lists.lazarus-ide.org> wrote:
>
> You'll likely expect wrong considering that GTK is rather Unix centric and doesn't like to deal with the platformisms of other platforms (both Windows and macOS).
> You'll likely have to look for a libgtk.3.dylib or so and you'll need to adjust the import library names in the GTK3 units.
>
I see in LazGdk3.pas there is a $LINKLIB line which is wrong. On my system at /usr/local/Cellar/gtk+3/3.24.5/lib there is a libgtk-3.dylib which I can link to. I changde these to this:
{$LINKLIB libgtk-3.dylib}
{$LINKLIB libgdk-3.dylib}
I then added -Fl/usr/local/Cellar/gtk+3/3.24.5/lib to the command line but I still get a linker error "Error: ld: library not found for -lgtk-3"
For proof:
ls /usr/local/Cellar/gtk+3/3.24.5/lib
girepository-1.0 libgailutil-3.dylib libgtk-3.0.dylib
gtk-3.0 libgdk-3.0.dylib libgtk-3.dylib
libgailutil-3.0.dylib libgdk-3.dylib pkgconfig
Is that not correct?
Regards,
Ryan Joseph
More information about the lazarus
mailing list