7782 Commits

Author SHA1 Message Date
Mike Hommey
662b0ed7ec Bug 1772036 - Add a mach cargo vet command. r=firefox-build-system-reviewers,ahochheiden
The cargo-vet toolchain is auto-bootstrapped and setup for things to
work properly. We modify `mach vendor rust` to invoke `mach cargo vet`
instead of doing its own setup, but in a underhanded way to work around
bug 1772453.

Differential Revision: https://phabricator.services.mozilla.com/D148218
2022-06-07 20:37:11 +00:00
Mike Hommey
037099a13b Bug 1772036 - Avoid "configure" output from the bootstrap sandbox when using bootstrap_toolchain. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D148217
2022-06-07 20:37:11 +00:00
Mike Hommey
4956da1564 Bug 1772036 - Move toolchain bootstrapping code to some shared module. r=firefox-build-system-reviewers,ahochheiden
We're going to use it to auto-bootstrap cargo-vet in the upcoming `mach
cargo vet` command.

Differential Revision: https://phabricator.services.mozilla.com/D148216
2022-06-07 20:37:11 +00:00
Mike Hommey
1d1d4cc62a Bug 1772980 - Check for unused crates in build/rust. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D148473
2022-06-07 20:34:35 +00:00
Jeff Muizelaar
8f41fc26fe Bug 1772955 - Remove broken ns[Int]Region lldb pretty printers. r=mstange
These were broken with Bas's region rewrite. They seem to just
pretty 'empty' now which is less useful than not having a pretty
printer at all.

Differential Revision: https://phabricator.services.mozilla.com/D148459
2022-06-07 17:16:04 +00:00
Jan-Erik Rediger
8182bee632 Bug 1768834 - Switch to Glean with UniFFI integration r=glandium,chutten
Upgrades to Glean v50.0.1, which comes with a rewritten core and
UniFFI-powered bindings.
Glean has some API changes, so we swap it over to that. Mostly mechanical changes.
Also upgrades to inherent v1.0 in fog.
This matches what Glean uses internally and gets rid of one duplicated crate.

Also upgrades to glean-parser==6.0.1

One crate duplication now (change in `python/mozbuild/mozbuild/vendor/vendor_rust.py` required).
Some new crates now vendored.
These are transitive dependencies of Glean dependencies, all with valid
licenses and already used in other products (mobile).

Differential Revision: https://phabricator.services.mozilla.com/D146062
2022-06-07 12:37:20 +00:00
Mike Hommey
57c2d48e4f Bug 1772960 - Upgrade geckodriver to base64 0.13. r=webdriver-reviewers,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D148460
2022-06-07 09:26:16 +00:00
Geoff Lankow
28e851f616 Bug 1741360 - Fix Thunderbird artifact builds from comm-esr* trees. r=nalexander
Differential Revision: https://phabricator.services.mozilla.com/D147840
2022-06-02 23:09:56 +00:00
ahochheiden
6b662685df Bug 1766497 - Updated a log call to use command_context instead of self (since self would never work in this instance) r=firefox-build-system-reviewers,nalexander
Depends on D142274

Differential Revision: https://phabricator.services.mozilla.com/D148176
2022-06-02 22:15:40 +00:00
ahochheiden
606803ce1d Bug 1761849 - Added missing pathlib conversions in mach.util r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D142274
2022-06-02 22:16:39 +00:00
Nika Layzell
5caf4ef842 Bug 1743020 - Part 2: Vendor the function2 library, r=glandium,mhoye
The function2 library is a header-only library which provides support
for defining move-only function types, similar to the proposed
std::move_only_function in C++23, but with support for additional
customization.

This appears to be the first time we've vendored code using the boost
license, so I've added it to license.html and moz_yaml.py, and have
requested review to ensure it is OK to use code with this license.

Differential Revision: https://phabricator.services.mozilla.com/D145690
2022-06-02 13:24:10 +00:00
Mike Hommey
c88be1e316 Bug 1772035 - Hook cargo vet into rust vendoring lint. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D147821
2022-06-02 06:54:25 +00:00
Mike Hommey
0e3dacb973 Bug 1772043 - Allow duplicate crates when one depends on the other. r=firefox-build-system-reviewers,andi
In bug 1769902, we allowed such duplicate crates when one of them is
under build/rust. This changes the logic to be more generic and allow
a crate duplicate when it depends on a crate of the same name, whether
in build/rust or elsewhere, which could happen for vendored transitional
crates (rare, but happens). This is also a more generic way to handle
our situation with build/rust and doesn't rely on parsing Cargo.toml.

Differential Revision: https://phabricator.services.mozilla.com/D147824
2022-06-02 06:49:18 +00:00
Mike Hommey
b11cccf425 Bug 1771089 - Add a lint-like task to check rust vendoring. r=firefox-build-system-reviewers,linter-reviewers,marco,andi
This is deliberately simple. Future improvements will report if the
vendoring doesn't produce the same content as what's in the tree, and
attach errors to a better location than the first line of Cargo.lock.

Differential Revision: https://phabricator.services.mozilla.com/D147466
2022-06-02 06:42:02 +00:00
ahochheiden
964834abba Bug 1769631 - Remove 'U' from 'mode' parameters for various 'open' calls to ensure Python3.11 compatibility r=firefox-build-system-reviewers,glandium
The 'U' flag represents "universal newline". It has been deprecated
since Python3.3. Since then "universal newline" is the default when a
file is opened in text mode (not bytes). In Python3.11 using the 'U'
flag throws errors. There should be no harm in removing 'U' from 'open'
everywhere it is used, and doing allows the use of Python3.11.

For more reading see: https://docs.python.org/3.11/whatsnew/3.11.html#changes-in-the-python-api

Differential Revision: https://phabricator.services.mozilla.com/D147721
2022-06-02 06:27:44 +00:00
Mike Hommey
46156fb100 Bug 1710421 - [webdriver] Update warp and hyper dependencies. r=mjf,webdriver-reviewers
At the same time, update mdns_service to socket2 0.4 to avoid a duplicate.

Differential Revision: https://phabricator.services.mozilla.com/D147479
2022-06-01 22:05:53 +00:00
Mike Hommey
709d91019f Bug 1710421 - [webdriver] Update time and cookie dependencies. r=webdriver-reviewers,glandium,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D147000
2022-06-01 22:05:53 +00:00
Butkovits Atila
923df44073 Bug 1760161 - lint fix. a=testonly. CLOSED TREE 2022-06-01 21:19:40 +03:00
Simon Farre
dbea53e911 Bug 1760161 - Enhance string & smartptr pretty printers. r=nalexander
Added two additional string types to be pretty printed by the string
pretty printer.

Added the children method to smartpr, which yields 1 child. Has
the added benefit of returning (name, gdb.Value) which can be used
from an IDE with support for Python in GDB.

Differential Revision: https://phabricator.services.mozilla.com/D141404
2022-06-01 17:23:45 +00:00
Marian-Vasile Laza
03a1ff18e4 Backed out 6 changesets (bug 1772068, bug 1710421) for causing multiple web-platform failures. CLOSED TREE
Backed out changeset 7dc183461431 (bug 1772068)
Backed out changeset 437682fe4871 (bug 1772068)
Backed out changeset 717912ea0672 (bug 1772068)
Backed out changeset 6790f990c322 (bug 1772068)
Backed out changeset 33831638ba99 (bug 1710421)
Backed out changeset b35aaa56fa54 (bug 1710421)
2022-06-01 15:01:10 +03:00
Mike Hommey
d50e4bf7f4 Bug 1710421 - [webdriver] Update warp and hyper dependencies. r=mjf,webdriver-reviewers
At the same time, update mdns_service to socket2 0.4 to avoid a duplicate.

Differential Revision: https://phabricator.services.mozilla.com/D147479
2022-06-01 09:57:13 +00:00
Mike Hommey
477fbb9ce7 Bug 1710421 - [webdriver] Update time and cookie dependencies. r=webdriver-reviewers,glandium,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D147000
2022-06-01 09:57:13 +00:00
Marian-Vasile Laza
5d7edc0d2e Backed out 2 changesets (bug 1710421) for causing web-platform failures on context.rs. CLOSED TREE
Backed out changeset bdd6f29ebeeb (bug 1710421)
Backed out changeset 1739da34411f (bug 1710421)
2022-06-01 10:34:41 +03:00
Mike Hommey
2bfc571ce5 Bug 1710421 - [webdriver] Update warp and hyper dependencies. r=mjf,webdriver-reviewers
At the same time, update mdns_service to socket2 0.4 to avoid a duplicate.

Differential Revision: https://phabricator.services.mozilla.com/D147479
2022-06-01 06:44:07 +00:00
Mike Hommey
2edc1ca2ed Bug 1710421 - [webdriver] Update time and cookie dependencies. r=webdriver-reviewers,glandium,whimboo
Differential Revision: https://phabricator.services.mozilla.com/D147000
2022-06-01 06:44:06 +00:00
Mike Hommey
c84e4eef26 Bug 1770894 - Update style to uluru 3.0. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147477
2022-05-31 22:05:05 +00:00
ahochheiden
c69126de73 Bug 1761849 - Removed 'ancestors' function and replaced the only use of it with a Pathlib equivalent r=firefox-build-system-reviewers,mhentges
While testing the change, I noticed that the old implementation also
considered the 'current' path as a part of all ancestors. As such, I
added an additional path component to the path that is immediately
discarded so that the behavior is consistent.

Differential Revision: https://phabricator.services.mozilla.com/D142273
2022-05-31 15:45:24 +00:00
Tom Ritter
823c091aa5 Bug 1770895: Support specifying a blocking bug r=jewilde
Differential Revision: https://phabricator.services.mozilla.com/D147214
2022-05-31 15:43:38 +00:00
ahochheiden
f2d180af99 Bug 1761849 - Removed 'samepath' function and replaced the only use of it with a Pathlib equivalent r=firefox-build-system-reviewers,mhentges
In test_base.py the backslashes had to be replaced with forward slashes,
otherwise the string isn't read properly from the mozconfig during the
test. This was always 'broken', but the test just happened to pass since
the old path comparison was naive.

Differential Revision: https://phabricator.services.mozilla.com/D142272
2022-05-31 03:38:25 +00:00
Mike Hommey
ea29d69603 Bug 1771089 - Report the vendor_rust.py path relative to topsrcdir. r=firefox-build-system-reviewers,andi
Differential Revision: https://phabricator.services.mozilla.com/D147461
2022-05-30 21:54:30 +00:00
Mike Hommey
4206e06896 Bug 1771089 - Fail more gracefully when cargo update/vendor fail during mach vendor rust. r=firefox-build-system-reviewers,ahochheiden
Differential Revision: https://phabricator.services.mozilla.com/D147458
2022-05-30 21:54:29 +00:00
Mike Hommey
2b5ef1f23c Bug 1771089 - Fix typo in extra dupes error message. r=firefox-build-system-reviewers,andi
and clarify we prefer avoiding dupes.

Differential Revision: https://phabricator.services.mozilla.com/D147406
2022-05-30 21:54:29 +00:00
Mike Hommey
7023f65280 Bug 1771089 - Make VendorRust.vendor return a bool rather than hard exit on error. r=firefox-build-system-reviewers,ahochheiden
Differential Revision: https://phabricator.services.mozilla.com/D147403
2022-05-30 21:54:29 +00:00
Mike Hommey
396566d4a1 Bug 1771089 - Error out with a message when cargo is missing. r=firefox-build-system-reviewers,ahochheiden
Differential Revision: https://phabricator.services.mozilla.com/D147402
2022-05-30 21:54:28 +00:00
Mike Hommey
a8a9285375 Bug 1771089 - Properly error out on license errors in mach vendor rust. r=firefox-build-system-reviewers,ahochheiden
Differential Revision: https://phabricator.services.mozilla.com/D147401
2022-05-30 21:54:28 +00:00
Mike Hommey
1b60385e51 Bug 1770894 - Update profiler-helper to object 0.28. r=mstange
Differential Revision: https://phabricator.services.mozilla.com/D147256
2022-05-30 21:37:36 +00:00
Mike Hommey
f686964c71 Bug 1770894 - Force update memmap2 to 0.3. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147255
2022-05-30 21:37:35 +00:00
Mike Hommey
4d1c26ec5d Bug 1770894 - Update cert_storage to base64 0.13. r=keeler
Differential Revision: https://phabricator.services.mozilla.com/D147254
2022-05-30 21:37:35 +00:00
Mike Hommey
f9d9d6369f Bug 1770894 - Force update itertools to 0.10. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147249
2022-05-30 21:37:33 +00:00
Mike Hommey
8f5e659734 Bug 1770894 - Force update cfg-if to 1.0. r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D147248
2022-05-30 21:37:32 +00:00
Cosmin Sabou
3419858c99 Backed out changeset 2ad8e52fa3e6 (bug 1761849) for causing python failures on test_objdir_mismatch. 2022-05-31 00:17:59 +03:00
ahochheiden
026134af4f Bug 1761849 - Removed 'samepath' function and replaced the only use of it with a Pathlib equivalent r=firefox-build-system-reviewers,mhentges
Differential Revision: https://phabricator.services.mozilla.com/D142272
2022-05-30 19:46:22 +00:00
ahochheiden
c9ebd0b85d Bug 1770993 - Remove the .strip() from the MOZCONFIG_SUGGESTION_TEMPLATE so that a newline is output before the shell prompt r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D147485
2022-05-27 18:48:56 +00:00
ahochheiden
efa7c0d842 Bug 1770991 - Added an extra space and removed .strip() so that the spacing between the ./mach bootstrap choice prompt and the choice input matches textual conventions r=dholbert
Differential Revision: https://phabricator.services.mozilla.com/D147486
2022-05-27 18:48:23 +00:00
Nicklas Boman
0832272ff8 Bug 1767204 - NetBSD Bootstrapper r=firefox-build-system-reviewers,glandium,ahochheiden
Differential Revision: https://phabricator.services.mozilla.com/D145186
2022-05-26 20:49:45 +00:00
Bernard Igiri
23156ab69a Bug 1768881 - Created GeneratedFile method implementing HTML Fragment Preprocessor r=firefox-build-system-reviewers,glandium
Created GeneratedFile method implementing HTML Fragment Preprocessor.

Usage in a `moz.build` file will be as follows

```
GeneratedFile(
    "example.js",
    script="/python/mozbuild/mozbuild/action/html_fragment_preprocesor.py",
    entry_point="generate",
    inputs=["example_a.xml", "example_b.xml"],
)
```

Example XML files for testing are in `python/mozbuild/mozbuild/test/action/data/html_fragment_preprocesor/`

Differential Revision: https://phabricator.services.mozilla.com/D146255
2022-05-26 14:37:52 +00:00
ahochheiden
129e18dbac Bug 1771016 - Updated ./mach doctor to check for erroneously enabled Artifact Builds r=sheehan
Differential Revision: https://phabricator.services.mozilla.com/D147219
2022-05-25 18:10:31 +00:00
Raphael Ferrand
c50724ef05 Bug 907297 - improve UI resource_usage r=sylvestre DONTBUILD
Differential Revision: https://phabricator.services.mozilla.com/D146999
2022-05-21 19:23:05 +00:00
Cosmin Sabou
839d232742 Backed out changeset 2ce131c8742e (bug 1768881) for causing python failures on test_html_fragment_preprocessor.py. CLOSED TREE 2022-05-21 22:12:48 +03:00
Bernard Igiri
e887386531 Bug 1768881 - Created GeneratedFile method implementing HTML Fragment Preprocessor r=firefox-build-system-reviewers,glandium
Created GeneratedFile method implementing HTML Fragment Preprocessor.

Usage in a `moz.build` file will be as follows

```
GeneratedFile(
    "example.js",
    script="/python/mozbuild/mozbuild/action/html_fragment_preprocesor.py",
    entry_point="generate",
    inputs=["example_a.xml", "example_b.xml"],
)
```

Example XML files for testing are in `python/mozbuild/mozbuild/test/action/data/html_fragment_preprocesor/`

Differential Revision: https://phabricator.services.mozilla.com/D146255
2022-05-21 18:41:28 +00:00