michael@0: # -*- Mode: python; c-basic-offset: 4; indent-tabs-mode: nil; tab-width: 40 -*- michael@0: # vim: set filetype=python: michael@0: # This Source Code Form is subject to the terms of the Mozilla Public michael@0: # License, v. 2.0. If a copy of the MPL was not distributed with this michael@0: # file, You can obtain one at http://mozilla.org/MPL/2.0/. michael@0: michael@0: PROGRAM = 'updater' michael@0: michael@0: SOURCES += [ michael@0: 'archivereader.cpp', michael@0: 'bspatch.cpp', michael@0: 'updater.cpp', michael@0: ] michael@0: michael@0: have_progressui = 0 michael@0: if CONFIG['OS_ARCH'] == 'WINNT': michael@0: have_progressui = 1 michael@0: SOURCES += [ michael@0: 'loaddlls.cpp', michael@0: 'progressui_win.cpp', michael@0: 'win_dirent.cpp', michael@0: ] michael@0: RCINCLUDE = 'updater.rc' michael@0: DEFINES['UNICODE'] = True michael@0: DEFINES['_UNICODE'] = True michael@0: DEFINES['NOMINMAX'] = True michael@0: USE_STATIC_LIBS = True michael@0: michael@0: # Pick up nsWindowsRestart.cpp michael@0: LOCAL_INCLUDES += [ michael@0: '/toolkit/xre', michael@0: ] michael@0: michael@0: if CONFIG['MOZ_ENABLE_GTK']: michael@0: have_progressui = 1 michael@0: SOURCES += [ michael@0: 'progressui_gtk.cpp', michael@0: ] michael@0: michael@0: if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa': michael@0: have_progressui = 1 michael@0: SOURCES += [ michael@0: 'launchchild_osx.mm', michael@0: 'progressui_osx.mm', michael@0: ] michael@0: LDFLAGS += ['-framework Cocoa'] michael@0: elif CONFIG['MOZ_WIDGET_TOOLKIT'] == 'gonk': michael@0: have_progressui = 1 michael@0: SOURCES += [ michael@0: 'automounter_gonk.cpp', michael@0: 'progressui_gonk.cpp', michael@0: ] michael@0: DISABLE_STL_WRAPPING = True michael@0: michael@0: if have_progressui == 0: michael@0: SOURCES += [ michael@0: 'progressui_null.cpp', michael@0: ] michael@0: michael@0: DEFINES['NS_NO_XPCOM'] = True michael@0: DISABLE_STL_WRAPPING = True michael@0: for var in ('MAR_CHANNEL_ID', 'MOZ_APP_VERSION'): michael@0: DEFINES[var] = '"%s"' % CONFIG[var] michael@0: michael@0: LOCAL_INCLUDES += [ michael@0: '../common', michael@0: '/xpcom/glue', michael@0: ] michael@0: michael@0: DELAYLOAD_DLLS += [ michael@0: 'crypt32.dll', michael@0: 'userenv.dll', michael@0: 'wsock32.dll', michael@0: ] michael@0: michael@0: if CONFIG['_MSC_VER']: michael@0: WIN32_EXE_LDFLAGS += ['-ENTRY:wmainCRTStartup'] michael@0: elif CONFIG['OS_ARCH'] == 'WINNT': michael@0: WIN32_EXE_LDFLAGS += ['-municode'] michael@0: michael@0: if CONFIG['MOZ_UPDATE_CHANNEL'] in ('beta', 'release', 'esr'): michael@0: DEFINES['MAR_SIGNING_RELEASE_BETA'] = '1' michael@0: elif CONFIG['MOZ_UPDATE_CHANNEL'] in ('nightly', 'aurora', 'nightly-elm', 'nightly-profiling', 'nightly-oak', 'nightly-ux'): michael@0: DEFINES['MAR_SIGNING_AURORA_NIGHTLY'] = '1'