servo: Merge #11756 - MSVC support for Servo, and CMake builds for native code (from vvuk:servo-msvc); r=larsbergstrom
This is the base PR for MSVC builds of servo and dependent crates. It's got replacements in the Cargo.toml to pull in the right versions, to make sure that crates were properly converted to CMake for all other platforms, not just Windows. (Servo builds with MSVC 2015 with this PR; also with 2013, though a manual change in rust-mozjs to select a different set of bindings is needed.) This PR isn't quite ready yet, but I want bors-servo to do builds. Source-Repo: https://github.com/servo/servo Source-Revision: ec53136863f20b80caf165d2f15e8a77d614536e
This commit is contained in:
@@ -202,8 +202,9 @@ def check_modeline(file_name, lines):
|
||||
|
||||
|
||||
def check_length(file_name, idx, line):
|
||||
if file_name.endswith(".lock") or file_name.endswith(".json") or file_name.endswith(".html"):
|
||||
raise StopIteration
|
||||
for suffix in [".lock", ".json", ".html", ".toml"]:
|
||||
if file_name.endswith(suffix):
|
||||
raise StopIteration
|
||||
# Prefer shorter lines when shell scripting.
|
||||
if file_name.endswith(".sh"):
|
||||
max_length = 80
|
||||
@@ -297,8 +298,18 @@ def check_lock(file_name, contents):
|
||||
# package names to be neglected (as named by cargo)
|
||||
exceptions = ["lazy_static"]
|
||||
|
||||
import toml
|
||||
content = toml.loads(contents)
|
||||
# toml.py has a bug(?) that we trip up in [metadata] sections;
|
||||
# see https://github.com/uiri/toml/issues/61
|
||||
# This should only affect a very few lines (that have embedded ?branch=...),
|
||||
# and most of them won't be in the repo
|
||||
try:
|
||||
import toml
|
||||
content = toml.loads(contents)
|
||||
except:
|
||||
print "WARNING!"
|
||||
print "WARNING! toml parsing failed for Cargo.lock, but ignoring..."
|
||||
print "WARNING!"
|
||||
raise StopIteration
|
||||
|
||||
packages = {}
|
||||
for package in content.get("package", []):
|
||||
|
||||
Reference in New Issue
Block a user