CEF3 new project (HELP)

Having problems with building or using CEF's C/C++ APIs? This forum is here to help. Please do not post bug reports or feature requests here.

CEF3 new project (HELP)

Postby JipBoes » Thu Aug 18, 2016 2:58 pm

I'm new to c++ and learning Cmake is on my long todo list so yeeey another newbie asking questions!
I'm trying to create a new project with visual studio and link it against CEF3 to implement it's functionality.
What i'm trying to accomplish is to create a folder with all the dependency's like SFML has it.

Image

SFML has a folder which houses a include folder for all the header files and a lib folder which has all the .lib files.
Then inside the VS project i can link to those files. (http://www.sfml-dev.org/tutorials/2.4/start-vc.php)

Ive been mainly following this tutorial: https://bitbucket.org/chromiumembedded/cef-project
and came this far...
Image
Image

but something is wrong because I get errors in VS which tell me the source files can't be found.
Image

Also something i need to do in the future is link CEF against a shared V8 library since i want to use V8 for scripting in the engine. So if somebody could advice on that +2! Source: http://www.magpcss.org/ceforum/viewtopic.php?f=6&t=11427

Ive been banging my head against the wall for 2 days now so I hope somebody is willing to help me.
I understand this is as frustrating for you (the reader) as for me, because there is a big wiki for CEF3 and believe me I've read it all.
But with my lack of experience I can't seem to figure it out.

Thanks,
Jip
JipBoes
Newbie
 
Posts: 8
Joined: Thu Aug 18, 2016 2:06 pm

Re: CEF3 new project (HELP)

Postby Czarek » Thu Aug 18, 2016 4:03 pm

You cannot change the name of the "include/" directory or its structure and parent directory must be in include path.
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: CEF3 new project (HELP)

Postby JipBoes » Thu Aug 18, 2016 4:41 pm

Aah, took a long break and think I see what you mean. So is there no way to divide the CEF library from my project files ? Ive seen a github which did the same as I am trying to do. https://github.com/aphistic/cef3barebones.

Basically what i'm asking is if there is a Cmake script that can construct such a file structure so I can implement it into my existing project instead of working out of this directory.

Image
JipBoes
Newbie
 
Posts: 8
Joined: Thu Aug 18, 2016 2:06 pm

Re: CEF3 new project (HELP)

Postby magreenblatt » Fri Aug 19, 2016 3:20 am

Yes, you can put all CEF code and binaries into a separate directory. See https://bitbucket.org/chromiumembedded/cef-project as an example.
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm

Re: CEF3 new project (HELP)

Postby JipBoes » Fri Aug 19, 2016 6:05 am

@magreenblatt what part of that page are you referring to ?

Next steps part 2 does nothing closely related for what i'm requesting.

Source:
Image

Result:
Image
JipBoes
Newbie
 
Posts: 8
Joined: Thu Aug 18, 2016 2:06 pm

Re: CEF3 new project (HELP)

Postby magreenblatt » Fri Aug 19, 2016 6:10 am

If what you are trying to do is move CEF headers from "<path>/include/*.h" to "<path>/include/cef/*.h" then that is not supported.
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm

Re: CEF3 new project (HELP)

Postby JipBoes » Fri Aug 19, 2016 6:16 am

So is there something else which can isolate the CEF from my project so I can use CEF as a library/plugin instead of inserting my project as part of the CEF solution ?
JipBoes
Newbie
 
Posts: 8
Joined: Thu Aug 18, 2016 2:06 pm

Re: CEF3 new project (HELP)

Postby magreenblatt » Fri Aug 19, 2016 6:31 am

JipBoes wrote:So is there something else which can isolate the CEF from my project so I can use CEF as a library/plugin instead of inserting my project as part of the CEF solution ?

That is what the above-linked cef-project does. All CEF source code and libraries are placed in a third_party/cef directory.
magreenblatt
Site Admin
 
Posts: 12409
Joined: Fri May 29, 2009 6:57 pm

Re: CEF3 new project (HELP)

Postby JipBoes » Fri Aug 19, 2016 6:58 am

Well thanks i guess, This is what i have now. It's not nearly as tidy as i would like but no linking errors hooray!
Copied cef\cef_binary_3.2704.1427.g95055fe_windows32 from \cef-project\third_party\cef\cef_binary_3.2704.1427.g95055fe_windows32 into root folder of my project.

VS project property's:
Image
Image

Folder "structure"
Image

Include in project file
Image

There is probably still a lot of clean up I can do, Will post when I've done that A.t.m. eager to implement the GUI.
Hope it helps somebody else who got confused like me.

thanks,
Jip
JipBoes
Newbie
 
Posts: 8
Joined: Thu Aug 18, 2016 2:06 pm

Re: CEF3 new project (HELP)

Postby JipBoes » Fri Aug 19, 2016 12:48 pm

The linking horror continues...

Image

So i followed the wiki https://bitbucket.org/chromiumembedded/cef/wiki/LinkingDifferentRunTimeLibraries.
And downloaded the ▶ Minimal Distribution cef_binary_3.2743.1447.g37d988b_windows32_minimal.tar.bz2, unzipped it, mkdir build && cd build and Cmake.

Linked libcef_dll_wrapper to libcef.dll and cef_sandbox.lib.
Image

Then after building got this error:
Image

copied the libcef_dll_wrapper to the project anyway and on compiling got a huge list of errors.
Image

My project now only links against libcef_dll_wrapper.lib and i don't have any of the MT errors anymore. (if i would link against libcef.lib i would get the same errors about libcef.lib)

Hope somebody can help. (Are the image's any good to explain what's going on ?)

thanks,
Jip
JipBoes
Newbie
 
Posts: 8
Joined: Thu Aug 18, 2016 2:06 pm

Next

Return to Support Forum

Who is online

Users browsing this forum: No registered users and 56 guests