1# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
2# vim: set filetype=python:
3# This Source Code Form is subject to the terms of the Mozilla Public
4# License, v. 2.0. If a copy of the MPL was not distributed with this
5# file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
7FINAL_LIBRARY = "js"
8
9# Includes should be relative to parent path
10LOCAL_INCLUDES += ["!..", ".."]
11
12include("../js-config.mozbuild")
13include("../js-cxxflags.mozbuild")
14
15UNIFIED_SOURCES += [
16    "AllocationLogging.cpp",
17    "AllocPolicy.cpp",
18    "CompleteFile.cpp",
19    "DumpFunctions.cpp",
20    "NativeStack.cpp",
21    "Printf.cpp",
22    "StringBuffer.cpp",
23    "StructuredSpewer.cpp",
24    "Text.cpp",
25    "Unicode.cpp",
26]
27
28# DoubleToString.cpp cannot be built in unified mode because we want to suppress
29#   compiler warnings in third-party dtoa.c.
30# Utility.cpp cannot be built in unified mode because it is needed for
31#   check-vanilla-allocations.
32SOURCES += [
33    "DoubleToString.cpp",
34    "Utility.cpp",
35]
36
37# Suppress warnings in third-party code.
38if CONFIG["CC_TYPE"] in ("clang", "gcc"):
39    SOURCES["DoubleToString.cpp"].flags += ["-Wno-implicit-fallthrough"]
40