Page 1 of 1

Build errors on linux

PostPosted: Tue Sep 10, 2019 6:18 am
by Adriaanse
Trying to make a new JCEF today I encounter build errors on linux. The Windows build works fine.

I am using the same dedicated Ubuntu 14.04 VM I use last March to build JCEF and as the WIki page with instructions for building has not been modified for a few years, i would expect to be able to run the same build steps as before. (https://bitbucket.org/chromiumembedded/ ... uilding.md)

However, after the first step (cmake) runs OK, the second step (make -j4) returns the following errors:

[ 95%] Building CXX object native/CMakeFiles/jcef.dir/string_visitor.cpp.o
[ 96%] Building CXX object native/CMakeFiles/jcef.dir/url_request_client.cpp.o
[ 96%] Building CXX object native/CMakeFiles/jcef.dir/web_plugin_unstable_callback.cpp.o
In file included from /home/user/java-cef/src/native/url_request_client.cpp:5:0:
/home/user/java-cef/src/native/url_request_client.h: In constructor ‘URLRequestClient::URLRequestClient(JNIEnv*, jobject, jobject)’:
/home/user/java-cef/src/native/url_request_client.h:52:25: error: ‘URLRequestClient::client_handle_’ will be initialized after [-Werror=reorder]
ScopedJNIObjectGlobal client_handle_;
^
/home/user/java-cef/src/native/url_request_client.h:51:25: error: ‘ScopedJNIObjectGlobal URLRequestClient::request_handle_’ [-Werror=reorder]
ScopedJNIObjectGlobal request_handle_;
^
/home/user/java-cef/src/native/url_request_client.cpp:16:1: error: when initialized here [-Werror=reorder]
URLRequestClient::URLRequestClient(JNIEnv* env,
^
At global scope:
cc1plus: error: unrecognized command line option "-Wno-undefined-var-template" [-Werror]
cc1plus: all warnings being treated as errors
make[2]: *** [native/CMakeFiles/jcef.dir/url_request_client.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [native/CMakeFiles/jcef.dir/all] Error 2
make: *** [all] Error 2

I hope i am not the only one running into this problem ? I have little experience with cmake and related build tools on linux so i can use some help ?!

Re: Build errors on linux

PostPosted: Tue Sep 10, 2019 10:33 am
by magreenblatt
Thanks for the report. It should be fixed in this commit.

Re: Build errors on linux

PostPosted: Wed Sep 11, 2019 7:39 am
by Adriaanse
magreenblatt wrote:Thanks for the report. It should be fixed in this commit.


Wow, that was fast, thank you so much, the build succeeded this time !