Running CefGlue on Mac or Linux?

Having problems with building or using the CefGlue .NET/Mono binding? Ask your questions here.

Moderator: fddima

Running CefGlue on Mac or Linux?

Postby alexchandel » Mon Jul 08, 2013 9:07 pm

Hello,

I'm experiencing a problem running CefGlue on OS X. After fixing some bad pathnames to GTK# Assemblies, I compiled all the projects fine (except the WPF ones, but that doesn't matter). When I ran the GTK# (and WinForms) demo initially, I got a "missing libcef" error.

So I downloaded the CEF binaries for OSX, and I copied libcef.dylib, libplugin_carbon_interpose.dylib, and ffmpegsumo.so into the "bin/Debug" directory of each example, and I tried running it again. Now I get this error:

Code: Select all
CefRuntime.ExecuteProcess() returns -1
OnBeforeCommandLineProcessing:  - --lang=en-US --log-file=cef.log --log-severity=verbose --enable-release-dcheck --resources-dir-path=/Users/alex/GitHub/xilium.cefglue/CefGlue.Demo.GtkSharp/bin/Debug --remote-debugging-port=20480 --no-sandbox
[0708/205203:WARNING:resource_bundle.cc(255)] locale_file_path.empty()
[0708/205203:FATAL:main_delegate.cc(440)] Check failed: !loaded_locale.empty(). Locale could not be found for en-US
The application was terminated by a signal: SIGTRAP


Is CEF correctly positioned? Am I calling CEF correctly? Or is this just a bug in CEF?

Background: I'm searching for a solution to embed a webView in a .NET application, in a completely cross-platform fashion, so I can use it as a cross-platform UI framework. .NET because I don't want to c
alexchandel
Newbie
 
Posts: 2
Joined: Mon Jul 08, 2013 8:35 pm

Re: Running CefGlue on Mac or Linux?

Postby alexchandel » Mon Jul 08, 2013 11:45 pm

...completely re-code for every target platform.

An update: I've localized the failure to the call `CefRuntime.Initialize(mainArgs, settings, app)` in `Xilium.CefGlue.Demo.DemoApp.Run()`
alexchandel
Newbie
 
Posts: 2
Joined: Mon Jul 08, 2013 8:35 pm

Re: Running CefGlue on Mac or Linux?

Postby fddima » Thu Jul 11, 2013 3:14 am

Hi.

For first CEF on each platform uses different UI toolkits.
For windows - browser's window it is plain HWND.
For linux - it is GTK's GtkBox*.
For macosx - it is NSView*.
It is probably possible wrap all of them to Gtk# control, current sample control for gtk# works on linux and windows (windows version still require some improvements to correct work), so may be it can be extended to work on osx.

About locales not found - try use similar directory layout as cefclient. May be additional hints will be required.

You can examine this fork https://bitbucket.org/kosyak_nsk/xilium.cefglue . It is little outdated, but kosyak_nsk get it worked on macosx.
Also exist similar issue https://bitbucket.org/xilium/xilium.cef ... mo-project .
fddima
Master
 
Posts: 788
Joined: Tue Dec 07, 2010 6:10 am

Re: Running CefGlue on Mac or Linux?

Postby Czarek » Thu Jul 11, 2013 4:00 am

Regarding the locales problem, on Linux you need to set the path to the locales directory by
setting the "locales_dir_path" option in CefSettings. You also need to set the "resources_dir_path"
option (application directory). Both paths should be absolute. On Windows these options seem to
have default values, but on Linux they seem to be empty.
Maintainer of the CEF Python, PHP Desktop and CEF C API projects. My LinkedIn.
User avatar
Czarek
Virtuoso
 
Posts: 1927
Joined: Sun Nov 06, 2011 2:12 am

Re: Running CefGlue on Mac or Linux?

Postby fddima » Thu Jul 11, 2013 4:05 am

For linux there is done in sample application in cefglue.
fddima
Master
 
Posts: 788
Joined: Tue Dec 07, 2010 6:10 am


Return to CefGlue Forum

Who is online

Users browsing this forum: No registered users and 15 guests