Page 1 of 1

installing webkitgtk

Posted: Mon Jun 18, 2018 3:25 pm
by raananb
I would like to use wxWebView on Ubuntu 16.04.

I used to have webkitgtk-1.0 but this is no longer the case, and Ubuntu now proposes 'libwebkitgtk-1.0-common'. I guess (hope) it fills the same functions as webkitgtk-1.0.

'configure' looks for webkit-1.0, but this kit is not available. How can I convince configure to accept 'libwebkitgtk-1.0-common' and include wxWebView in the configuration?

Re: installing webkitgtk

Posted: Mon Jun 18, 2018 3:48 pm
by DavidHart

What are you trying to do? To build wxWidgets, configuring with --enable-webview? If so, you probably need to install libwebkitgtk-dev.

Otherwise please give more details about what you wish to build.



Re: installing webkitgtk

Posted: Thu Jun 21, 2018 8:22 am
by raananb
I installed libwebkitgtk-dev, which configure accepts as a webkit. However, the application fails with this kit (it did not with the older webkitgtk-1.0). BTW, gdb also fails, with a segment fault so that I cannot trace where the problem is

I removed libwebkitgtk-dev and installed libwebkitgtk-1.0-0-amd64. configure declares 'webkitgtk not found' & 'webkit not found', and disables wxWebView.

This seems strange, as libwebkitgtk-1.0-0 is the current offering on Ubuntu.

Re: installing webkitgtk

Posted: Thu Jun 21, 2018 9:36 am
by DavidHart
The wx3.1.1 'webview' sample doesn't crash on my ubuntu 16.04 vbox guest. Does it crash for you?
If not, presumably the problem is how your program and libwebkitgtk interact.
This seems strange
Why? If you try to build without the dev package and its dependencies, you want configure to notice and refuse to try to build wx. If configure failed to notice, compilation would fail instead.
BTW, gdb also fails, with a segment fault
What do you mean? Does gdb crash when it starts? Does it crash when debugging other programs (try e.g. the wx 'minimal' sample, then the 'webview' sample)? Or only when debugging your program? Maybe get the latest gdb version; it's easy to build.

Re: installing webkitgtk

Posted: Sat Jun 23, 2018 11:13 am
by raananb
After reinstalling libwebkitgtk-dev everything compiles as expected.

My application (developed with DialogBlocks) requires an access to a https website. since I did not want to delve into https-specific kits, I decided that wxWebView would be sufficient, but that requires to take care of the fact that wxWebView works in an asynch mode.

Basically, I have the url loaded into wxWebView browser, and a timer is launched on a 'DocumnetLoaded' event.

When the page is loaded it is processed to extract the data.

The mechanism works fine in Windows (Visual Studio) and in OSX (compiled with gcc/g++).

Under Ubuntu/GTK, using the same code (copied from the Windows/OSX version) the mechanism fails, and the DocumentLoaded event is not reached. gdb collapses somewhere after the url is loaded.

I have no idea why this happens, and the debugger is not very helpful inasmuch as it must be debugged before it can be of any help.

I finally disabled the functions which use wxWebView in the GTK version.