Building gn from source fails due to hardcoded paths
Reported by
adrian.g...@googlemail.com,
Apr 13 2018
|
|
Issue descriptionUserAgent: Mozilla/5.0 (X11; Linux x86_64; rv:59.0) Gecko/20100101 Firefox/59.0 Steps to reproduce the problem: Building gn from source is not possible since the build system has hard-coded paths: glaubitz@deb4g:/srv/glaubitz$ git clone https://chromium.googlesource.com/chromium/src/tools/gn Cloning into 'gn'... remote: Total 9606 (delta 7047), reused 9606 (delta 7047) Receiving objects: 100% (9606/9606), 2.54 MiB | 7.87 MiB/s, done. Resolving deltas: 100% (7047/7047), done. glaubitz@deb4g:/srv/glaubitz$ cd gn/ glaubitz@deb4g:/srv/glaubitz/gn$ ./bootstrap/bootstrap.py Building gn manually in a temporary directory for bootstrapping... /usr/bin/python: can't open file '/srv/build/write_buildflag_header.py': [Errno 2] No such file or directory Command '['/usr/bin/python', '/srv/build/write_buildflag_header.py', '--output', 'base/synchronization/synchronization_buildflags.h', '--gen-dir', '/tmp/tmpEeGkAa/gen', '--definitions', '/tmp/tmpEeGkAa/gen/base/synchronization/synchronization_buildflags.h.tmp']' returned non-zero exit status 2 glaubitz@deb4g:/srv/glaubitz/gn$ What is the expected behavior? Building a simple C++ like gn from source should be possible on any modern Linux system with a reasonable recent version of gcc which is the case on the Debian unstable where I tested the build. What went wrong? The build script tries to load Python code from a non-existing path, /srv/build. Did this work before? N/A Chrome version: 66.0.3359.26 Channel: n/a OS Version: Debian unstable Flash Version: N/A
,
Apr 30 2018
That's because gn is tied to chromium source code, while not being part of chromium source tree per se (if you download a snapshot of chromium source code, gn won't be in the "tools' subdir). It requires a number of files from the chrome build subdirectory. This is probably one of the reasons why gn is not available as a package in Debian, for exampl. |
|
►
Sign in to add a comment |
|
Comment 1 by dtapu...@chromium.org
, Apr 13 2018