blob: 165f9269e37cdf991334a589b6a3a94353b51f85 [file] [log] [blame]
#!/usr/bin/env python
# Copyright 2017 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
"""Performs some static analysis checks on Chrome debian packages
using lintian.
import argparse
import os
import subprocess
# Google Chrome is not software available on a distro by default,
# so installing to /opt is correct behavior.
# Distros usually don't like libraries to be statically linked
# into binaries because it's easier to push a security patch on a
# single package than to update many packages. Chromium
# statically links some libraries anyway.
# The setuid sandbox is a setuid binary.
# Some nacl binaries are statically linked but don't have "static"
# in their name.
# Build configurations with is_official_build=false don't compress
# the packages.
parser = argparse.ArgumentParser()
parser.add_argument('package', help='path/to/package.deb')
args = parser.parse_args()
package = os.path.abspath(args.package)
cmd = [