Link error with webkit disabled

First time back working with JUCE in a long time. I see version 5 is out. Small link problem:

If you set the macro JUCE_WEB_BROWSER=0 to avoid webkit (I don’t need it) then the application fails to link with:

In function `juce::JUCEApplicationBase::main(int, char const**, void*)':
include_juce_events.cpp:(.text.startup+0x1ae): undefined reference to `juce::juce_gtkWebkitMain(int, char const**)'

My temporary fix was to add && JUCE_WEB_BROWSER to the #if just prior to that line in JUCEApplicationBase::main().

Same here,
but as i’m trying to build with travis i can’t really change the source code without having to local-copy the modules, and i don’t want to do that.

Moreover, when i enable Web browser, i get this error instead :

In file included from …/…/…/JUCE/modules/juce_gui_extra/juce_gui_extra.cpp:140:
…/…/…/JUCE/modules/juce_gui_extra/native/juce_linux_X11_WebBrowserComponent.cpp:166:69: error:
use of undeclared identifier 'WEBKIT_HARDWARE_ACCELERATION_POLICY_NEVER’
webkit_settings_set_hardware_acceleration_policy (settings, WEBK…

on my local ubuntu VM i can compile just fine, but in travis, with the same packages i can’t get past this error.

Do you know which version of webkit2gtk is right for JUCE 5 ?

Thanks

Thanks for reporting. This is now fixed on develop.

It’s webkit2gtk-4.0. Have a look at this thread for the latest dependencies on linux.

Same issue here on ubuntu 14.04 with libwebkit2gtk-4.0 package installed.

According to this page, the webkit_settings_get_hardware_acceleration_policy () method has been introduced in v2.16 (released last March).

OK this is now fixed on develop. The projucer will now dynamically check for the symbol.

Thanks, it works now :ok_hand: !

Ps: Nothing to do with webit2, but just to point you that you have a duplicate friend class Ref; that produce a warning here.