gn.py: Could not find checkout in any parent of the current path. This must be run inside a checkout.

7,207 views
Skip to first unread message

leona...@google.com

unread,
Apr 9, 2018, 4:18:43 PM4/9/18
to Chromium-dev
What should I do to run gn? I keep running into this error. I followed the 2 steps on the setup page

```
$ $ export PATH=$PATH:/path/to/depot_tools
```

But get this error when running `gn`

```
gn.py: Could not find checkout in any parent of the current path.
This must be run inside a checkout.
```

I'm running it inside the cloned depot_tools directory and tried running `git checkout` but still can't seem to run gn.

Dirk Pranke

unread,
Apr 9, 2018, 4:22:17 PM4/9/18
to leona...@google.com, Chromium-dev
gn.py assumes that you have a chromium checkout (or v8 or one of a few other projects) where you have a copy of the "buildtools" repo checked out and you can find .../buildtools/{arch}/gn{.exe}.

depot_tools itself does not have that repo, and so you don't yet have an actual copy of GN to use.

-- Dirk

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To view this discussion on the web visit https://groups.google.com/a/chromium.org/d/msgid/chromium-dev/ea4a4cee-9dae-43d6-8eb2-13a36689f763%40chromium.org.

jam lee

unread,
Apr 16, 2021, 7:22:20 PM4/16/21
to Chromium-dev, Dirk Pranke, Chromium-dev, leona...@google.com
fetch v8
cd v8 ;tar -cvf buildtools.tar buildtools/ cd mydemo; cp ../../v8/v8/buildtools.tar . tar -cvf buildtools.tar buildtools/ gn gen out

Reply all
Reply to author
Forward
0 new messages