Commit Graph

14 Commits

Author SHA1 Message Date
Fumitoshi Ukai
a7571b1596 Reland "Reland "Use bundled python to run gn""
This reverts commit 6678906cf8.

Reason for revert:
run gn.py instead of gn on PATH in presubmit check.

Bug: 414312048
Original change's description:
> Revert "Reland "Use bundled python to run gn""
>
> This reverts commit 49fcbee29e.
>
> Reason for revert: This broke a presubmit check in devtools-frontend https://ci.chromium.org/ui/p/devtools-frontend/builders/try/dtf_presubmit_linux/b8715987965894722097/overview
>
> Bug: 414312048
> Original change's description:
> > Reland "Use bundled python to run gn"
> >
> > This reverts commit a3cdfed6c4.
> >
> > Reason for revert:
> > https://chromium-review.googlesource.com/c/chromium/src/+/6498495 landed
> >
> > Original change's description:
> > > Revert "Use bundled python to run gn"
> > >
> > > This reverts commit fa8fc854e1.
> > >
> > > Reason for revert: Most likely culprit for consistent failure
> > > to generate orderfiles (see crbug.com/414312048).
> > >
> > > Bug: 414312048
> > >
> > > Original change's description:
> > > > Use bundled python to run gn
> > > >
> > > > Change-Id: If01a7dae1aca72c93c87c1db27d2d37432094852
> > > > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6490515
> > > > Reviewed-by: Junji Watanabe <jwata@google.com>
> > > > Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
> > > > Auto-Submit: Fumitoshi Ukai <ukai@google.com>
> > > > Commit-Queue: Fumitoshi Ukai <ukai@google.com>
> > >
> > > No-Presubmit: true
> > > No-Tree-Checks: true
> > > No-Try: true
> > > Change-Id: Id5e5f7cec91927aae144026aa16b169689881fb2
> > > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6494846
> > > Owners-Override: Friedrich Hauser <friedrichh@chromium.org>
> > > Auto-Submit: Friedrich Hauser <friedrichh@chromium.org>
> > > Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
> > > Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
> >
> > Bug: 414312048
> > Change-Id: Id04cfe67ed994b91d794e51ba329f411de5d2d36
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6504176
> > Commit-Queue: Fumitoshi Ukai <ukai@google.com>
> > Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
> > Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
> > Reviewed-by: Junji Watanabe <jwata@google.com>
>
> Bug: 414312048
> Change-Id: Iadb3bd20af737c1e7404bf8e95c333f1dbd62942
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6508888
> Commit-Queue: Garrett Beaty <gbeaty@google.com>
> Reviewed-by: Garrett Beaty <gbeaty@google.com>
> Owners-Override: Garrett Beaty <gbeaty@google.com>
> Auto-Submit: Liviu Rau <liviurau@chromium.org>
> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>

Bug: 414312048
Change-Id: I86d611b234bd5b2e91b184c7610c18cfe79f9816
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6515221
Reviewed-by: Junji Watanabe <jwata@google.com>
Auto-Submit: Fumitoshi Ukai <ukai@google.com>
Commit-Queue: Gavin Mak <gavinmak@google.com>
Reviewed-by: Gavin Mak <gavinmak@google.com>
2025-05-08 16:53:39 -07:00
Liviu Rau
6678906cf8 Revert "Reland "Use bundled python to run gn""
This reverts commit 49fcbee29e.

Reason for revert: This broke a presubmit check in devtools-frontend https://ci.chromium.org/ui/p/devtools-frontend/builders/try/dtf_presubmit_linux/b8715987965894722097/overview

