Bug 1423416 - Remove updatecommon-standalone. r=ted
authorMike Hommey <mh+mozilla@glandium.org>
Wed, 06 Dec 2017 10:47:15 +0900
changeset 395436 9da3d30626a2e8f8be3bde7b79d1948d22f3dc6f
parent 395435 f19a94ec336a442baf631c7e325b605225c710b6
child 395437 1e489f546448d4762df44d484d12910c91d12453
push id98101
push userbtara@mozilla.com
push dateThu, 07 Dec 2017 11:02:38 +0000
treeherdermozilla-inbound@e30c06a1074c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersted
bugs1423416
milestone59.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1423416 - Remove updatecommon-standalone. r=ted Maybe there was a time where both updatecommon and updatecommon-standalone were used in the same configuration, but it's currently not the case. So the distinction between both is not necessary, and updatecommon can just become the standalone version of itself on Windows.
toolkit/components/maintenanceservice/moz.build
toolkit/moz.build
toolkit/mozapps/update/common-standalone/moz.build
toolkit/mozapps/update/common/moz.build
toolkit/mozapps/update/common/sources.mozbuild
toolkit/mozapps/update/moz.build
toolkit/mozapps/update/tests/moz.build
toolkit/mozapps/update/updater/updater-common.build
--- a/toolkit/components/maintenanceservice/moz.build
+++ b/toolkit/components/maintenanceservice/moz.build
@@ -8,24 +8,19 @@ Program('maintenanceservice')
 
 SOURCES += [
     'maintenanceservice.cpp',
     'servicebase.cpp',
     'serviceinstall.cpp',
     'workmonitor.cpp',
 ]
 
-if CONFIG['OS_ARCH'] == 'WINNT':
-    USE_LIBS += [
-        'updatecommon-standalone',
-    ]
-else:
-    USE_LIBS += [
-        'updatecommon',
-    ]
+USE_LIBS += [
+    'updatecommon',
+]
 
 # For debugging purposes only
 #DEFINES['DISABLE_UPDATER_AUTHENTICODE_CHECK'] = True
 
 DEFINES['UNICODE'] = True
 DEFINES['_UNICODE'] = True
 DEFINES['NS_NO_XPCOM'] = True
 
--- a/toolkit/moz.build
+++ b/toolkit/moz.build
@@ -18,22 +18,19 @@ DIRS += [
     'pluginproblem',
     'profile',
     'themes',
 ]
 
 if CONFIG['MOZ_UPDATER'] and CONFIG['MOZ_WIDGET_TOOLKIT'] != 'android':
     DIRS += ['mozapps/update']
 
-if CONFIG['MOZ_MAINTENANCE_SERVICE'] or CONFIG['MOZ_UPDATER'] and CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
-# Including mozapps/update/common-standalone allows the maintenance service
-# to be built so the maintenance service can be used for things other than
-# updating applications.
+if CONFIG['MOZ_MAINTENANCE_SERVICE'] or CONFIG['MOZ_UPDATER']:
     DIRS += [
-        'mozapps/update/common-standalone',
+        'mozapps/update/common',
     ]
 
 if CONFIG['MOZ_MAINTENANCE_SERVICE']:
     DIRS += [
         'components/maintenanceservice'
     ]
 
 DIRS += ['xre']
deleted file mode 100644
--- a/toolkit/mozapps/update/common-standalone/moz.build
+++ /dev/null
@@ -1,12 +0,0 @@
-# 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('updatecommon-standalone')
-
-srcdir = '../common'
-
-include('../common/sources.mozbuild')
-
-if CONFIG['OS_ARCH'] == 'WINNT':
-    USE_STATIC_LIBS = True
--- a/toolkit/mozapps/update/common/moz.build
+++ b/toolkit/mozapps/update/common/moz.build
@@ -21,12 +21,30 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'wind
         EXPORTS += [
             'certificatecheck.h',
             'registrycertificates.h',
         ]
 
 Library('updatecommon')
 
 DEFINES['NS_NO_XPCOM'] = True
+USE_STATIC_LIBS = True
 
