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: XPCSHELLTESTROOT = $(abspath $(DEPTH))/_tests/xpcshell/$(relativesrcdir) michael@0: CHROMETESTROOT = $(abspath $(DEPTH))/_tests/testing/mochitest/chrome/$(relativesrcdir) michael@0: michael@0: DEFINES += \ michael@0: -DAB_CD=$(AB_CD) \ michael@0: $(NULL) michael@0: michael@0: PP_TARGETS += aus-update-head michael@0: aus-update-head_FLAGS := -Fsubstitution $(DEFINES) $(ACDEFINES) michael@0: aus-update-head := $(srcdir)/unit_aus_update/head_update.js michael@0: aus-update-head_PATH := $(XPCSHELLTESTROOT)/unit_aus_update michael@0: michael@0: INSTALL_TARGETS += xpcshell-data michael@0: xpcshell-data_TARGET := libs michael@0: xpcshell-data_DEST := $(XPCSHELLTESTROOT)/data michael@0: xpcshell-data_FILES := $(wildcard $(srcdir)/data/*) michael@0: michael@0: # Android doesn't use the Mozilla updater or the toolkit update UI michael@0: ifneq (android,$(MOZ_WIDGET_TOOLKIT)) michael@0: INSTALL_TARGETS += base-updater-head michael@0: base-updater-head_TARGET := libs michael@0: base-updater-head_DEST := $(XPCSHELLTESTROOT)/unit_base_updater michael@0: base-updater-head_FILES := $(XPCSHELLTESTROOT)/unit_aus_update/head_update.js michael@0: michael@0: ifdef MOZ_MAINTENANCE_SERVICE michael@0: INSTALL_TARGETS += service-updater-head michael@0: service-updater-head_TARGET := libs michael@0: service-updater-head_DEST := $(XPCSHELLTESTROOT)/unit_service_updater michael@0: service-updater-head_FILES := $(XPCSHELLTESTROOT)/unit_aus_update/head_update.js michael@0: endif # MOZ_MAINTENANCE_SERVICE michael@0: michael@0: ifndef MOZ_PROFILE_GENERATE michael@0: ifdef COMPILE_ENVIRONMENT michael@0: INSTALL_TARGETS += xpcshell-test-helper michael@0: xpcshell-test-helper_TARGET := libs michael@0: xpcshell-test-helper_DEST := $(XPCSHELLTESTROOT)/data michael@0: xpcshell-test-helper_FILES := $(DIST)/bin/TestAUSHelper$(BIN_SUFFIX) michael@0: endif michael@0: endif # Not MOZ_PROFILE_GENERATE michael@0: michael@0: _CHROME_SHARED := \ michael@0: update.sjs \ michael@0: utils.js \ michael@0: $(NULL) michael@0: PP_TARGETS += chrome-shared michael@0: chrome-shared := $(addprefix $(srcdir)/chrome/,$(_CHROME_SHARED)) michael@0: chrome-shared_PATH := $(CHROMETESTROOT)/chrome michael@0: michael@0: _CHROME_DATA := \ michael@0: simple.mar \ michael@0: $(NULL) michael@0: INSTALL_TARGETS += chrome-data michael@0: chrome-data_TARGET := libs michael@0: chrome-data_DEST := $(CHROMETESTROOT)/data michael@0: chrome-data_FILES := $(addprefix $(srcdir)/data/,$(_CHROME_DATA)) michael@0: michael@0: INI_TEST_FILES = \ michael@0: TestAUSReadStrings1.ini \ michael@0: TestAUSReadStrings2.ini \ michael@0: TestAUSReadStrings3.ini \ michael@0: $(NULL) michael@0: michael@0: MOZ_WINCONSOLE = 1 michael@0: michael@0: ifeq ($(OS_ARCH),WINNT) michael@0: LIBS += $(call EXPAND_LIBNAME_PATH,updatecommon-standalone,../common-standalone) michael@0: OS_LIBS += $(call EXPAND_LIBNAME,wintrust shlwapi) michael@0: else michael@0: LIBS += $(call EXPAND_LIBNAME_PATH,updatecommon,../common) michael@0: endif michael@0: michael@0: endif # Not Android michael@0: michael@0: include $(topsrcdir)/config/rules.mk michael@0: michael@0: ifneq (android,$(MOZ_WIDGET_TOOLKIT)) michael@0: # TestAUSReadStrings runs during check in the following directory with a Unicode michael@0: # char in order to test bug 473417 on Windows. michael@0: ifeq ($(OS_ARCH),WINNT) michael@0: bug473417dir = test_bug473417-ó michael@0: else michael@0: bug473417dir = test_bug473417 michael@0: endif michael@0: michael@0: check:: michael@0: $(RM) -rf $(DEPTH)/_tests/updater/ && $(NSINSTALL) -D $(DEPTH)/_tests/updater/$(bug473417dir)/ michael@0: for i in $(INI_TEST_FILES); do \ michael@0: $(INSTALL) $(srcdir)/$$i $(DEPTH)/_tests/updater/$(bug473417dir)/; \ michael@0: done michael@0: $(INSTALL) $(FINAL_TARGET)/TestAUSReadStrings$(BIN_SUFFIX) $(DEPTH)/_tests/updater/$(bug473417dir)/ michael@0: @$(RUN_TEST_PROGRAM) $(DEPTH)/_tests/updater/$(bug473417dir)/TestAUSReadStrings$(BIN_SUFFIX) michael@0: endif # Not Android