Hi!
On 7 March 2018 at 20:01, Dan Sinclair <
dsin...@chromium.org> wrote:
> I'm not sure in that case, it's possible our gn files don't set things up so
> it can use the env, or it's possible ninja uses the env in a different
> fashion.
At least for cross-compiling with Yocto we need to create a custom
toolchain file for gn and inject that into the build, just setting
standard environment variables don't seem to help.
We do something very much like this when building pdfium:
https://github.com/OSSystems/meta-browser/blob/master/recipes-browser/chromium/gn-utils.inc
In general it would be nice to get support for a more normal build
system upstream, but I've just assumed that's a no-go so I haven't
submitted any patches for that. I know Qt used to automatically
generate .pri files from the .gyp files to be able to cross-compile
etc. (I'm not sure what they do now that gyp is replaced with gn), and
qtpdfium maintains .pri files by hand, so it's something that would
benefit more projects, though.
--
Martin Sandsmark
Chief Technical Officer
+47 980 33 988
https://remarkable.com
Pilestredet 75c, 0354 Oslo - Norway