-srcdir = '.'
+if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
+    SOURCES += [
+        'pathhash.cpp',
+        'uachelper.cpp',
+        'updatehelper.cpp',
+    ]
+    if CONFIG['MOZ_MAINTENANCE_SERVICE']:
+        SOURCES += [
+            'certificatecheck.cpp',
+            'registrycertificates.cpp',
+        ]
+        OS_LIBS += [
+            'crypt32',
+            'wintrust',
+        ]
 
-include('sources.mozbuild')
+SOURCES += [
+    'readstrings.cpp',
+    'updatecommon.cpp',
+]
deleted file mode 100644
--- a/toolkit/mozapps/update/common/sources.mozbuild
+++ /dev/null
@@ -1,28 +0,0 @@
-# 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/.
-
-sources = []
-
-if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'windows':
-    sources += [
-        'pathhash.cpp',
-        'uachelper.cpp',
-        'updatehelper.cpp',
-    ]
-    if CONFIG['MOZ_MAINTENANCE_SERVICE']:
-        sources += [
-            'certificatecheck.cpp',
-            'registrycertificates.cpp',
-        ]
-        OS_LIBS += [
-            'crypt32',
-            'wintrust',
-        ]
-
-sources += [
-    'readstrings.cpp',
-    'updatecommon.cpp',
-]
-
-SOURCES += sorted(['%s/%s' % (srcdir, s) for s in sources])
--- a/toolkit/mozapps/update/moz.build
+++ b/toolkit/mozapps/update/moz.build
@@ -2,17 +2,16 @@
 # 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/.
 
 XPIDL_MODULE = 'update'
 
 DIRS += [
-    'common',
     'updater',
 ]
 
 XPIDL_SOURCES += [
     'nsIUpdateService.idl',
 ]
 
 TEST_DIRS += ['tests']
--- a/toolkit/mozapps/update/tests/moz.build
+++ b/toolkit/mozapps/update/tests/moz.build
@@ -27,27 +27,23 @@ SimplePrograms([
 ])
 
 LOCAL_INCLUDES += [
     '/toolkit/mozapps/update',
     '/toolkit/mozapps/update/common',
 ]
 
 if CONFIG['OS_ARCH'] == 'WINNT':
-    USE_LIBS += [
-        'updatecommon-standalone',
-    ]
-
     OS_LIBS += [
         'shlwapi',
       ]
-else:
-    USE_LIBS += [
-        'updatecommon',
-    ]
+
+USE_LIBS += [
+    'updatecommon',
+]
 
 for var in ('MOZ_APP_NAME', 'MOZ_APP_BASENAME', 'MOZ_APP_DISPLAYNAME',
             'MOZ_APP_VENDOR', 'BIN_SUFFIX', 'MOZ_DEBUG'):
     DEFINES[var] = CONFIG[var]
 
 DEFINES['NS_NO_XPCOM'] = True
 
 if CONFIG['MOZ_MAINTENANCE_SERVICE']:
--- a/toolkit/mozapps/update/updater/updater-common.build
+++ b/toolkit/mozapps/update/updater/updater-common.build
@@ -28,41 +28,34 @@ if CONFIG['OS_ARCH'] == 'WINNT':
     DEFINES['UNICODE'] = True
     DEFINES['_UNICODE'] = True
     USE_STATIC_LIBS = True
 
     # Pick up nsWindowsRestart.cpp
     LOCAL_INCLUDES += [
         '/toolkit/xre',
     ]
-    USE_LIBS += [
-        'updatecommon-standalone',
-    ]
     OS_LIBS += [
         'comctl32',
         'ws2_32',
         'shell32',
         'shlwapi',
         'crypt32',
         'advapi32',
     ]
 elif CONFIG['OS_ARCH'] == 'Linux' and CONFIG['MOZ_VERIFY_MAR_SIGNATURE']:
     USE_LIBS += [
         'nss',
         'signmar',
-        'updatecommon',
     ]
     OS_LIBS += CONFIG['NSPR_LIBS']
-else:
-    USE_LIBS += [
-        'updatecommon',
-    ]
 
 USE_LIBS += [
     'mar',
+    'updatecommon',
     'xz-embedded',
 ]
 
 if CONFIG['MOZ_SYSTEM_BZ2']:
     OS_LIBS += CONFIG['MOZ_BZ2_LIBS']
 else:
     USE_LIBS += [
         'bz2',