Bug: 414312048
Original change's description:
> Reland "Use bundled python to run gn"
>
> This reverts commit a3cdfed6c4.
>
> Reason for revert: 
> https://chromium-review.googlesource.com/c/chromium/src/+/6498495 landed
>
> Original change's description:
> > Revert "Use bundled python to run gn"
> >
> > This reverts commit fa8fc854e1.
> >
> > Reason for revert: Most likley culprit for consistent failure
> > to generate orderfiles (see crbug.com/414312048).
> >
> > Bug: 414312048
> >
> > Original change's description:
> > > Use bundled python to run gn
> > >
> > > Change-Id: If01a7dae1aca72c93c87c1db27d2d37432094852
> > > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6490515
> > > Reviewed-by: Junji Watanabe <jwata@google.com>
> > > Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
> > > Auto-Submit: Fumitoshi Ukai <ukai@google.com>
> > > Commit-Queue: Fumitoshi Ukai <ukai@google.com>
> >
> > No-Presubmit: true
> > No-Tree-Checks: true
> > No-Try: true
> > Change-Id: Id5e5f7cec91927aae144026aa16b169689881fb2
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6494846
> > Owners-Override: Friedrich Hauser <friedrichh@chromium.org>
> > Auto-Submit: Friedrich Hauser <friedrichh@chromium.org>
> > Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
> > Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
>
> Bug: 414312048
> Change-Id: Id04cfe67ed994b91d794e51ba329f411de5d2d36
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6504176
> Commit-Queue: Fumitoshi Ukai <ukai@google.com>
> Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
> Reviewed-by: Junji Watanabe <jwata@google.com>

Bug: 414312048
Change-Id: Iadb3bd20af737c1e7404bf8e95c333f1dbd62942
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6508888
Commit-Queue: Garrett Beaty <gbeaty@google.com>
Reviewed-by: Garrett Beaty <gbeaty@google.com>
Owners-Override: Garrett Beaty <gbeaty@google.com>
Auto-Submit: Liviu Rau <liviurau@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
2025-05-05 10:55:19 -07:00
Fumitoshi Ukai
49fcbee29e Reland "Use bundled python to run gn"
This reverts commit a3cdfed6c4.

Reason for revert: 
https://chromium-review.googlesource.com/c/chromium/src/+/6498495 landed

Original change's description:
> Revert "Use bundled python to run gn"
>
> This reverts commit fa8fc854e1.
>
> Reason for revert: Most likley culprit for consistent failure
> to generate orderfiles (see crbug.com/414312048).
>
> Bug: 414312048
>
> Original change's description:
> > Use bundled python to run gn
> >
> > Change-Id: If01a7dae1aca72c93c87c1db27d2d37432094852
> > Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6490515
> > Reviewed-by: Junji Watanabe <jwata@google.com>
> > Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
> > Auto-Submit: Fumitoshi Ukai <ukai@google.com>
> > Commit-Queue: Fumitoshi Ukai <ukai@google.com>
>
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Change-Id: Id5e5f7cec91927aae144026aa16b169689881fb2
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6494846
> Owners-Override: Friedrich Hauser <friedrichh@chromium.org>
> Auto-Submit: Friedrich Hauser <friedrichh@chromium.org>
> Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
> Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>

Bug: 414312048
Change-Id: Id04cfe67ed994b91d794e51ba329f411de5d2d36
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6504176
Commit-Queue: Fumitoshi Ukai <ukai@google.com>
Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Reviewed-by: Junji Watanabe <jwata@google.com>
2025-04-30 19:26:15 -07:00
Friedrich Hauser
a3cdfed6c4 Revert "Use bundled python to run gn"
This reverts commit fa8fc854e1.

Reason for revert: Most likley culprit for consistent failure
to generate orderfiles (see crbug.com/414312048).

Bug: 414312048

Original change's description:
> Use bundled python to run gn
>
> Change-Id: If01a7dae1aca72c93c87c1db27d2d37432094852
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6490515
> Reviewed-by: Junji Watanabe <jwata@google.com>
> Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
> Auto-Submit: Fumitoshi Ukai <ukai@google.com>
> Commit-Queue: Fumitoshi Ukai <ukai@google.com>

No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Change-Id: Id5e5f7cec91927aae144026aa16b169689881fb2
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6494846
Owners-Override: Friedrich Hauser <friedrichh@chromium.org>
Auto-Submit: Friedrich Hauser <friedrichh@chromium.org>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
2025-04-28 03:33:13 -07:00
Fumitoshi Ukai
fa8fc854e1 Use bundled python to run gn
Change-Id: If01a7dae1aca72c93c87c1db27d2d37432094852
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/6490515
Reviewed-by: Junji Watanabe <jwata@google.com>
Reviewed-by: Takuto Ikuta <tikuta@chromium.org>
Auto-Submit: Fumitoshi Ukai <ukai@google.com>
Commit-Queue: Fumitoshi Ukai <ukai@google.com>
2025-04-28 00:22:14 -07:00
Dirk Pranke
c70750b73e Revert "Call python3.bat explicitly from gn.bat on Windows."
This reverts commit eb28118b7a.

