Bug 1445025: Part 1 - Move launcher code into browser/app/winlauncher; r=mhowell
authorAaron Klotz <aklotz@mozilla.com>
Tue, 05 Jun 2018 15:18:13 -0600
changeset 805573 6d5b2000e405ba68971554d6803c02fcc4935f1a
parent 805550 4d7a8d001f087fc500be3b4ca2469310fa39e6be
child 805574 2c97e6fe6c3de829c4972239e9de3b0701d7c939
push id112702
push userbmo:mh+mozilla@glandium.org
push dateFri, 08 Jun 2018 01:32:47 +0000
reviewersmhowell
bugs1445025
milestone62.0a1
Bug 1445025: Part 1 - Move launcher code into browser/app/winlauncher; r=mhowell
browser/app/LaunchUnelevated.cpp
browser/app/LaunchUnelevated.h
browser/app/LauncherProcessWin.cpp
browser/app/LauncherProcessWin.h
browser/app/ProcThreadAttributes.h
browser/app/moz.build
browser/app/winlauncher/LaunchUnelevated.cpp
browser/app/winlauncher/LaunchUnelevated.h
browser/app/winlauncher/LauncherProcessWin.cpp
browser/app/winlauncher/LauncherProcessWin.h
browser/app/winlauncher/ProcThreadAttributes.h
browser/app/winlauncher/moz.build
--- a/browser/app/moz.build
+++ b/browser/app/moz.build
@@ -57,28 +57,29 @@ if CONFIG['ENABLE_GECKODRIVER']:
 if CONFIG['CC_TYPE'] in ('msvc', 'clang-cl'):
     # Always enter a Windows program through wmain, whether or not we're
     # a console application.
     WIN32_EXE_LDFLAGS += ['-ENTRY:wmainCRTStartup']
 
 if CONFIG['OS_ARCH'] == 'WINNT':
     RCINCLUDE = 'splash.rc'
     DEFINES['MOZ_PHOENIX'] = True
-    SOURCES += [
-        'LauncherProcessWin.cpp',
-        'LaunchUnelevated.cpp',
+    DIRS += [
+        'winlauncher',
+    ]
+    USE_LIBS += [
+        'winlauncher',
+    ]
+    LOCAL_INCLUDES += [
+        '/browser/app/winlauncher',
     ]
     DELAYLOAD_DLLS += [
         'oleaut32.dll',
         'ole32.dll',
     ]
-    OS_LIBS += [
-        'oleaut32',
-        'ole32',
-    ]
 
 if CONFIG['MOZ_SANDBOX'] and CONFIG['OS_ARCH'] == 'WINNT':
     # For sandbox includes and the include dependencies those have
     LOCAL_INCLUDES += [
         '/security/sandbox/chromium',
         '/security/sandbox/chromium-shim',
     ]
 
rename from browser/app/LaunchUnelevated.cpp
rename to browser/app/winlauncher/LaunchUnelevated.cpp
rename from browser/app/LaunchUnelevated.h
rename to browser/app/winlauncher/LaunchUnelevated.h
rename from browser/app/LauncherProcessWin.cpp
rename to browser/app/winlauncher/LauncherProcessWin.cpp
rename from browser/app/LauncherProcessWin.h
rename to browser/app/winlauncher/LauncherProcessWin.h
rename from browser/app/ProcThreadAttributes.h
rename to browser/app/winlauncher/ProcThreadAttributes.h
new file mode 100644
--- /dev/null
+++ b/browser/app/winlauncher/moz.build
@@ -0,0 +1,22 @@
+# -*- 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('winlauncher')
+
+FORCE_STATIC_LIB = True
+
+UNIFIED_SOURCES += [
+    'LauncherProcessWin.cpp',
+    'LaunchUnelevated.cpp',
+]
+
+OS_LIBS += [
+    'ntdll',
+    'oleaut32',
+    'ole32',
+]
+
+DisableStlWrapping()