I'm trying to cross-compile my desktop project to a raspberry pi. My projects uses Qt 5.6, and QtWebEngine. I followed this guide: RaspberryPi2EGLFS It runs without the webengine-using parts, but I cannot use the WebEngine module because I cannot compile it. It gives me this:
gyp: Undefined variable clang_dir in /Users/aeron/raspi/qtwebengine/src/core/core_generated.gyp
gyp: Undefined variable clang_dir in /Users/aeron/raspi/qtwebengine/src/core/resources/resources.gyp
Project ERROR: -- running gyp_qtwebengine failed --
I have already tried to manually insert an empty variable, but these two lines are just the tip of the iceberg.
I get to this error too when I grab the full qt5 repository and try to compile it.
Update
I made some progress. With editing qtwebengine/src/core/config/embedded_linux.pri
I managed to solve the clang_dir problem. I've just added the line clang_dir=0
to the end of the list of the variables.
But there is another problem of the same kind:
gyp: Undefined variable c_sources in /Users/aeron/raspi/qtwebengine/src/3rdparty/chromium/third_party/ffmpeg/ffmpeg.gyp
Project ERROR: -- running gyp_qtwebengine failed --
How can I resolve this? Or how can I turn off the ffmpeg part of the webengine, I don't have plans to use it anyway...
Update 2
Now it think I solved the ffmpeg problem. The way: in the file src/3rdparty/chromium/third_party/ffmpeg/ffmpeg.gyp
I set the use_system_ffmpeg to 1.
Now I have a new problem:
Updating projects from gyp files...
gyp: Dependency '/Users/aeron/raspi/qtwebengine/src/3rdparty/chromium/base/base.gyp:symbolize#host' not found while trying to load target /Users/aeron/raspi/qtwebengine/src/3rdparty/chromium/base/base.gyp:base#host
Project ERROR: -- running gyp_qtwebengine failed --
So it still does not compile.