Reason for revert: This broke one of the v8 builders: https://ci.chromium.org/ui/p/devtools-frontend/builders/try/dtf_presubmit_win64/b8835470412847208097/overview, because it assumes that `python3.bat` is in $PATH. We need to change the CL to reference the python3.bat via ~dp0 instead, I think.

Original change's description:
> Call python3.bat explicitly from gn.bat on Windows.
>
> This ensures users running from a linux-style shell call through to
> the right Python interpreter.
>
> Bug: None
> Change-Id: I2e5f2d1a02537ee86f682607670199d37225cf15
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3168710
> Auto-Submit: Jamie Madill <jmadill@chromium.org>
> Commit-Queue: Dirk Pranke <dpranke@google.com>
> Reviewed-by: Dirk Pranke <dpranke@google.com>

Bug: None
Change-Id: I834e828c99e056887e0a84805c4c7a9e67220cfb
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3173633
Auto-Submit: Dirk Pranke <dpranke@google.com>
Commit-Queue: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
Commit-Queue: Dirk Pranke <dpranke@google.com>
Bot-Commit: Rubber Stamper <rubber-stamper@appspot.gserviceaccount.com>
2021-09-21 16:25:20 +00:00
Jamie Madill
eb28118b7a Call python3.bat explicitly from gn.bat on Windows.
This ensures users running from a linux-style shell call through to
the right Python interpreter.

