Bug 1416989 - Remove mfbt_staticruntime. r?froydnj draft
authorMike Hommey <mh+mozilla@glandium.org>
Tue, 14 Nov 2017 15:55:53 +0900
changeset 697536 6e8c8cc31c68bb2b4847f031b58af60d7b1b1435
parent 697275 c616a6fd5e4b20cca139fcdd3957682afaa862b9
child 740149 472f9b6b204ce594f7ebffafcdaf75fc3ad53cf5
push id89035
push userbmo:mh+mozilla@glandium.org
push dateTue, 14 Nov 2017 06:58:25 +0000
reviewersfroydnj
bugs1416989, 1160285, 1238079
milestone59.0a1
Bug 1416989 - Remove mfbt_staticruntime. r?froydnj The library was added in bug 1160285 for webapprt, and webapprt was removed in bug 1238079.
mfbt/moz.build
mfbt/objs.mozbuild
mfbt/staticruntime/moz.build
--- a/mfbt/moz.build
+++ b/mfbt/moz.build
@@ -4,21 +4,16 @@
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 with Files("**"):
     BUG_COMPONENT = ("Core", "MFBT")
 
 TEST_DIRS += ['tests']
 
-# On win we build two mfbt libs - mfbt linked to crt dlls here and in
-# staticruntime we build a statically linked mfbt lib.
-if CONFIG['OS_ARCH'] == 'WINNT':
-    DIRS += ['staticruntime']
-
 Library('mfbt')
 
 EXPORTS.mozilla = [
     'Alignment.h',
     'AllocPolicy.h',
     'AlreadyAddRefed.h',
     'Array.h',
     'ArrayUtils.h',
@@ -122,35 +117,54 @@ if CONFIG['OS_ARCH'] == 'WINNT':
     EXPORTS.mozilla += [
         'WindowsVersion.h',
     ]
 elif CONFIG['OS_ARCH'] == 'Linux':
     EXPORTS.mozilla += [
         'LinuxSignal.h',
     ]
 
-include('objs.mozbuild')
-
-UNIFIED_SOURCES += mfbt_src_cppsrcs
+UNIFIED_SOURCES += [
+    'Assertions.cpp',
+    'ChaosMode.cpp',
+    'double-conversion/double-conversion/bignum-dtoa.cc',
+    'double-conversion/double-conversion/bignum.cc',
+    'double-conversion/double-conversion/cached-powers.cc',
+    'double-conversion/double-conversion/diy-fp.cc',
+    'double-conversion/double-conversion/double-conversion.cc',
+    'double-conversion/double-conversion/fast-dtoa.cc',
+    'double-conversion/double-conversion/fixed-dtoa.cc',
+    'double-conversion/double-conversion/strtod.cc',
+    'FloatingPoint.cpp',
+    'HashFunctions.cpp',
+    'JSONWriter.cpp',
+    'Poison.cpp',
+    'SHA1.cpp',
+    'TaggedAnonymousMemory.cpp',
+    'Unused.cpp',
+]
 
 DEFINES['IMPL_MFBT'] = True
 
-SOURCES += mfbt_nonunified_src_cppsrcs
+SOURCES += [
+    'Compression.cpp',
+    'decimal/Decimal.cpp',
+]
 
 DisableStlWrapping()
 
 # Suppress warnings in third-party LZ4 code.
 # TODO: Remove these suppressions after bug 993267 is fixed.
 
 if CONFIG['GNU_CXX']:
-    SOURCES['/mfbt/Compression.cpp'].flags += ['-Wno-unused-function']
+    SOURCES['Compression.cpp'].flags += ['-Wno-unused-function']
     CXXFLAGS += ['-Wno-error=shadow']
 
 if CONFIG['CLANG_CXX']:
     # Suppress warnings from third-party V8 Decimal code.
-    SOURCES['/mfbt/decimal/Decimal.cpp'].flags += ['-Wno-implicit-fallthrough']
+    SOURCES['decimal/Decimal.cpp'].flags += ['-Wno-implicit-fallthrough']
 
 if CONFIG['_MSC_VER']:
     # Error 4804 is "'>' : unsafe use of type 'bool' in operation"
-    SOURCES['/mfbt/Compression.cpp'].flags += ['-wd4804']
+    SOURCES['Compression.cpp'].flags += ['-wd4804']
 
 if CONFIG['MOZ_NEEDS_LIBATOMIC']:
     OS_LIBS += ['atomic']
deleted file mode 100644
--- a/mfbt/objs.mozbuild
+++ /dev/null
@@ -1,40 +0,0 @@
-# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
-# vim: set filetype=python:
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-
-mfbt_src_lcppsrcs = [
-    'Assertions.cpp',
-    'ChaosMode.cpp',
-    'double-conversion/double-conversion/bignum-dtoa.cc',
-    'double-conversion/double-conversion/bignum.cc',
-    'double-conversion/double-conversion/cached-powers.cc',
-    'double-conversion/double-conversion/diy-fp.cc',
-    'double-conversion/double-conversion/double-conversion.cc',
-    'double-conversion/double-conversion/fast-dtoa.cc',
-    'double-conversion/double-conversion/fixed-dtoa.cc',
-    'double-conversion/double-conversion/strtod.cc',
-    'FloatingPoint.cpp',
-    'HashFunctions.cpp',
-    'JSONWriter.cpp',
-    'Poison.cpp',
-    'SHA1.cpp',
-    'TaggedAnonymousMemory.cpp',
-    'Unused.cpp',
-]
-
-mfbt_src_cppsrcs = [
-    '/mfbt/%s' % s for s in mfbt_src_lcppsrcs
-]
-
-# Compression.cpp cannot be built in unified mode because it pulls in Windows system headers.
-# Decimal.cpp doesn't build in unified mode with gcc.
-mfbt_nonunified_src_lcppsrcs = [
-    'Compression.cpp',
-    'decimal/Decimal.cpp',
-]
-
-mfbt_nonunified_src_cppsrcs = [
-    '/mfbt/%s' % s for s in mfbt_nonunified_src_lcppsrcs
-]
deleted file mode 100644
--- a/mfbt/staticruntime/moz.build
+++ /dev/null
@@ -1,33 +0,0 @@
-# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
-# vim: set filetype=python:
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-
-Library('mfbt_staticruntime')
-
-LOCAL_INCLUDES += [
-    '/mfbt/double-conversion',
-]
-
-include('../objs.mozbuild')
-
-UNIFIED_SOURCES += mfbt_src_cppsrcs
-
-DEFINES['IMPL_MFBT'] = True
-
-SOURCES += mfbt_nonunified_src_cppsrcs
-
-USE_STATIC_LIBS = True
-
-DisableStlWrapping()
-
-# Suppress warnings in third-party LZ4 code.
-# TODO: Remove these suppressions after bug 993267 is fixed.
-
-if CONFIG['GNU_CXX']:
-    SOURCES['/mfbt/Compression.cpp'].flags += ['-Wno-unused-function']
-
-if CONFIG['_MSC_VER']:
-    # Error 4804 is "'>' : unsafe use of type 'bool' in operation"
-    SOURCES['/mfbt/Compression.cpp'].flags += ['-wd4804']