Bug: None
Change-Id: I2e5f2d1a02537ee86f682607670199d37225cf15
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/3168710
Auto-Submit: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Dirk Pranke <dpranke@google.com>
Reviewed-by: Dirk Pranke <dpranke@google.com>
2021-09-20 18:37:26 +00:00
Mirko Bonadei
ea4e399c4d Switch gn wrapper scripts to invoke python3.
Bug: 941669
Change-Id: I515459793f2a406a959c361f9884b183e21ebdf7
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2825439
Reviewed-by: Dirk Pranke <dpranke@google.com>
Commit-Queue: Mirko Bonadei <mbonadei@chromium.org>
2021-04-14 18:05:29 +00:00
Dan Jacques
74809c1b31 [.bat] Remove "depot_tools" override. (#2)
Second attempt at landing. Fix quotes around python in "gclient.bat".

Currently, all ".bat" entry points use "~dp0python" to ensure that the
Python that is used to execute the tool is the one in depot_tools. This
prevents any sort of system override.

Remove this override so that PATH solely determines which Python is
used. To accommodate users who invoked these tools without Python on the
PATH, we still still add "depot_tools" as a catch-all PATH suffix.

Some tools were also not using DOS-style line endings. This CL fixes
this.

BUG=chromium:714293, chromium:724902
TEST=None

Change-Id: I0fceb99c8adb96e72dac706819be032d400aad37
Reviewed-on: https://chromium-review.googlesource.com/521704
Commit-Queue: Daniel Jacques <dnj@chromium.org>
Reviewed-by: Marc-Antoine Ruel <maruel@chromium.org>
Reviewed-by: Scott Graham <scottmg@chromium.org>
Reviewed-by: Nodir Turakulov <nodir@chromium.org>
2017-06-01 21:05:21 +00:00
Daniel Jacques
96fa295ab4 Revert "[.bat] Remove "depot_tools" override."
This reverts commit 2f5f0b7a99.

Reason for revert: <INSERT REASONING HERE>

Original change's description:
> [.bat] Remove "depot_tools" override.
> 
> Currently, all ".bat" entry points use "~dp0python" to ensure that the
> Python that is used to execute the tool is the one in depot_tools. This
> prevents any sort of system override.
> 
> Remove this override so that PATH solely determines which Python is
> used. To accommodate users who invoked these tools without Python on the
> PATH, we still still add "depot_tools" as a catch-all PATH suffix.
> 
> Some tools were also not using DOS-style line endings. This CL fixes
> this.
> 
> BUG=chromium:714293, chromium:724902
> TEST=None
> 
> Change-Id: I06e9583a668c767196a2a335547aded868f2a2b5
> Reviewed-on: https://chromium-review.googlesource.com/517236
> Commit-Queue: Daniel Jacques <dnj@chromium.org>
> Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
> Reviewed-by: Marc-Antoine Ruel <maruel@chromium.org>
> 

TBR=maruel@chromium.org,iannucci@chromium.org,vadimsh@chromium.org,dnj@chromium.org
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
BUG=chromium:714293, chromium:724902

Change-Id: I822abdd4e02abd32d2f4789fb16d5a7f78fdd02d
Reviewed-on: https://chromium-review.googlesource.com/521867
Reviewed-by: Daniel Jacques <dnj@chromium.org>
Commit-Queue: Daniel Jacques <dnj@chromium.org>
2017-06-01 20:44:29 +00:00
Dan Jacques
2f5f0b7a99 [.bat] Remove "depot_tools" override.
Currently, all ".bat" entry points use "~dp0python" to ensure that the
Python that is used to execute the tool is the one in depot_tools. This
prevents any sort of system override.

Remove this override so that PATH solely determines which Python is
used. To accommodate users who invoked these tools without Python on the
PATH, we still still add "depot_tools" as a catch-all PATH suffix.

Some tools were also not using DOS-style line endings. This CL fixes
this.

BUG=chromium:714293, chromium:724902
TEST=None

Change-Id: I06e9583a668c767196a2a335547aded868f2a2b5
Reviewed-on: https://chromium-review.googlesource.com/517236
Commit-Queue: Daniel Jacques <dnj@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
Reviewed-by: Marc-Antoine Ruel <maruel@chromium.org>
2017-06-01 19:48:49 +00:00
Dan Jacques
1b9a43aab3 Remove special Cygwin PATH manipulation from .bat.
Several boilerplate batch files include a provision to prepend
"depot_tools" to PATH prior to running those tools. This undermines
the utility of PATH overrides, since these tools specifically force their
"depot_tools" sub-paths to be used regardless of environment.

The origin of this behavior is likely limited to a specific fix for a
specific problem, but was then perpetuated by the copy/paste of
boilerplate bootstrap code as more bootstraps were added.

This is important in upcoming configurations, where core tools such as
Python and Git will be overridden via PATH on the bots.

Cygwin users who depended on this behavior should just add "depot_tools"
to their PATH in the appropriate location (i.e. in their .bashrc).

BUG=chromium:714293, chromium:724902
TEST=None

Change-Id: Ie948a430847d20326d2411e9296cacd02f83a537
Reviewed-on: https://chromium-review.googlesource.com/510290
Commit-Queue: Daniel Jacques <dnj@chromium.org>
Reviewed-by: Robbie Iannucci <iannucci@chromium.org>
2017-05-24 22:22:52 +00:00
scottmg@chromium.org
28974af759 Add some missing setlocals from various .bat files
Shell PATH was growing quite long in some cases.

R=gab@chromium.org, iannucci@chromium.org, johnw@chromium.org, maruel@chromium.org

Review URL: https://codereview.chromium.org/180303003

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@253347 0039d316-1c4b-4281-b951-d872f2087c98
2014-02-26 04:07:29 +00:00
brettw@chromium.org
67bb861400 Add a wrapper script for GN to depot_tools
This automatically searches the path for a source root (or takes one from the
command line), and then executes the current platform's GN binary inside that
source tree.

This will allow the user to have a "gn" command on their path, and allow our
scripts to run GN without having to bake-in the logic for finding the correct
platform's GN binary.

Review URL: https://codereview.chromium.org/66013002

git-svn-id: svn://svn.chromium.org/chrome/trunk/tools/depot_tools@233983 0039d316-1c4b-4281-b951-d872f2087c98
2013-11-08 20:51:40 +00:00