diff --git a/calendar/.eslintrc.js b/calendar/.eslintrc.js index b7c1ba91d7..29e4c3d0c4 100644 --- a/calendar/.eslintrc.js +++ b/calendar/.eslintrc.js @@ -1,6 +1,9 @@ "use strict"; module.exports = { + "extends": [ + "../../toolkit/.eslintrc.js" + ], "rules": { // Enforce one true brace style (opening brace on the same line) // Allow single line (for now) because of the vast number of changes needed diff --git a/calendar/libical/src/libical/Makefile.in b/calendar/libical/src/libical/Makefile.in index 089f4dbe8f..5241638f53 100644 --- a/calendar/libical/src/libical/Makefile.in +++ b/calendar/libical/src/libical/Makefile.in @@ -54,7 +54,7 @@ CSRCS += \ icalrestriction.c \ $(NULL) -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk ###################################################################### # diff --git a/calendar/lightning/Makefile.in b/calendar/lightning/Makefile.in index 37e4c14852..54be9d9be1 100644 --- a/calendar/lightning/Makefile.in +++ b/calendar/lightning/Makefile.in @@ -15,29 +15,29 @@ DEFINES += -DLIGHTNING_PRERELEASE_VERSION=1 endif # Gecko milestone -GRE_MILESTONE = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build Milestone) +GRE_MILESTONE = $(shell $(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build Milestone) ifdef GRE_MILESTONE DEFINES += -DGRE_MILESTONE=$(GRE_MILESTONE) endif # comm-central source repo and stamp -SOURCE_STAMP ?= $(firstword $(shell hg -R $(topsrcdir) parent --template='{node}\n' 2>/dev/null)) +SOURCE_STAMP ?= $(firstword $(shell hg -R $(commtopsrcdir) parent --template='{node}\n' 2>/dev/null)) ifdef SOURCE_STAMP DEFINES += -DSOURCE_STAMP='$(SOURCE_STAMP)' endif -SOURCE_REPO := $(shell hg -R $(topsrcdir) showconfig paths.default 2>/dev/null | sed -e 's/^ssh:/http:/') +SOURCE_REPO := $(shell hg -R $(commtopsrcdir) showconfig paths.default 2>/dev/null | sed -e 's/^ssh:/http:/') ifdef SOURCE_REPO DEFINES += -DSOURCE_REPO='$(SOURCE_REPO)' endif # Mozilla source repo and stamps -MOZ_SOURCE_STAMP = $(firstword $(shell hg -R $(MOZILLA_SRCDIR) parent --template='{node}\n' 2>/dev/null)) +MOZ_SOURCE_STAMP = $(firstword $(shell hg -R $(moztopsrcdir) parent --template='{node}\n' 2>/dev/null)) ifdef MOZ_SOURCE_STAMP DEFINES += -DMOZ_SOURCE_STAMP='$(MOZ_SOURCE_STAMP)' endif -MOZ_SOURCE_REPO := $(shell hg -R $(MOZILLA_SRCDIR) showconfig paths.default 2>/dev/null | sed -e 's/^ssh:/http:/') +MOZ_SOURCE_REPO := $(shell hg -R $(moztopsrcdir) showconfig paths.default 2>/dev/null | sed -e 's/^ssh:/http:/') ifdef MOZ_SOURCE_REPO DEFINES += -DMOZ_SOURCE_REPO='$(MOZ_SOURCE_REPO)' endif @@ -60,10 +60,10 @@ DEFINES += -DTHUNDERBIRD_VERSION=$(THUNDERBIRD_VERSION) \ -DXPI_EM_ID="$(XPI_EM_ID)" \ $(NULL) -MOZ_BUILDID = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(DIST)/bin/application.ini App BuildID) +MOZ_BUILDID = $(shell $(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py $(DIST)/bin/application.ini App BuildID) DEFINES += -DMOZ_BUILDID=$(MOZ_BUILDID) -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk include $(srcdir)/versions.mk include $(srcdir)/lightning-packager.mk include $(srcdir)/lightning-tests.mk @@ -72,17 +72,17 @@ include $(srcdir)/lightning-tests.mk # copy if the files doesn't exist. repack-process-extrafiles: lightning-extrafiles lightning-extrafiles: LTN_ABCD_L10NJS=$(call EXPAND_LOCALE_SRCDIR,calendar/locales)/lightning-l10n.js -lightning-extrafiles: LTN_ANY_L10NJS=$(if $(wildcard $(LTN_ABCD_L10NJS)),$(LTN_ABCD_L10NJS),$(topsrcdir)/calendar/locales/en-US/lightning-l10n.js) +lightning-extrafiles: LTN_ANY_L10NJS=$(if $(wildcard $(LTN_ABCD_L10NJS)),$(LTN_ABCD_L10NJS),$(commtopsrcdir)/calendar/locales/en-US/lightning-l10n.js) lightning-extrafiles: $(call py_action,preprocessor,$(PREF_PPFLAGS) $(DEFINES) $(ACDEFINES) $(XULPPFLAGS) $(LTN_ANY_L10NJS) -o $(DIST)/xpi-stage/$(L10N_XPI_NAME)/$(PREF_DIR)/lightning-l10n.js) ident: @printf 'comm_revision ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(FINAL_TARGET)/app.ini App SourceStamp @printf 'moz_revision ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(FINAL_TARGET)/app.ini Build SourceStamp @printf 'buildid ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(FINAL_TARGET)/app.ini App BuildID diff --git a/calendar/lightning/jar.mn b/calendar/lightning/jar.mn index 81aa8b7cd1..b91f01fda1 100644 --- a/calendar/lightning/jar.mn +++ b/calendar/lightning/jar.mn @@ -104,17 +104,17 @@ lightning.jar: calendar.jar: - content/calendar/calendarCreation.xul (/calendar/resources/content/calendarCreation.xul) - content/calendar/calendarCreation.js (/calendar/resources/content/calendarCreation.js) - content/calendar/datetimepickers/datetimepickers.css (/calendar/resources/content/datetimepickers/datetimepickers.css) - content/calendar/datetimepickers/datetimepickers.xml (/calendar/resources/content/datetimepickers/datetimepickers.xml) - content/calendar/mouseoverPreviews.js (/calendar/resources/content/mouseoverPreviews.js) - content/calendar/publish.js (/calendar/resources/content/publish.js) - content/calendar/publishDialog.js (/calendar/resources/content/publishDialog.js) - content/calendar/publishDialog.xul (/calendar/resources/content/publishDialog.xul) - content/calendar/sound.wav (/calendar/resources/content/sound.wav) - ../skin/lightning-common/datetimepickers.css (/calendar/resources/skin/datetimepickers.css) - ../skin/lightning-common/dialogOverlay.css (/calendar/resources/skin/dialogOverlay.css) + content/calendar/calendarCreation.xul (../resources/content/calendarCreation.xul) + content/calendar/calendarCreation.js (../resources/content/calendarCreation.js) + content/calendar/datetimepickers/datetimepickers.css (../resources/content/datetimepickers/datetimepickers.css) + content/calendar/datetimepickers/datetimepickers.xml (../resources/content/datetimepickers/datetimepickers.xml) + content/calendar/mouseoverPreviews.js (../resources/content/mouseoverPreviews.js) + content/calendar/publish.js (../resources/content/publish.js) + content/calendar/publishDialog.js (../resources/content/publishDialog.js) + content/calendar/publishDialog.xul (../resources/content/publishDialog.xul) + content/calendar/sound.wav (../resources/content/sound.wav) + ../skin/lightning-common/datetimepickers.css (../resources/skin/datetimepickers.css) + ../skin/lightning-common/dialogOverlay.css (../resources/skin/dialogOverlay.css) ../skin/lightning-common/imip.css (themes/common/imip.css) ../skin/lightning-common/lightning.css (themes/common/lightning.css) ../skin/lightning-common/lightning-toolbar.css (themes/common/lightning-toolbar.css) diff --git a/calendar/lightning/lightning-packager.mk b/calendar/lightning/lightning-packager.mk index cfc23c98aa..a41c20531f 100644 --- a/calendar/lightning/lightning-packager.mk +++ b/calendar/lightning/lightning-packager.mk @@ -17,7 +17,7 @@ # LIGHTNING_VERSION = 2.2 # Will be used to replace the Thunderbird version # # in POST_UPLOAD_CMD -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/package-name.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/package-name.mk XPI_STAGE_PATH = $(DIST)/xpi-stage _ABS_XPI_STAGE_PATH = $(ABS_DIST)/xpi-stage @@ -58,7 +58,7 @@ $(XPI_ZIP_IN): ensure-stage-dir L10N_TARGET = $(XPI_STAGE_PATH)/$(XPI_NAME)-$(AB_CD) # function print_ltnconfig(section,configname) -print_ltnconfig = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(XPI_STAGE_PATH)/$(XPI_NAME)/app.ini $1 $2) +print_ltnconfig = $(shell $(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py $(XPI_STAGE_PATH)/$(XPI_NAME)/app.ini $1 $2) wget-en-US: ifeq (thunderbird,$(MOZ_APP_NAME)) @@ -88,9 +88,9 @@ langpack-en-US: merge-%: AB_CD=$* merge-%: $(RM) -rf $(REAL_LOCALE_MERGEDIR)/calendar - $(MOZILLA_SRCDIR)/mach compare-locales \ + $(moztopsrcdir)/mach compare-locales \ --merge $(REAL_LOCALE_MERGEDIR)/.. \ - $(topsrcdir)/calendar/locales/l10n.toml \ + $(commtopsrcdir)/calendar/locales/l10n.toml \ $(L10NBASEDIR) \ $* @@ -167,7 +167,7 @@ upload-%: AB_CD=$* upload-%: LTN_UPLOAD_CMD := $(patsubst $(THUNDERBIRD_VERSION)%,$(LIGHTNING_VERSION),$(subst thunderbird,calendar/lightning,$(POST_UPLOAD_CMD))) upload-%: stage-upload-% POST_UPLOAD_CMD="$(LTN_UPLOAD_CMD)" \ - $(PYTHON) $(MOZILLA_DIR)/build/upload.py --base-path $(DIST) \ + $(PYTHON) $(moztopsrcdir)/build/upload.py --base-path $(DIST) \ --properties-file $(DIST)/$(XPI_NAME)_build_properties.json \ "$(DIST)/$(MOZ_PKG_PLATFORM)/$(XPI_PKGNAME).xpi" diff --git a/calendar/lightning/lightning-tests.mk b/calendar/lightning/lightning-tests.mk index 334ca67691..e004b963d6 100644 --- a/calendar/lightning/lightning-tests.mk +++ b/calendar/lightning/lightning-tests.mk @@ -18,6 +18,6 @@ stage-extension: # name conflicts between calendar/ and mail/ stage-mozmill: $(NSINSTALL) -D $(PKG_STAGE)/mozmill/shared-modules - (cd $(topsrcdir)/calendar/test/mozmill && tar $(TAR_CREATE_FLAGS) - `cat $(topsrcdir)/calendar/test/mozmill/mozmilltests.list`) | (cd $(PKG_STAGE)/mozmill && tar -xf -) - (cd $(topsrcdir)/calendar/test/mozmill/shared-modules && tar $(TAR_CREATE_FLAGS) - *) | (cd $(PKG_STAGE)/mozmill/shared-modules && tar -xf -) - $(call py_action,buildlist,$(PKG_STAGE)/mozmill/mozmilltests.list $(shell cat $(topsrcdir)/calendar/test/mozmill/mozmilltests.list)) + (cd $(commtopsrcdir)/calendar/test/mozmill && tar $(TAR_CREATE_FLAGS) - `cat $(commtopsrcdir)/calendar/test/mozmill/mozmilltests.list`) | (cd $(PKG_STAGE)/mozmill && tar -xf -) + (cd $(commtopsrcdir)/calendar/test/mozmill/shared-modules && tar $(TAR_CREATE_FLAGS) - *) | (cd $(PKG_STAGE)/mozmill/shared-modules && tar -xf -) + $(call py_action,buildlist,$(PKG_STAGE)/mozmill/mozmilltests.list $(shell cat $(commtopsrcdir)/calendar/test/mozmill/mozmilltests.list)) diff --git a/calendar/lightning/locales/Makefile.in b/calendar/lightning/locales/Makefile.in index 1ef5dd430e..c078978645 100644 --- a/calendar/lightning/locales/Makefile.in +++ b/calendar/lightning/locales/Makefile.in @@ -4,7 +4,7 @@ # Setting this to calendar/locales sets up LOCALE_SRCDIR to the correct locale # directory -relativesrcdir = calendar/locales +relativesrcdir = $(commreltopsrcdir)/calendar/locales DEFINES += -DTHEME=$(THEME) \ -DLOCALE_SRCDIR=$(LOCALE_SRCDIR) \ diff --git a/calendar/lightning/versions.mk b/calendar/lightning/versions.mk index fb2aad267e..bfe40edd86 100644 --- a/calendar/lightning/versions.mk +++ b/calendar/lightning/versions.mk @@ -3,16 +3,16 @@ # file, You can obtain one at http://mozilla.org/MPL/2.0/. # Lighting version number -THUNDERBIRD_VERSION := $(shell cat $(topsrcdir)/mail/config/version.txt) -SEAMONKEY_VERSION := $(shell cat $(topsrcdir)/suite/config/version.txt) +THUNDERBIRD_VERSION := $(shell cat $(commtopsrcdir)/mail/config/version.txt) +SEAMONKEY_VERSION := $(shell cat $(commtopsrcdir)/suite/config/version.txt) ifdef MOZ_SUITE -LIGHTNING_VERSION := $(shell $(PYTHON) $(topsrcdir)/calendar/lightning/build/makeversion.py $(THUNDERBIRD_VERSION)) +LIGHTNING_VERSION := $(shell $(PYTHON) $(commtopsrcdir)/calendar/lightning/build/makeversion.py $(THUNDERBIRD_VERSION)) else -LIGHTNING_VERSION := $(shell $(PYTHON) $(topsrcdir)/calendar/lightning/build/makeversion.py $(word 1,$(MOZ_PKG_VERSION) $(THUNDERBIRD_VERSION))) +LIGHTNING_VERSION := $(shell $(PYTHON) $(commtopsrcdir)/calendar/lightning/build/makeversion.py $(word 1,$(MOZ_PKG_VERSION) $(THUNDERBIRD_VERSION))) endif -GDATA_VERSION := $(shell $(PYTHON) $(topsrcdir)/calendar/providers/gdata/makeversion.py $(LIGHTNING_VERSION)) +GDATA_VERSION := $(shell $(PYTHON) $(commtopsrcdir)/calendar/providers/gdata/makeversion.py $(LIGHTNING_VERSION)) # For extensions we require a max version that is compatible across security releases. # THUNDERBIRD_MAXVERSION and SEAMONKEY_MAXVERSION is our method for doing that. diff --git a/calendar/providers/gdata/Makefile.in b/calendar/providers/gdata/Makefile.in index d5f97d5918..647cc3fdbb 100644 --- a/calendar/providers/gdata/Makefile.in +++ b/calendar/providers/gdata/Makefile.in @@ -28,6 +28,6 @@ stage-package: $(NSINSTALL) -D $(PKG_STAGE)/extensions/$(XPI_EM_ID) (cd $(FINAL_TARGET) && tar $(TAR_CREATE_FLAGS) - *) | (cd $(PKG_STAGE)/extensions/$(XPI_EM_ID) && tar -xf -) -include $(topsrcdir)/config/rules.mk -include $(topsrcdir)/calendar/lightning/versions.mk -include $(topsrcdir)/calendar/lightning/lightning-packager.mk +include $(moztopsrcdir)/config/rules.mk +include $(commtopsrcdir)/calendar/lightning/versions.mk +include $(commtopsrcdir)/calendar/lightning/lightning-packager.mk diff --git a/calendar/providers/gdata/locales/Makefile.in b/calendar/providers/gdata/locales/Makefile.in index f307792b5e..1c173e549f 100644 --- a/calendar/providers/gdata/locales/Makefile.in +++ b/calendar/providers/gdata/locales/Makefile.in @@ -4,6 +4,6 @@ # Setting this to calendar/locales sets up LOCALE_SRCDIR to the correct locale # directory -relativesrcdir = calendar/locales +relativesrcdir = $(commreltopsrcdir)/calendar/locales DEFINES += -DLOCALE_SRCDIR=$(LOCALE_SRCDIR) diff --git a/calendar/test/mozmill/Makefile.in b/calendar/test/mozmill/Makefile.in index b4c22dc1cd..551ad1e056 100644 --- a/calendar/test/mozmill/Makefile.in +++ b/calendar/test/mozmill/Makefile.in @@ -25,7 +25,7 @@ endif check-no-solo = $(foreach solo,SOLO_TEST SOLO_FILE,$(if $($(solo)),$(error $(subst SOLOVAR,$(solo),$(1))))) find-solo-test = $(if $(and $(SOLO_TEST),$(SOLO_FILE)),$(error Both SOLO_TEST and SOLO_FILE are specified. You may only specify one.),$(if $(SOLO_TEST),$(SOLO_TEST),$(if $(SOLO_FILE),$(SOLO_FILE),$(error SOLO_TEST or SOLO_FILE needs to be specified.)))) -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk # Calendar uses both its own shared modules and those from Thunderbird. Since # the build system and mozmill is not set up to include files from two different @@ -38,7 +38,7 @@ mozmill-stage: $(MOZMILL_SHARED) $(INSTALL) -D $(MOZMILL_STAGE_SHARED) $(INSTALL) $(addprefix $(srcdir)/,$(shell cat $(srcdir)/mozmilltests.list)) $(MOZMILL_STAGE) - $(INSTALL) $(wildcard $(topsrcdir)/mail/test/mozmill/shared-modules/*.js) $(MOZMILL_STAGE_SHARED) + $(INSTALL) $(wildcard $(commtopsrcdir)/mail/test/mozmill/shared-modules/*.js) $(MOZMILL_STAGE_SHARED) $(INSTALL) $(wildcard $(srcdir)/shared-modules/*.js) $(MOZMILL_STAGE_SHARED) mozmill: mozmill-stage diff --git a/calendar/timezones/Makefile.in b/calendar/timezones/Makefile.in index 444b268eae..99c7bed0a6 100644 --- a/calendar/timezones/Makefile.in +++ b/calendar/timezones/Makefile.in @@ -4,12 +4,12 @@ XPI_PKGNAME = calendar-timezones-$(TIMEZONES_VERSION) -THUNDERBIRD_VERSION := $(shell cat $(topsrcdir)/mail/config/version.txt) -SEAMONKEY_VERSION := $(shell cat $(topsrcdir)/suite/config/version.txt) -CALENDAR_VERSION := $(shell $(PYTHON) $(topsrcdir)/calendar/lightning/build/makeversion.py $(word 1,$(MOZ_PKG_VERSION) $(THUNDERBIRD_VERSION))) +THUNDERBIRD_VERSION := $(shell cat $(commtopsrcdir)/mail/config/version.txt) +SEAMONKEY_VERSION := $(shell cat $(commtopsrcdir)/suite/config/version.txt) +CALENDAR_VERSION := $(shell $(PYTHON) $(commtopsrcdir)/calendar/lightning/build/makeversion.py $(word 1,$(MOZ_PKG_VERSION) $(THUNDERBIRD_VERSION))) TIMEZONES_VERSION := $(shell $(PYTHON) $(srcdir)/version.py) -relativesrcdir = calendar/locales +relativesrcdir = $(commreltopsrcdir)/calendar/locales DEFINES += -DTHUNDERBIRD_VERSION=$(THUNDERBIRD_VERSION) \ -DSEAMONKEY_VERSION=$(SEAMONKEY_VERSION) \ diff --git a/comm-confvars.sh b/comm-confvars.sh new file mode 100644 index 0000000000..1a02de9cb3 --- /dev/null +++ b/comm-confvars.sh @@ -0,0 +1,20 @@ +#!/bin/sh + +if [[ "$MOZ_BUILD_APP" == *comm* ]] +then + # we are building with comm/ as the subdirectory + # $srcdir is the mozilla repo, comm is in the subdir + moztopsrcdir=$srcdir + commtopsrcdir=$srcdir/comm + + mozreltopsrcdir=. + commreltopsrcdir=comm +else + # we are building with mozilla/ as the subdirectory + # $srcdir is still the mozilla repo, so use the parent for comm + moztopsrcdir=$srcdir + commtopsrcdir=$srcdir/.. + + mozreltopsrcdir=mozilla + commreltopsrcdir=. +fi diff --git a/im/Makefile.in b/im/Makefile.in index 0afeeea44b..2dfd39f7cd 100644 --- a/im/Makefile.in +++ b/im/Makefile.in @@ -3,7 +3,7 @@ # 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/. -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk ifdef MAKENSISU # For Windows build the uninstaller during the application build since the @@ -17,7 +17,7 @@ endif # platform.ini are the same, which isn't a problem for Firefox, but # it's not right for anything else. So we correct platform.ini here. -MOZ_REV=$(shell hg -R "$(MOZILLA_SRCDIR)" parent --template="{node}" 2>/dev/null) +MOZ_REV=$(shell hg -R "$(moztopsrcdir)" parent --template="{node}" 2>/dev/null) libs:: $(DIST)/bin/platform.ini sed -e "s/^\(SourceStamp=\).*/\1$(MOZ_REV)/" $(DIST)/bin/platform.ini \ diff --git a/im/app-config.mk b/im/app-config.mk new file mode 100644 index 0000000000..0d3d6bd3f0 --- /dev/null +++ b/im/app-config.mk @@ -0,0 +1,9 @@ +# 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/. + +ifeq ($(findstring comm,$(MOZ_BUILD_APP)),) +COMMDEPTH = $(DEPTH) +else +COMMDEPTH = $(DEPTH)/comm +endif diff --git a/im/app.mozbuild b/im/app.mozbuild index 6c1bd713dc..e7a4311a23 100644 --- a/im/app.mozbuild +++ b/im/app.mozbuild @@ -6,11 +6,11 @@ include('/toolkit/toolkit.mozbuild') DIRS += [ '/%s' % CONFIG['MOZ_BRANDING_DIRECTORY'], - '/chat', + '/%s/chat' % CONFIG['commreltopsrcdir'] ] # Ensure extensions are built after chat/ so purplexpcom can build. if CONFIG['MOZ_EXTENSIONS']: DIRS += ['/extensions'] -DIRS += ['/im'] +DIRS += ['/%s/im' % CONFIG['commreltopsrcdir']] diff --git a/im/app/Makefile.in b/im/app/Makefile.in index b8e4683074..fa47bdcffb 100644 --- a/im/app/Makefile.in +++ b/im/app/Makefile.in @@ -4,10 +4,10 @@ AB_CD = $(MOZ_UI_LOCALE) -GRE_MILESTONE = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build Milestone) -MOZ_BUILDID = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build BuildID) +GRE_MILESTONE = $(shell $(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build Milestone) +MOZ_BUILDID = $(shell $(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build BuildID) -LICENSE_TXT_FILE = $(topsrcdir)/im/LICENSE.txt +LICENSE_TXT_FILE = $(commtopsrcdir)/im/LICENSE.txt DEFINES += \ -DINSTANTBIRD_ICO=\"$(DIST)/branding/instantbird.ico\" \ @@ -27,7 +27,7 @@ endif # shouldn't get 755 perms need $(IFLAGS1) for either way of calling nsinstall. NSDISTMODE = copy -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk # If we are trying to show an error dialog about the lack of SSE2 support, # make sure that code itself doesn't use SSE2. @@ -44,14 +44,14 @@ ifeq ($(OS_ARCH),WINNT) png2ico = $(PYTHON) $(srcdir)/png2ico.py $(1) $(2) $(3) $(4) $(5) # Extract the icons we care about embedding into the EXE -available-16.ico: $(topsrcdir)/chat/themes/available-16.png $(srcdir)/png2ico.py - $(call png2ico,$(topsrcdir)/chat/themes/available-16.png,0,0,16,available-16.ico) +available-16.ico: $(commtopsrcdir)/chat/themes/available-16.png $(srcdir)/png2ico.py + $(call png2ico,$(commtopsrcdir)/chat/themes/available-16.png,0,0,16,available-16.ico) -away-16.ico: $(topsrcdir)/chat/themes/away-16.png $(srcdir)/png2ico.py - $(call png2ico,$(topsrcdir)/chat/themes/away-16.png,0,0,16,away-16.ico) +away-16.ico: $(commtopsrcdir)/chat/themes/away-16.png $(srcdir)/png2ico.py + $(call png2ico,$(commtopsrcdir)/chat/themes/away-16.png,0,0,16,away-16.ico) -offline-16.ico: $(topsrcdir)/chat/themes/offline-16.png $(srcdir)/png2ico.py - $(call png2ico,$(topsrcdir)/chat/themes/offline-16.png,0,0,16,offline-16.ico) +offline-16.ico: $(commtopsrcdir)/chat/themes/offline-16.png $(srcdir)/png2ico.py + $(call png2ico,$(commtopsrcdir)/chat/themes/offline-16.png,0,0,16,offline-16.ico) embedded-icons:: available-16.ico away-16.ico offline-16.ico GARBAGE += available-16.ico away-16.ico offline-16.ico @@ -63,7 +63,7 @@ GARBAGE += available-16.ico away-16.ico offline-16.ico EXTRA_DEPS += instantbird.exe.manifest endif -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk ifeq ($(OS_ARCH),WINNT) @@ -174,11 +174,11 @@ ifdef ENABLE_TESTS # mozilla-central does this in testing/xpcshell-tests which means that it is very # hard for anyone to specify anything else. libs:: - $(INSTALL) $(IFLAGS1) $(topsrcdir)/im/test/xpcshell.ini $(DEPTH)/_tests/xpcshell - cp $(topsrcdir)/im/test/xpcshell.ini $(DEPTH)/_tests/xpcshell/all-test-dirs.list + $(INSTALL) $(IFLAGS1) $(commtopsrcdir)/im/test/xpcshell.ini $(DEPTH)/_tests/xpcshell + cp $(commtopsrcdir)/im/test/xpcshell.ini $(DEPTH)/_tests/xpcshell/all-test-dirs.list endif -libs:: $(topsrcdir)/mail/app/blocklist.xml +libs:: $(commtopsrcdir)/mail/app/blocklist.xml $(INSTALL) $(IFLAGS1) $^ $(DIST)/bin ifeq (cocoa,$(MOZ_WIDGET_TOOLKIT)) diff --git a/im/app/moz.build b/im/app/moz.build index a02c0436b6..44284b9110 100644 --- a/im/app/moz.build +++ b/im/app/moz.build @@ -10,15 +10,15 @@ USE_LIBS += ['mozglue'] SOURCES += ['nsMain.cpp'] LOCAL_INCLUDES += [ '!/build', - '/mozilla/toolkit/xre', - '/mozilla/xpcom/base', - '/mozilla/xpcom/build', + '/%s/toolkit/xre' % CONFIG['mozreltopsrcdir'], + '/%s/xpcom/base' % CONFIG['mozreltopsrcdir'], + '/%s/xpcom/build' % CONFIG['mozreltopsrcdir'], ] if CONFIG['LIBFUZZER']: USE_LIBS += [ 'fuzzer' ] LOCAL_INCLUDES += [ - '/mozilla/tools/fuzzing/libfuzzer', + '/%s/tools/fuzzing/libfuzzer' % CONFIG['mozreltopsrcdir'], ] if CONFIG['OS_ARCH'] == 'WINNT': @@ -28,8 +28,8 @@ if CONFIG['OS_ARCH'] == 'WINNT': if CONFIG['MOZ_SANDBOX'] and CONFIG['OS_ARCH'] == 'WINNT': # For sandbox includes and the include dependencies those have LOCAL_INCLUDES += [ - '/mozilla/security/sandbox/chromium', - '/mozilla/security/sandbox/chromium-shim', + '/%s/security/sandbox/chromium' % CONFIG['mozreltopsrcdir'], + '/%s/security/sandbox/chromium-shim' % CONFIG['mozreltopsrcdir'], ] USE_LIBS += [ diff --git a/im/branding/halloween/Makefile.in b/im/branding/halloween/Makefile.in index d4879c6632..29d0b24f2c 100644 --- a/im/branding/halloween/Makefile.in +++ b/im/branding/halloween/Makefile.in @@ -4,7 +4,7 @@ # Branding Makefile for nightlies/unofficial branding -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk export:: $(NSINSTALL) -D $(DIST)/branding diff --git a/im/branding/nightly/Makefile.in b/im/branding/nightly/Makefile.in index e96de1faf6..59501367fd 100644 --- a/im/branding/nightly/Makefile.in +++ b/im/branding/nightly/Makefile.in @@ -4,7 +4,7 @@ # Branding Makefile for nightlies/unofficial branding -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk export:: $(NSINSTALL) -D $(DIST)/branding diff --git a/im/build.mk b/im/build.mk index bcada94ec8..914a70031d 100644 --- a/im/build.mk +++ b/im/build.mk @@ -5,10 +5,10 @@ ifndef COMM_BUILD ifndef MOZILLA_DIR -MOZILLA_DIR = $(topsrcdir) +MOZILLA_DIR = $(moztopsrcdir) endif # included to get $(BUILDID), which needs $(MOZILLA_DIR) -include $(topsrcdir)/toolkit/mozapps/installer/package-name.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/package-name.mk BUILD_YEAR = $(shell echo $(BUILDID) | cut -c 1-4) BUILD_MONTH = $(shell echo $(BUILDID) | cut -c 5-6) @@ -71,7 +71,7 @@ FORCE_UPDATE := components/components.list|Contents/MacOS/components/components. # SYMBOL_SERVER_USER=buildbot distribution: - @$(MAKE) MAKE_SYM_STORE_PATH=$(MAKE_SYM_STORE_PATH) SYM_STORE_SOURCE_DIRS='$(topsrcdir)/mozilla/extensions/purple $(topsrcdir)/mozilla $(topsrcdir)' buildsymbols + @$(MAKE) MAKE_SYM_STORE_PATH=$(MAKE_SYM_STORE_PATH) SYM_STORE_SOURCE_DIRS='$(moztopsrcdir)/extensions/purple $(moztopsrcdir) $(commtopsrcdir)' buildsymbols @$(MAKE) -C im/installer libs installer ifdef ENABLE_TESTS $(MAKE) xpcshell-tests @@ -91,7 +91,7 @@ ifdef LIST_PREVIOUS_MAR_CMD mkdir -p $(PREVIOUS_MAR_DIR)/$(buildid) ; \ $(DOWNLOAD_MAR_CMD) ; \ echo "$(MAR_FILE_DEST),$(DIST)/$(COMPLETE_MAR),$(DIST)/$(PKG_UPDATE_PATH)$(PKG_UPDATE_BASENAME).partial.from-$(buildid).mar,$(FORCE_UPDATE)" >> $(PATCH_FILE) ;)))) - PATH="$(realpath $(DIST)/host/bin):$(PATH)" $(PYTHON) $(topsrcdir)/tools/update-packaging/make_incremental_updates.py -f $(PATCH_FILE) + PATH="$(realpath $(DIST)/host/bin):$(PATH)" $(PYTHON) $(moztopsrcdir)/tools/update-packaging/make_incremental_updates.py -f $(PATCH_FILE) endif ifdef SYMBOL_SERVER_HOST @$(MAKE) uploadsymbols @@ -103,7 +103,7 @@ endif installer: @$(MAKE) -C im/installer installer -SHIPPED_LOCALES_FILE = $(topsrcdir)/im/locales/shipped-locales +SHIPPED_LOCALES_FILE = $(commtopsrcdir)/im/locales/shipped-locales SHIPPED_LOCALES := $(shell if test -f $(SHIPPED_LOCALES_FILE); then cat $(SHIPPED_LOCALES_FILE); fi) package: diff --git a/im/configure.in b/im/configure.in index 4a61bb3f23..6861502c7d 100644 --- a/im/configure.in +++ b/im/configure.in @@ -7,6 +7,12 @@ dnl file, You can obtain one at http://mozilla.org/MPL/2.0/. dnl Things we need to carry from confvars.sh AC_SUBST(INSTANTBIRD_VERSION) +dnl More things we need to carry from confvars.sh +AC_SUBST(moztopsrcdir) +AC_SUBST(commtopsrcdir) +AC_SUBST(mozreltopsrcdir) +AC_SUBST(commreltopsrcdir) + if test `echo "$MOZ_EXTENSIONS" | grep -c purple` -ne 0; then MOZ_PURPLE=1 AC_SUBST(MOZ_PURPLE) diff --git a/im/confvars.sh b/im/confvars.sh index e343f69e87..68fac1d2c3 100644 --- a/im/confvars.sh +++ b/im/confvars.sh @@ -3,6 +3,8 @@ # 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/. +source ${_topsrcdir}/$MOZ_BUILD_APP/../comm-confvars.sh + MOZ_APP_BASENAME=Instantbird MOZ_APP_NAME=instantbird MOZ_APP_STATIC_INI=1 @@ -17,8 +19,9 @@ MOZ_APP_VERSION_TXT=${_topsrcdir}/$MOZ_BUILD_APP/config/version.txt MOZ_APP_VERSION=`cat $MOZ_APP_VERSION_TXT` INSTANTBIRD_VERSION=$MOZ_APP_VERSION -MOZ_BRANDING_DIRECTORY=im/branding/nightly -MOZ_OFFICIAL_BRANDING_DIRECTORY=other-licenses/branding/instantbird +MOZ_BRANDING_DIRECTORY=$commreltopsrcdir/im/branding/nightly +MOZ_OFFICIAL_BRANDING_DIRECTORY=$commreltopsrcdir/other-licenses/branding/instantbird + MOZ_APP_ID={33cb9019-c295-46dd-be21-8c4936574bee} # Enable generational GC on desktop. JSGC_GENERATIONAL=1 diff --git a/im/content/jar.mn b/im/content/jar.mn index 1d05a9c744..876d25f7c4 100644 --- a/im/content/jar.mn +++ b/im/content/jar.mn @@ -2,6 +2,8 @@ # 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/. +#filter substitution + instantbird.jar: % content instantbird %content/instantbird/ #ifdef XP_MACOSX @@ -97,7 +99,7 @@ instantbird.jar: content/instantbird/preferences/smiley.css (preferences/smiley.css) content/instantbird/preferences/smiley.xml (preferences/smiley.xml) # override the toolkit license.html file -* content/instantbird/license.html (/mozilla/toolkit/content/license.html) +* content/instantbird/license.html (/@mozreltopsrcdir@/toolkit/content/license.html) % override chrome://global/content/license.html chrome://instantbird/content/license.html toolkit.jar: diff --git a/im/content/moz.build b/im/content/moz.build index 206de0119c..2ee47c7020 100644 --- a/im/content/moz.build +++ b/im/content/moz.build @@ -5,8 +5,8 @@ JAR_MANIFESTS += ['jar.mn'] -# defines used for preference window files -for var in ('MOZ_APP_NAME', 'MOZ_MACBUNDLE_NAME'): +# defines used for preference window files and license +for var in ('MOZ_APP_NAME', 'MOZ_MACBUNDLE_NAME', 'mozreltopsrcdir'): DEFINES[var] = CONFIG[var] #if CONFIG['MOZ_WIDGET_TOOLKIT'] in ('windows', 'gtk2', 'gtk3', 'mac', 'cocoa'): @@ -16,3 +16,4 @@ if CONFIG['MOZ_UPDATER']: DEFINES['MOZ_UPDATER'] = 1 DEFINES['APP_LICENSE_BLOCK'] = '%s/overrides/app-license.html' % SRCDIR + diff --git a/im/installer/Makefile.in b/im/installer/Makefile.in index 2277de35d6..b2fadd3b21 100644 --- a/im/installer/Makefile.in +++ b/im/installer/Makefile.in @@ -4,7 +4,7 @@ STANDALONE_MAKEFILE := 1 -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk MOZ_PKG_REMOVALS = $(srcdir)/removed-files.in @@ -15,8 +15,8 @@ MOZ_PKG_FATAL_WARNINGS = 1 endif MOZ_PKG_DUPEFLAGS = \ -f $(srcdir)/allowed-dupes.mn \ - -f $(topsrcdir)/mail/installer/allowed-dupes.mn \ - -f $(MOZILLA_DIR)/browser/installer/allowed-dupes.mn \ + -f $(commtopsrcdir)/mail/installer/allowed-dupes.mn \ + -f $(moztopsrcdir)/browser/installer/allowed-dupes.mn \ $(NULL) MOZ_NONLOCALIZED_PKG_LIST = \ @@ -118,8 +118,8 @@ NON_OMNIJAR_FILES = GENERATE_CACHE=1 -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/signing.mk -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/packager.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/signing.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/packager.mk ifeq (bundle, $(MOZ_FS_LAYOUT)) BINPATH = $(_BINPATH) @@ -189,7 +189,7 @@ ifdef INSTALLER_DIR endif # The comm-* source stamp is already there. -PLATFORM_SOURCE_STAMP = $(firstword $(shell hg -R "$(MOZILLA_SRCDIR)" parent --template="{node}\n" 2>/dev/null)) -PLATFORM_SOURCE_REPO = $(shell hg -R "$(MOZILLA_SRCDIR)" showconfig paths.default 2>/dev/null | sed -e "s/^ssh:/https:/") +PLATFORM_SOURCE_STAMP = $(firstword $(shell hg -R "$(moztopsrcdir)" parent --template="{node}\n" 2>/dev/null)) +PLATFORM_SOURCE_REPO = $(shell hg -R "$(moztopsrcdir)" showconfig paths.default 2>/dev/null | sed -e "s/^ssh:/https:/") make-sourcestamp-file:: @echo "$(PLATFORM_SOURCE_REPO)/rev/$(PLATFORM_SOURCE_STAMP)" >> $(MOZ_SOURCESTAMP_FILE) diff --git a/im/installer/windows/Makefile.in b/im/installer/windows/Makefile.in index 043e1eafc5..deaad165e9 100644 --- a/im/installer/windows/Makefile.in +++ b/im/installer/windows/Makefile.in @@ -2,13 +2,13 @@ # 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/. -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/package-name.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/package-name.mk PKG_INST_PATH = CONFIG_DIR = instgen -SFX_MODULE = $(topsrcdir)/other-licenses/7zstub/instantbird/7zSD.sfx +SFX_MODULE = $(commtopsrcdir)/other-licenses/7zstub/instantbird/7zSD.sfx DEFINES += -DMOZ_APP_VERSION=$(MOZ_APP_VERSION) -PRE_RELEASE_SUFFIX := $(shell $(PYTHON) $(topsrcdir)/mozilla/config/printprereleasesuffix.py $(MOZ_APP_VERSION)) +PRE_RELEASE_SUFFIX := $(shell $(PYTHON) $(moztopsrcdir)/config/printprereleasesuffix.py $(MOZ_APP_VERSION)) DEFINES += -DPRE_RELEASE_SUFFIX="$(PRE_RELEASE_SUFFIX)" ifdef MOZ_UPDATER @@ -35,7 +35,7 @@ DEFINES += \ -DMOZILLA_VERSION=${MOZILLA_VERSION} \ $(NULL) -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk OVERRIDE_DEFAULT_GOAL := installer installer:: @@ -50,8 +50,8 @@ uninstaller:: $(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) $(CONFIG_DIR) $(call py_action,preprocessor,-Fsubstitution $(DEFINES) $(ACDEFINES) \ $(srcdir)/nsis/defines.nsi.in -o $(CONFIG_DIR)/defines.nsi) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --preprocess-locale $(MOZILLA_SRCDIR) \ + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --preprocess-locale $(moztopsrcdir) \ $(call EXPAND_LOCALE_SRCDIR,im/locales)/installer $(AB_CD) $(CONFIG_DIR) $(CONFIG_DIR)/setup.exe:: @@ -60,9 +60,9 @@ $(CONFIG_DIR)/setup.exe:: $(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) $(CONFIG_DIR) $(call py_action,preprocessor,-Fsubstitution $(DEFINES) $(ACDEFINES) \ $(srcdir)/nsis/defines.nsi.in -o $(CONFIG_DIR)/defines.nsi) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --preprocess-locale $(MOZILLA_SRCDIR) \ + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --preprocess-locale $(moztopsrcdir) \ $(call EXPAND_LOCALE_SRCDIR,im/locales)/installer $(AB_CD) $(CONFIG_DIR) -include $(topsrcdir)/config/rules.mk -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/makensis.mk +include $(moztopsrcdir)/config/rules.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/makensis.mk diff --git a/im/locales/Makefile.in b/im/locales/Makefile.in index 99f79e2c15..fd0cf9180a 100644 --- a/im/locales/Makefile.in +++ b/im/locales/Makefile.in @@ -2,9 +2,9 @@ # 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/. -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk -_ABS_SRCDIR := $(abspath $(topsrcdir)) +_ABS_SRCDIR := $(abspath $(commtopsrcdir)) ifndef MOZ_BRANDING_DIRECTORY MOZ_BRANDING_DIRECTORY = im/branding/nightly @@ -40,8 +40,8 @@ MOZ_PKG_MAC_ICON=$(ABS_DIST)/branding/disk.icns MOZ_PKG_MAC_EXTRA=--symlink "/Applications:/ " endif -MOZ_SFX_PACKAGE=$(topsrcdir)/other-licenses/7zstub/instantbird/7zSD.sfx -MOZ_INSTALLER_PATH=$(topsrcdir)/im/installer/windows +MOZ_SFX_PACKAGE=$(commtopsrcdir)/other-licenses/7zstub/instantbird/7zSD.sfx +MOZ_INSTALLER_PATH=$(commtopsrcdir)/im/installer/windows ifeq (WINNT,$(OS_ARCH)) UNINSTALLER_PACKAGE_HOOK = $(RM) -r $(STAGEDIST)/uninstall; \ @@ -67,9 +67,9 @@ GARBAGE += $(list-txt) libs:: searchplugins -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk -include $(topsrcdir)/mozilla/toolkit/locales/l10n.mk +include $(moztopsrcdir)/toolkit/locales/l10n.mk $(list-txt): $(call mkdir_deps,$(SEARCHPLUGINS_PATH)) $(if $(IS_LANGUAGE_REPACK),FORCE) $(RM) $(list-txt) @@ -150,13 +150,13 @@ endif ident: @printf "ib_revision " - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/application.ini App SourceStamp @printf "moz_revision " - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/platform.ini Build SourceStamp @printf "buildid " - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/application.ini App BuildID #These make targets call prepare-repackages by setting different UPLOAD_DIR @@ -205,8 +205,8 @@ MOZ_L10N_REPO_BASE = https://hg.mozilla.org/releases/l10n-mozilla-2.0 checkout-%: AB_CD=$* checkout-%: - mkdir -p $(topsrcdir)/$(L10NBASEDIR) - $(PYTHON) $(topsrcdir)/client.py checkout-l10n --skip-instantbird --clean --l10n-base-dir $(L10NBASEDIR) --locale $(AB_CD) + mkdir -p $(commtopsrcdir)/$(L10NBASEDIR) + $(PYTHON) $(commtopsrcdir)/client.py checkout-l10n --skip-instantbird --clean --l10n-base-dir $(L10NBASEDIR) --locale $(AB_CD) repack-%: AB_CD=$* repack-%: diff --git a/ldap/c-sdk/libraries/liblber/moz.build b/ldap/c-sdk/libraries/liblber/moz.build index 8a344a4739..f89c8c3d72 100644 --- a/ldap/c-sdk/libraries/liblber/moz.build +++ b/ldap/c-sdk/libraries/liblber/moz.build @@ -3,7 +3,7 @@ # 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/. -include('/ldap/ldap-sdk.mozbuild') +include('/%s/ldap/ldap-sdk.mozbuild' % CONFIG['commreltopsrcdir']) Library('lber60') @@ -18,6 +18,6 @@ DEFINES['USE_WAITPID'] = True DEFINES['NEEDPROTOS'] = True LOCAL_INCLUDES += [ - '/ldap/c-sdk/include' + '../../include' ] diff --git a/ldap/c-sdk/libraries/libldap/moz.build b/ldap/c-sdk/libraries/libldap/moz.build index 05c7a6b524..3c3d747a86 100644 --- a/ldap/c-sdk/libraries/libldap/moz.build +++ b/ldap/c-sdk/libraries/libldap/moz.build @@ -3,7 +3,7 @@ # 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/. -include('/ldap/ldap-sdk.mozbuild') +include('/%s/ldap/ldap-sdk.mozbuild' % CONFIG['commreltopsrcdir']) SharedLibrary('ldap60') @@ -82,7 +82,7 @@ if CONFIG['OS_TARGET'] != 'WINNT': DEFINES['NEEDPROTOS'] = True LOCAL_INCLUDES += [ - '/ldap/c-sdk/include' + '../../include' ] USE_LIBS += ['lber60'] diff --git a/ldap/c-sdk/libraries/libldif/moz.build b/ldap/c-sdk/libraries/libldif/moz.build index 000775a249..e649f66a2c 100644 --- a/ldap/c-sdk/libraries/libldif/moz.build +++ b/ldap/c-sdk/libraries/libldif/moz.build @@ -3,7 +3,7 @@ # 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/. -include('/ldap/ldap-sdk.mozbuild') +include('/%s/ldap/ldap-sdk.mozbuild' % CONFIG['commreltopsrcdir']) SharedLibrary('ldif60') @@ -12,7 +12,7 @@ SOURCES += [ ] LOCAL_INCLUDES += [ - '/ldap/c-sdk/include' + '../../include' ] if CONFIG['OS_ARCH'] == 'WINNT': @@ -20,4 +20,3 @@ if CONFIG['OS_ARCH'] == 'WINNT': DEFINES['USE_WAITPID'] = True DEFINES['NEEDPROTOS'] = True - diff --git a/ldap/c-sdk/libraries/libprldap/moz.build b/ldap/c-sdk/libraries/libprldap/moz.build index 422557cc95..be2370aae7 100644 --- a/ldap/c-sdk/libraries/libprldap/moz.build +++ b/ldap/c-sdk/libraries/libprldap/moz.build @@ -3,7 +3,7 @@ # 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/. -include('/ldap/ldap-sdk.mozbuild') +include('/%s/ldap/ldap-sdk.mozbuild' % CONFIG['commreltopsrcdir']) SharedLibrary('prldap60') @@ -22,7 +22,7 @@ DEFINES['USE_WAITPID'] = True DEFINES['NEEDPROTOS'] = True LOCAL_INCLUDES += [ - '/ldap/c-sdk/include' + '../../include' ] USE_LIBS += [ diff --git a/ldap/xpcom/src/moz.build b/ldap/xpcom/src/moz.build index 84508f0563..520a1209de 100644 --- a/ldap/xpcom/src/moz.build +++ b/ldap/xpcom/src/moz.build @@ -35,6 +35,6 @@ Library('mozldap') FINAL_LIBRARY = 'xul' LOCAL_INCLUDES += [ - '/ldap/c-sdk/include', + '../../c-sdk/include', ] diff --git a/mail/Makefile.in b/mail/Makefile.in index 96a0e319de..1cfdf1217b 100644 --- a/mail/Makefile.in +++ b/mail/Makefile.in @@ -1,22 +1,21 @@ -# # 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/. -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk ifdef ENABLE_TESTS check-sync-dirs:: - @$(PYTHON) $(topsrcdir)/mail/check-sync-dirs.py \ - $(topsrcdir)/build $(MOZILLA_SRCDIR)/build - @$(PYTHON) $(topsrcdir)/mail/check-sync-dirs.py \ - $(srcdir)/config/tooltool-manifests $(MOZILLA_SRCDIR)/browser/config/tooltool-manifests + @$(PYTHON) $(commtopsrcdir)/mail/check-sync-dirs.py \ + $(topsrcdir)/build $(moztopsrcdir)/build + @$(PYTHON) $(commtopsrcdir)/mail/check-sync-dirs.py \ + $(srcdir)/config/tooltool-manifests $(moztopsrcdir)/browser/config/tooltool-manifests check:: check-sync-dirs endif -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk ifdef MAKENSISU # For Windows build the uninstaller during the application build since the @@ -33,7 +32,7 @@ endif # platform.ini are the same, which isn't a problem for Firefox, but # it's not right for anything else. So we correct platform.ini here. -MOZ_REV=$(shell hg -R "$(MOZILLA_SRCDIR)" parent --template="{node}" 2>/dev/null) +MOZ_REV=$(shell hg -R "$(moztopsrcdir)" parent --template="{node}" 2>/dev/null) libs:: $(DIST)/bin/platform.ini sed -e "s/^\(SourceStamp=\).*/\1$(MOZ_REV)/" $(DIST)/bin/platform.ini \ diff --git a/mail/app-config.mk b/mail/app-config.mk new file mode 100644 index 0000000000..0d3d6bd3f0 --- /dev/null +++ b/mail/app-config.mk @@ -0,0 +1,9 @@ +# 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/. + +ifeq ($(findstring comm,$(MOZ_BUILD_APP)),) +COMMDEPTH = $(DEPTH) +else +COMMDEPTH = $(DEPTH)/comm +endif diff --git a/mail/app.mozbuild b/mail/app.mozbuild index c361131e20..0ad993f243 100644 --- a/mail/app.mozbuild +++ b/mail/app.mozbuild @@ -3,27 +3,30 @@ # 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/. -include('/mailnews/mailnews.mozbuild') +# Note that paths in this file are relative to the top directory, which may be +# m-c or c-c. -DIRS += ['/mail/components'] +include('../mailnews/mailnews.mozbuild') -include('/toolkit/toolkit.mozbuild') +DIRS += ['/%s/mail/components' % CONFIG['commreltopsrcdir']] + +include('/%s/toolkit/toolkit.mozbuild' % CONFIG['mozreltopsrcdir']) if CONFIG['MOZ_EXTENSIONS']: - DIRS += ['/extensions'] + DIRS += ['/%s/extensions' % CONFIG['mozreltopsrcdir']] DIRS += ['/%s' % CONFIG['MOZ_BRANDING_DIRECTORY']] if CONFIG['MOZ_COMPOSER']: - DIRS += ['/editor/ui'] + DIRS += ['/%s/editor/ui' % CONFIG['commreltopsrcdir']] if CONFIG['MOZ_CALENDAR']: DIRS += [ - '/calendar/lightning', - '/calendar/timezones' + '/%s/calendar/lightning' % CONFIG['commreltopsrcdir'], + '/%s/calendar/timezones' % CONFIG['commreltopsrcdir'] ] DIRS += [ - '/chat', - '/mail', + '/%s/chat' % CONFIG['commreltopsrcdir'], + '/%s/mail' % CONFIG['commreltopsrcdir'], ] diff --git a/mail/app/Makefile.in b/mail/app/Makefile.in index c3a7943afd..f3bbe98477 100644 --- a/mail/app/Makefile.in +++ b/mail/app/Makefile.in @@ -4,8 +4,8 @@ AB_CD = $(MOZ_UI_LOCALE) -GRE_MILESTONE = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build Milestone) -MOZ_BUILDID = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build BuildID) +GRE_MILESTONE = $(shell $(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build Milestone) +MOZ_BUILDID = $(shell $(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build BuildID) DEFINES += \ -DTHUNDERBIRD_ICO='"$(DIST)/branding/thunderbird.ico"' \ @@ -25,7 +25,7 @@ endif # shouldn't get 755 perms need $(IFLAGS1) for either way of calling nsinstall. NSDISTMODE = copy -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk # If we are trying to show an error dialog about the lack of SSE2 support, # make sure that code itself doesn't use SSE2. @@ -38,7 +38,7 @@ endif ifeq ($(OS_ARCH),WINNT) # Extract the icons we care about embedding into the EXE -mailtoolbar = $(topsrcdir)/mail/themes/windows/mail/icons/jumplist.png +mailtoolbar = $(commtopsrcdir)/mail/themes/windows/mail/icons/jumplist.png # png to ico converter. The function takes 5 arguments, in order: source png # file, left, top, size, output ico file. @@ -62,7 +62,7 @@ GARBAGE += write-message.ico address-book.ico EXTRA_DEPS += thunderbird.exe.manifest endif -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk ifeq ($(OS_ARCH),WINNT) diff --git a/mail/app/moz.build b/mail/app/moz.build index f18374b6a5..ac0f63d693 100644 --- a/mail/app/moz.build +++ b/mail/app/moz.build @@ -10,15 +10,15 @@ USE_LIBS += ['mozglue'] SOURCES += ['nsMailApp.cpp'] LOCAL_INCLUDES += [ '!/build', - '/mozilla/toolkit/xre', - '/mozilla/xpcom/base', - '/mozilla/xpcom/build', + '/%s/toolkit/xre' % CONFIG['mozreltopsrcdir'], + '/%s/xpcom/base' % CONFIG['mozreltopsrcdir'], + '/%s/xpcom/build' % CONFIG['mozreltopsrcdir'], ] if CONFIG['LIBFUZZER']: USE_LIBS += [ 'fuzzer' ] LOCAL_INCLUDES += [ - '/mozilla/tools/fuzzing/libfuzzer', + '/%s/tools/fuzzing/libfuzzer' % CONFIG['mozreltopsrcdir'], ] if CONFIG['OS_ARCH'] == 'WINNT': @@ -28,8 +28,8 @@ if CONFIG['OS_ARCH'] == 'WINNT': if CONFIG['MOZ_SANDBOX'] and CONFIG['OS_ARCH'] == 'WINNT': # For sandbox includes and the include dependencies those have LOCAL_INCLUDES += [ - '/mozilla/security/sandbox/chromium', - '/mozilla/security/sandbox/chromium-shim', + '/%s/security/sandbox/chromium' % CONFIG['mozreltopsrcdir'], + '/%s/security/sandbox/chromium-shim' % CONFIG['mozreltopsrcdir'], ] USE_LIBS += [ diff --git a/mail/app/profile/extensions/Makefile.in b/mail/app/profile/extensions/Makefile.in index 665a0aad41..9584992ea4 100644 --- a/mail/app/profile/extensions/Makefile.in +++ b/mail/app/profile/extensions/Makefile.in @@ -5,7 +5,7 @@ DISTROEXT = $(ABS_DIST)/bin/distribution/extensions -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk # If adding extra extensions here, check that EXTRA_ARGS defined below won't # affect them unintentionally. diff --git a/mail/base/jar.mn b/mail/base/jar.mn index 023320563c..87104d042c 100644 --- a/mail/base/jar.mn +++ b/mail/base/jar.mn @@ -1,3 +1,5 @@ +#filter substitution + messenger.jar: % content messagebody %content/messagebody/ contentaccessible=yes % content messenger %content/messenger/ @@ -115,7 +117,7 @@ messenger.jar: content/messenger/sanitizeDialog.js (content/sanitizeDialog.js) * content/messenger/toolbarIconColor.js (content/toolbarIconColor.js) # the following files are mail-specific overrides -* content/messenger/license.html (/mozilla/toolkit/content/license.html) +* content/messenger/license.html (/@mozreltopsrcdir@/toolkit/content/license.html) % override chrome://global/content/license.html chrome://messenger/content/license.html # L10n resource overrides % override chrome://mozapps/locale/downloads/settingsChange.dtd chrome://messenger/locale/downloads/settingsChange.dtd @@ -125,7 +127,7 @@ comm.jar: % content communicator %content/communicator/ content/communicator/charsetOverlay.xul (content/charsetOverlay.xul) content/communicator/contentAreaClick.js (content/contentAreaClick.js) - content/communicator/labelsencodings.properties (/mozilla/dom/encoding/labelsencodings.properties) + content/communicator/labelsencodings.properties (/@mozreltopsrcdir@/dom/encoding/labelsencodings.properties) * content/communicator/utilityOverlay.xul (content/utilityOverlay.xul) content/communicator/utilityOverlay.js (content/utilityOverlay.js) diff --git a/mail/base/moz.build b/mail/base/moz.build index c16455fbea..153adcc056 100644 --- a/mail/base/moz.build +++ b/mail/base/moz.build @@ -12,6 +12,7 @@ JAR_MANIFESTS += ['jar.mn'] DEFINES['PRE_RELEASE_SUFFIX'] = '' DEFINES['MOZ_APP_VERSION'] = CONFIG['MOZ_APP_VERSION'] DEFINES['MOZ_APP_VERSION_DISPLAY'] = CONFIG['MOZ_APP_VERSION_DISPLAY'] +DEFINES['mozreltopsrcdir'] = CONFIG['mozreltopsrcdir'] DEFINES['APP_LICENSE_BLOCK'] = '%s/content/overrides/app-license.html' % SRCDIR if CONFIG['MOZILLA_OFFICIAL']: diff --git a/mail/branding/aurora/Makefile.in b/mail/branding/aurora/Makefile.in index b64845602e..fb52642514 100644 --- a/mail/branding/aurora/Makefile.in +++ b/mail/branding/aurora/Makefile.in @@ -4,7 +4,7 @@ # Branding Makefile for nightlies/unofficial branding -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk export:: $(NSINSTALL) -D $(DIST)/branding diff --git a/mail/branding/nightly/Makefile.in b/mail/branding/nightly/Makefile.in index b64845602e..fb52642514 100644 --- a/mail/branding/nightly/Makefile.in +++ b/mail/branding/nightly/Makefile.in @@ -4,7 +4,7 @@ # Branding Makefile for nightlies/unofficial branding -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk export:: $(NSINSTALL) -D $(DIST)/branding diff --git a/mail/build.mk b/mail/build.mk index b1084a9b91..8a7378c627 100644 --- a/mail/build.mk +++ b/mail/build.mk @@ -4,48 +4,48 @@ ifndef COMM_BUILD installer: - @$(MAKE) -C mail/installer installer + @$(MAKE) -C $(COMMDEPTH)/mail/installer installer package: - @$(MAKE) -C mail/installer + @$(MAKE) -C $(COMMDEPTH)/mail/installer package-compare: - @$(MAKE) -C mail/installer package-compare + @$(MAKE) -C $(COMMDEPTH)/mail/installer package-compare stage-package: - @$(MAKE) -C mail/installer stage-package + @$(MAKE) -C $(COMMDEPTH)/mail/installer stage-package install:: - @$(MAKE) -C mail/installer install + @$(MAKE) -C $(COMMDEPTH)/mail/installer install source-package:: - @$(MAKE) -C mail/installer source-package + @$(MAKE) -C $(COMMDEPTH)/mail/installer source-package upload:: - @$(MAKE) -C mail/installer upload + @$(MAKE) -C $(COMMDEPTH)/mail/installer upload ifdef MOZ_CALENDAR - @$(MAKE) -C calendar/lightning upload - @$(MAKE) -C calendar/providers/gdata upload + @$(MAKE) -C $(COMMDEPTH)/calendar/lightning upload + @$(MAKE) -C $(COMMDEPTH)/calendar/providers/gdata upload endif source-upload:: - @$(MAKE) -C mail/installer source-upload + @$(MAKE) -C $(COMMDEPTH)/mail/installer source-upload hg-bundle:: - @$(MAKE) -C mail/installer hg-bundle + @$(MAKE) -C $(COMMDEPTH)/mail/installer hg-bundle l10n-check:: - @$(MAKE) -C mail/locales l10n-check + @$(MAKE) -C $(COMMDEPTH)/mail/locales l10n-check wget-en-US: - $(MAKE) -C mail/locales wget-en-US + $(MAKE) -C $(COMMDEPTH)/mail/locales wget-en-US # make -j1 because dependencies in l10n build targets don't work # with parallel builds merge-% installers-% langpack-% chrome-%: - $(MAKE) -j1 -C mail/locales $@ + $(MAKE) -j1 -C $(COMMDEPTH)/mail/locales $@ ifdef ENABLE_TESTS -include $(topsrcdir)/../mail/testsuite-targets.mk +include $(commtopsrcdir)/mail/testsuite-targets.mk endif endif diff --git a/mail/components/search/mdimporter/Makefile.in b/mail/components/search/mdimporter/Makefile.in index 352a07a78a..4c0fe34f09 100644 --- a/mail/components/search/mdimporter/Makefile.in +++ b/mail/components/search/mdimporter/Makefile.in @@ -22,7 +22,7 @@ CFLAGS += -mmacosx-version-min=$(MACOSX_DEPLOYMENT_TARGET) # We don't need mozglue WRAP_LDFLAGS := -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk # We're also a bundle. LDFLAGS += -bundle diff --git a/mail/configure.in b/mail/configure.in index 7ecfc5babf..885ca32841 100644 --- a/mail/configure.in +++ b/mail/configure.in @@ -12,6 +12,12 @@ AC_SUBST(THUNDERBIRD_VERSION) AC_DEFINE(MOZ_SEPARATE_MANIFEST_FOR_THEME_OVERRIDES) AC_SUBST(MOZ_BUNDLED_FONTS) +dnl More things we need to carry from confvars.sh +AC_SUBST(moztopsrcdir) +AC_SUBST(commtopsrcdir) +AC_SUBST(mozreltopsrcdir) +AC_SUBST(commreltopsrcdir) + dnl Optional parts of the build. AC_SUBST(MOZ_MORK) if test "$MOZ_MORK"; then diff --git a/mail/confvars.sh b/mail/confvars.sh index bd32859266..254d7a3e79 100755 --- a/mail/confvars.sh +++ b/mail/confvars.sh @@ -3,6 +3,8 @@ # 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/. +source ${_topsrcdir}/$MOZ_BUILD_APP/../comm-confvars.sh + MOZ_APP_BASENAME=Thunderbird MOZ_APP_NAME=thunderbird MOZ_UPDATER=1 @@ -31,8 +33,9 @@ MOZ_APP_VERSION_DISPLAY_TXT=${_topsrcdir}/$MOZ_BUILD_APP/config/version_display. MOZ_APP_VERSION_DISPLAY=`cat $MOZ_APP_VERSION_DISPLAY_TXT` THUNDERBIRD_VERSION=$MOZ_APP_VERSION -MOZ_BRANDING_DIRECTORY=mail/branding/nightly -MOZ_OFFICIAL_BRANDING_DIRECTORY=other-licenses/branding/thunderbird +MOZ_BRANDING_DIRECTORY=$commreltopsrcdir/mail/branding/nightly +MOZ_OFFICIAL_BRANDING_DIRECTORY=$commreltopsrcdir/other-licenses/branding/thunderbird + MOZ_APP_ID={3550f703-e582-4d05-9a08-453d09bdfdc6} # This should usually be the same as the value MAR_CHANNEL_ID. # If more than one ID is needed, then you should use a comma separated list diff --git a/mail/extensions/smime/jar.mn b/mail/extensions/smime/jar.mn index 051bd1461a..d425ff74d8 100644 --- a/mail/extensions/smime/jar.mn +++ b/mail/extensions/smime/jar.mn @@ -14,16 +14,16 @@ messenger.jar: content/messenger-smime/msgCompSMIMEOverlay.js (content/msgCompSMIMEOverlay.js) content/messenger-smime/msgHdrViewSMIMEOverlay.js (content/msgHdrViewSMIMEOverlay.js) content/messenger-smime/msgHdrViewSMIMEOverlay.xul (content/msgHdrViewSMIMEOverlay.xul) - content/messenger/am-smime.xul (/mailnews/extensions/smime/content/am-smime.xul) - content/messenger/am-smime.js (/mailnews/extensions/smime/content/am-smime.js) - content/messenger/am-smimeIdentityEditOverlay.xul (/mailnews/extensions/smime/content/am-smimeIdentityEditOverlay.xul) - content/messenger/am-smimeOverlay.xul (/mailnews/extensions/smime/content/am-smimeOverlay.xul) - content/messenger/certpicker.js (/mailnews/extensions/smime/content/certpicker.js) - content/messenger/certpicker.xul (/mailnews/extensions/smime/content/certpicker.xul) - content/messenger-smime/msgReadSMIMEOverlay.js (/mailnews/extensions/smime/content/msgReadSMIMEOverlay.js) - content/messenger-smime/msgCompSecurityInfo.js (/mailnews/extensions/smime/content/msgCompSecurityInfo.js) - content/messenger-smime/msgCompSecurityInfo.xul (/mailnews/extensions/smime/content/msgCompSecurityInfo.xul) - content/messenger-smime/msgReadSecurityInfo.xul (/mailnews/extensions/smime/content/msgReadSecurityInfo.xul) - content/messenger-smime/msgReadSecurityInfo.js (/mailnews/extensions/smime/content/msgReadSecurityInfo.js) - content/messenger-smime/certFetchingStatus.xul (/mailnews/extensions/smime/content/certFetchingStatus.xul) - content/messenger-smime/certFetchingStatus.js (/mailnews/extensions/smime/content/certFetchingStatus.js) + content/messenger/am-smime.xul (../../../mailnews/extensions/smime/content/am-smime.xul) + content/messenger/am-smime.js (../../../mailnews/extensions/smime/content/am-smime.js) + content/messenger/am-smimeIdentityEditOverlay.xul (../../../mailnews/extensions/smime/content/am-smimeIdentityEditOverlay.xul) + content/messenger/am-smimeOverlay.xul (../../../mailnews/extensions/smime/content/am-smimeOverlay.xul) + content/messenger/certpicker.js (../../../mailnews/extensions/smime/content/certpicker.js) + content/messenger/certpicker.xul (../../../mailnews/extensions/smime/content/certpicker.xul) + content/messenger-smime/msgReadSMIMEOverlay.js (../../../mailnews/extensions/smime/content/msgReadSMIMEOverlay.js) + content/messenger-smime/msgCompSecurityInfo.js (../../../mailnews/extensions/smime/content/msgCompSecurityInfo.js) + content/messenger-smime/msgCompSecurityInfo.xul (../../../mailnews/extensions/smime/content/msgCompSecurityInfo.xul) + content/messenger-smime/msgReadSecurityInfo.xul (../../../mailnews/extensions/smime/content/msgReadSecurityInfo.xul) + content/messenger-smime/msgReadSecurityInfo.js (../../../mailnews/extensions/smime/content/msgReadSecurityInfo.js) + content/messenger-smime/certFetchingStatus.xul (../../../mailnews/extensions/smime/content/certFetchingStatus.xul) + content/messenger-smime/certFetchingStatus.js (../../../mailnews/extensions/smime/content/certFetchingStatus.js) diff --git a/mail/installer/Makefile.in b/mail/installer/Makefile.in index 311a4df982..ad1483ea1f 100644 --- a/mail/installer/Makefile.in +++ b/mail/installer/Makefile.in @@ -5,7 +5,10 @@ STANDALONE_MAKEFILE := 1 # DIST_SUBDIR := mail # Not sure why TB is not using this -include $(topsrcdir)/config/rules.mk +# Since STANDALONE_MAKEFILE is defined we need to manually include our config +include $(commtopsrcdir)/mail/app-config.mk + +include $(moztopsrcdir)/config/rules.mk MOZ_PKG_REMOVALS = $(srcdir)/removed-files.in @@ -16,7 +19,7 @@ MOZ_PKG_FATAL_WARNINGS = 1 endif MOZ_PKG_DUPEFLAGS = \ -f $(srcdir)/allowed-dupes.mn \ - -f $(MOZILLA_DIR)/browser/installer/allowed-dupes.mn \ + -f $(moztopsrcdir)/browser/installer/allowed-dupes.mn \ $(NULL) MOZ_NONLOCALIZED_PKG_LIST = \ @@ -132,8 +135,8 @@ endif NON_OMNIJAR_FILES = defaults/messenger/mailViews.dat -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/signing.mk -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/packager.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/signing.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/packager.mk ifeq (bundle, $(MOZ_FS_LAYOUT)) BINPATH = $(_BINPATH) @@ -176,7 +179,7 @@ DEFINES += -DCLANG_CL endif libs:: - $(MAKE) -C $(DEPTH)/mail/locales langpack + $(MAKE) -C $(COMMDEPTH)/mail/locales langpack ifeq (WINNT,$(OS_ARCH)) PKGCOMP_FIND_OPTS = @@ -203,7 +206,7 @@ ifdef INSTALLER_DIR endif # The comm-* source stamp is already there. -PLATFORM_SOURCE_STAMP = $(firstword $(shell hg -R "$(MOZILLA_SRCDIR)" parent --template="{node}\n" 2>/dev/null)) -PLATFORM_SOURCE_REPO = $(shell hg -R "$(MOZILLA_SRCDIR)" showconfig paths.default 2>/dev/null | sed -e "s/^ssh:/https:/") +PLATFORM_SOURCE_STAMP = $(firstword $(shell hg -R "$(moztopsrcdir)" parent --template="{node}\n" 2>/dev/null)) +PLATFORM_SOURCE_REPO = $(shell hg -R "$(moztopsrcdir)" showconfig paths.default 2>/dev/null | sed -e "s/^ssh:/https:/") make-sourcestamp-file:: @echo "$(PLATFORM_SOURCE_REPO)/rev/$(PLATFORM_SOURCE_STAMP)" >> $(MOZ_SOURCESTAMP_FILE) diff --git a/mail/installer/windows/Makefile.in b/mail/installer/windows/Makefile.in index f6559137b4..d00e1d8da7 100644 --- a/mail/installer/windows/Makefile.in +++ b/mail/installer/windows/Makefile.in @@ -2,10 +2,10 @@ # 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/. -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/package-name.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/package-name.mk CONFIG_DIR = instgen -SFX_MODULE = $(topsrcdir)/other-licenses/7zstub/thunderbird/7zSD.sfx +SFX_MODULE = $(commtopsrcdir)/other-licenses/7zstub/thunderbird/7zSD.sfx DEFINES += -DMOZ_APP_VERSION=$(MOZ_APP_VERSION) PRE_RELEASE_SUFFIX := "" @@ -42,13 +42,13 @@ DEFINES += \ -DMOZILLA_VERSION=${MOZILLA_VERSION} \ $(NULL) -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk ifdef LOCALE_MERGEDIR PPL_LOCALE_ARGS = \ --l10n-dir=$(LOCALE_MERGEDIR)/mail/installer \ --l10n-dir=$(call EXPAND_LOCALE_SRCDIR,mail/locales)/installer \ - --l10n-dir=$(topsrcdir)/mail/locales/en-US/installer \ + --l10n-dir=$(commtopsrcdir)/mail/locales/en-US/installer \ $(NULL) else PPL_LOCALE_ARGS=$(call EXPAND_LOCALE_SRCDIR,mail/locales)/installer @@ -67,8 +67,8 @@ uninstaller:: $(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) $(CONFIG_DIR) $(call py_action,preprocessor,-Fsubstitution $(DEFINES) $(ACDEFINES) \ $(srcdir)/nsis/defines.nsi.in -o $(CONFIG_DIR)/defines.nsi) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --preprocess-locale $(MOZILLA_SRCDIR) \ + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --preprocess-locale $(moztopsrcdir) \ $(PPL_LOCALE_ARGS) $(AB_CD) $(CONFIG_DIR) # For building the maintenanceservice installer @@ -77,8 +77,8 @@ maintenanceservice_installer:: $(INSTALL) $(addprefix $(srcdir)/,$(INSTALLER_FILES)) $(CONFIG_DIR) $(call py_action,preprocessor,-Fsubstitution $(DEFINES) $(ACDEFINES) \ $(srcdir)/nsis/defines.nsi.in -o $(CONFIG_DIR)/defines.nsi) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --preprocess-locale $(MOZILLA_SRCDIR) \ + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --preprocess-locale $(moztopsrcdir) \ $(PPL_LOCALE_ARGS) $(AB_CD) $(CONFIG_DIR) endif @@ -88,9 +88,9 @@ $(CONFIG_DIR)/setup.exe:: $(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) $(CONFIG_DIR) $(call py_action,preprocessor,-Fsubstitution $(DEFINES) $(ACDEFINES) \ $(srcdir)/nsis/defines.nsi.in -o $(CONFIG_DIR)/defines.nsi) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --preprocess-locale $(MOZILLA_SRCDIR) \ + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --preprocess-locale $(moztopsrcdir) \ $(PPL_LOCALE_ARGS) $(AB_CD) $(CONFIG_DIR) -include $(topsrcdir)/config/rules.mk -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/makensis.mk +include $(moztopsrcdir)/config/rules.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/makensis.mk diff --git a/mail/locales/Makefile.in b/mail/locales/Makefile.in index 98fdc7463d..08ddd62695 100644 --- a/mail/locales/Makefile.in +++ b/mail/locales/Makefile.in @@ -2,9 +2,9 @@ # 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/. -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk -_ABS_SRCDIR := $(abspath $(topsrcdir)) +_ABS_SRCDIR := $(abspath $(commtopsrcdir)) SUBMAKEFILES += \ $(DEPTH)/$(MOZ_BRANDING_DIRECTORY)/Makefile \ @@ -40,8 +40,8 @@ MOZ_PKG_MAC_ICON=$(ABS_DIST)/branding/disk.icns MOZ_PKG_MAC_EXTRA=--symlink '/Applications:/ ' endif -MOZ_SFX_PACKAGE=$(topsrcdir)/other-licenses/7zstub/thunderbird/7zSD.sfx -MOZ_INSTALLER_PATH=$(topsrcdir)/mail/installer/windows +MOZ_SFX_PACKAGE=$(commtopsrcdir)/other-licenses/7zstub/thunderbird/7zSD.sfx +MOZ_INSTALLER_PATH=$(commtopsrcdir)/mail/installer/windows ifeq (WINNT,$(OS_ARCH)) UNINSTALLER_PACKAGE_HOOK = $(RM) -r $(STAGEDIST)/uninstall; \ @@ -72,9 +72,9 @@ libs:: searchplugins # be included in langpack xpis. DIST_SUBDIRS = $(DIST_SUBDIR) -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk -include $(topsrcdir)/mozilla/toolkit/locales/l10n.mk +include $(moztopsrcdir)/toolkit/locales/l10n.mk $(list-json): $(call mkdir_deps,$(SEARCHPLUGINS_PATH)) $(if $(IS_LANGUAGE_REPACK),FORCE) $(call py_action,generate_searchjson,$(srcdir)/search/list.json $(AB_CD) $(list-json)) @@ -147,13 +147,13 @@ endif ident: @printf 'comm_revision ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/application.ini App SourceStamp @printf 'moz_revision ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/platform.ini Build SourceStamp @printf 'buildid ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/application.ini App BuildID #These make targets call prepare-repackages by setting different UPLOAD_DIR @@ -199,8 +199,8 @@ l10n-check:: $(MAKE) installers-x-test L10NBASEDIR='$(PWD)' ifdef MOZ_CALENDAR -LIGHTNING_PATH=$(DEPTH)/calendar/lightning -GDATA_PATH=$(DEPTH)/calendar/providers/gdata +LIGHTNING_PATH=$(COMMDEPTH)/calendar/lightning +GDATA_PATH=$(COMMDEPTH)/calendar/providers/gdata define run-calendar-rule $(MAKE) -C $(LIGHTNING_PATH) $(subst calendar-,,$@) AB_CD=$(AB_CD) diff --git a/mail/moz.build b/mail/moz.build index 1fce45848d..8345ed627c 100644 --- a/mail/moz.build +++ b/mail/moz.build @@ -18,7 +18,7 @@ if CONFIG['MAKENSISU']: DIRS += ['installer/windows'] if CONFIG['MOZ_BUNDLED_FONTS']: - DIRS += ['/mozilla/browser/fonts'] + DIRS += ['/%s/browser/fonts' % CONFIG['mozreltopsrcdir']] TEST_DIRS += ['test/mozmill'] diff --git a/mail/test/mozmill/Makefile.in b/mail/test/mozmill/Makefile.in index 60c7643749..3650ee7268 100644 --- a/mail/test/mozmill/Makefile.in +++ b/mail/test/mozmill/Makefile.in @@ -3,7 +3,7 @@ # 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/. -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk # We're installing to _tests/mozmill _DEST_DIR = $(DEPTH)/_tests/mozmill @@ -18,12 +18,12 @@ $(_DEST_DIR): VIRTUALENV_DIR = $(_DEST_DIR)/../mozmill-virtualenv mozmill-virtualenv: NSDISTMODE=copy mozmill-virtualenv: $(_DEST_DIR) - $(INSTALL) $(topsrcdir)/mail/test/resources $(_DEST_DIR) - $(INSTALL) $(topsrcdir)/mozilla/third_party/python/virtualenv $(_DEST_DIR)/resources/ + $(INSTALL) $(commtopsrcdir)/mail/test/resources $(_DEST_DIR) + $(INSTALL) $(moztopsrcdir)/third_party/python/virtualenv $(_DEST_DIR)/resources/ rm -rf $(VIRTUALENV_DIR) && \ mkdir $(VIRTUALENV_DIR) && \ unset MACOSX_DEPLOYMENT_TARGET && \ - $(PYTHON) $(_DEST_DIR)/resources/installmozmill.py $(VIRTUALENV_DIR) $(MOZILLA_DIR)/testing/mozbase + $(PYTHON) $(_DEST_DIR)/resources/installmozmill.py $(VIRTUALENV_DIR) $(moztopsrcdir)/testing/mozbase libs:: mozmill-virtualenv @@ -31,5 +31,5 @@ PKG_STAGE = $(DIST)/test-stage stage-package: $(NSINSTALL) -D $(PKG_STAGE)/mozmill/ - @(cd $(topsrcdir)/mail/test/mozmill && tar $(TAR_CREATE_FLAGS) - *) | (cd $(PKG_STAGE)/mozmill/ && tar -xf -) + @(cd $(commtopsrcdir)/mail/test/mozmill && tar $(TAR_CREATE_FLAGS) - *) | (cd $(PKG_STAGE)/mozmill/ && tar -xf -) @(cd $(DEPTH)/_tests/mozmill && tar $(TAR_CREATE_FLAGS) - *) | (cd $(PKG_STAGE)/mozmill/ && tar -xf -) diff --git a/mail/test/mozmill/moz.build b/mail/test/mozmill/moz.build index dcbc9ac473..b959694928 100644 --- a/mail/test/mozmill/moz.build +++ b/mail/test/mozmill/moz.build @@ -10,8 +10,7 @@ TEST_HARNESS_FILES.mozmill += [ ] TEST_HARNESS_FILES.mozmill.resources += [ - '/mail/base/test/unit/resources/**', - '/mailnews/test/fakeserver/**', - '/mailnews/test/resources/**', + '/%s/mail/base/test/unit/resources/**' % CONFIG['commreltopsrcdir'], + '/%s/mailnews/test/fakeserver/**' % CONFIG['commreltopsrcdir'], + '/%s/mailnews/test/resources/**' % CONFIG['commreltopsrcdir'] ] - diff --git a/mail/test/mozmill/shared-modules/test-folder-display-helpers.js b/mail/test/mozmill/shared-modules/test-folder-display-helpers.js index 733c6ae02e..603012d799 100644 --- a/mail/test/mozmill/shared-modules/test-folder-display-helpers.js +++ b/mail/test/mozmill/shared-modules/test-folder-display-helpers.js @@ -2895,7 +2895,7 @@ function load_via_src_path(aPath, aModule) { } // If we've got this far, then we weren't successful, fail out. - throw new Error("Could not find " + aModule + " in available paths"); + throw new Error("Could not find " + aPath + " in available paths"); } function assert_equals(a, b, comment) diff --git a/mail/testsuite-targets.mk b/mail/testsuite-targets.mk index 033eb5c15a..afb4802362 100644 --- a/mail/testsuite-targets.mk +++ b/mail/testsuite-targets.mk @@ -31,7 +31,7 @@ mozmill: unset PYTHONHOME && cd $(MOZMILLDIR) && MACOSX_DEPLOYMENT_TARGET= \ $(MOZMILLPYTHON) runtestlist.py --list=mozmilltests.list \ --binary=$(abspath $(BINARY)) \ - --dir=$(abspath $(topsrcdir))/../mail/test/mozmill \ + --dir=$(commtopsrcdir)/mail/test/mozmill \ --symbols-path=$(ABS_DIST)/crashreporter-symbols \ --plugins-path=$(ABS_DIST)/plugins \ --testing-modules-dir=$(topobjdir)/_tests/modules \ @@ -41,7 +41,7 @@ mozmill-one: solo-test = $(find-solo-test) mozmill-one: unset PYTHONHOME && cd $(MOZMILLDIR) && MACOSX_DEPLOYMENT_TARGET= \ $(MOZMILLPYTHON) runtest.py \ - --test=$(abspath $(topsrcdir))/../mail/test/mozmill/$(solo-test) \ + --test=$(commtopsrcdir)/mail/test/mozmill/$(solo-test) \ --binary=$(abspath $(BINARY)) \ --symbols-path=$(ABS_DIST)/crashreporter-symbols \ --plugins-path=$(ABS_DIST)/plugins \ @@ -57,10 +57,10 @@ package-tests: stage-mozmill endif stage-mozmill: make-stage-dir - $(MAKE) -C $(DEPTH)/mail/test/mozmill stage-package + $(MAKE) -C $(COMMDEPTH)/mail/test/mozmill stage-package stage-calendar: make-stage-dir - $(MAKE) -C $(DEPTH)/calendar/lightning stage-package - $(MAKE) -C $(DEPTH)/calendar/providers/gdata stage-package + $(MAKE) -C $(COMMDEPTH)/calendar/lightning stage-package + $(MAKE) -C $(COMMDEPTH)/calendar/providers/gdata stage-package .PHONY: stage-mozmill stage-calendar diff --git a/mailnews/base/src/moz.build b/mailnews/base/src/moz.build index bc978722b2..3ae0274ee2 100644 --- a/mailnews/base/src/moz.build +++ b/mailnews/base/src/moz.build @@ -78,7 +78,7 @@ EXTRA_JS_MODULES += [ 'virtualFolderWrapper.js', ] LOCAL_INCLUDES += [ - '/mozilla/dom/base' + '/%s/dom/base' % CONFIG['mozreltopsrcdir'], ] FINAL_LIBRARY = 'mail' diff --git a/mailnews/base/test/moz.build b/mailnews/base/test/moz.build index 13df5cc198..738ba664d7 100644 --- a/mailnews/base/test/moz.build +++ b/mailnews/base/test/moz.build @@ -12,6 +12,6 @@ UNIFIED_SOURCES += [ ] LOCAL_INCLUDES += [ - '/mozilla/netwerk/test', - '/mozilla/xpcom/tests', + '/%s/netwerk/test' % CONFIG['mozreltopsrcdir'], + '/%s/xpcom/tests' % CONFIG['mozreltopsrcdir'], ] diff --git a/mailnews/base/util/moz.build b/mailnews/base/util/moz.build index 13eafc9c56..0235fc33e3 100644 --- a/mailnews/base/util/moz.build +++ b/mailnews/base/util/moz.build @@ -67,7 +67,7 @@ EXTRA_JS_MODULES += [ ] LOCAL_INCLUDES += [ - '/mozilla/netwerk/base' + '/%s/netwerk/base' % CONFIG['mozreltopsrcdir'] ] FINAL_LIBRARY = 'mail' diff --git a/mailnews/build/moz.build b/mailnews/build/moz.build index b60f11d1a6..0837f092bd 100644 --- a/mailnews/build/moz.build +++ b/mailnews/build/moz.build @@ -32,22 +32,22 @@ if CONFIG['MOZ_WIDGET_TOOLKIT'] == 'cocoa': OS_LIBS += ['-framework Cocoa'] LOCAL_INCLUDES += [ - '/mailnews/addrbook/src', - '/mailnews/base/search/src', - '/mailnews/base/src', - '/mailnews/base/util', - '/mailnews/compose/src', - '/mailnews/extensions/bayesian-spam-filter/src', - '/mailnews/extensions/fts3/src', - '/mailnews/extensions/mailviews/src', - '/mailnews/extensions/mdn/src', - '/mailnews/extensions/smime/src', - '/mailnews/imap/src', - '/mailnews/intl', - '/mailnews/local/src', - '/mailnews/mime/emitters', - '/mailnews/mime/src', - '/mailnews/news/src', + '../addrbook/src', + '../base/search/src', + '../base/src', + '../base/util', + '../compose/src', + '../extensions/bayesian-spam-filter/src', + '../extensions/fts3/src', + '../extensions/mailviews/src', + '../extensions/mdn/src', + '../extensions/smime/src', + '../imap/src', + '../intl', + '../local/src', + '../mime/emitters', + '../mime/src', + '../news/src', ] if CONFIG['MOZ_LDAP_XPCOM']: diff --git a/mailnews/extensions/smime/src/moz.build b/mailnews/extensions/smime/src/moz.build index f3e888dd42..d7a9efa15f 100644 --- a/mailnews/extensions/smime/src/moz.build +++ b/mailnews/extensions/smime/src/moz.build @@ -18,6 +18,6 @@ EXTRA_COMPONENTS += [ FINAL_LIBRARY = 'mail' LOCAL_INCLUDES += [ - '/mozilla/security/manager/pki', - '/mozilla/security/pkix/include' + '/%s/security/manager/pki' % CONFIG['mozreltopsrcdir'], + '/%s/security/pkix/include' % CONFIG['mozreltopsrcdir'] ] diff --git a/mailnews/imap/test/moz.build b/mailnews/imap/test/moz.build index 8edf8a9994..b54125bc76 100644 --- a/mailnews/imap/test/moz.build +++ b/mailnews/imap/test/moz.build @@ -6,9 +6,9 @@ XPCSHELL_TESTS_MANIFESTS += ['unit/xpcshell.ini'] LOCAL_INCLUDES += [ + '../../base/util', '../src', - '/mailnews/base/util', - '/mozilla/xpcom/tests', + '/%s/xpcom/tests' % CONFIG['mozreltopsrcdir'], ] USE_LIBS += [ diff --git a/mailnews/intl/moz.build b/mailnews/intl/moz.build index 9c88da129f..7a8649c821 100644 --- a/mailnews/intl/moz.build +++ b/mailnews/intl/moz.build @@ -20,14 +20,14 @@ UNIFIED_SOURCES += [ XPIDL_MODULE = 'commuconv' LOCAL_INCLUDES += [ - '/mozilla/intl/locale', + '/%s/intl/locale' % CONFIG['mozreltopsrcdir'], ] GENERATED_FILES += [ 'charsetalias.properties.h', ] charsetalias = GENERATED_FILES['charsetalias.properties.h'] -charsetalias.script = '../../mozilla/intl/locale/props2arrays.py' +charsetalias.script = '/%s/intl/locale/props2arrays.py' % CONFIG['mozreltopsrcdir'] charsetalias.inputs = ['charsetalias.properties'] FINAL_LIBRARY = 'mail' diff --git a/mailnews/jsaccount/test/idl/moz.build b/mailnews/jsaccount/test/idl/moz.build index 4bc9a27fb1..e307f60234 100644 --- a/mailnews/jsaccount/test/idl/moz.build +++ b/mailnews/jsaccount/test/idl/moz.build @@ -9,6 +9,11 @@ XPIDL_SOURCES += [ XPIDL_MODULE = 'testJsAccount' -TEST_HARNESS_FILES.xpcshell.mailnews.jsaccount.test.unit.resources += [ +if 'comm' in CONFIG['MOZ_BUILD_APP']: + test_harness_base = TEST_HARNESS_FILES.xpcshell.comm +else: + test_harness_base = TEST_HARNESS_FILES.xpcshell + +test_harness_base.mailnews.jsaccount.test.unit.resources += [ '!/dist/bin/components/testJsAccount.xpt', ] diff --git a/mailnews/mailnews.mozbuild b/mailnews/mailnews.mozbuild index 12ae6cd2e4..8829d830ae 100644 --- a/mailnews/mailnews.mozbuild +++ b/mailnews/mailnews.mozbuild @@ -5,12 +5,11 @@ if CONFIG['MOZ_LDAP_XPCOM']: DIRS += [ - '/ldap', - '/ldap/xpcom', + '/%s/ldap' % CONFIG['commreltopsrcdir'], + '/%s/ldap/xpcom' % CONFIG['commreltopsrcdir'], ] if CONFIG['MOZ_MORK']: - DIRS += ['/db'] - -DIRS += ['/mailnews'] + DIRS += ['/%s/db' % CONFIG['commreltopsrcdir']] +DIRS += ['/%s/mailnews' % CONFIG['commreltopsrcdir']] diff --git a/mailnews/mime/src/moz.build b/mailnews/mime/src/moz.build index 59e516c34d..ec0847eaf9 100644 --- a/mailnews/mime/src/moz.build +++ b/mailnews/mime/src/moz.build @@ -70,9 +70,9 @@ SOURCES += [ ] LOCAL_INCLUDES += [ - '/mozilla/security/certverifier', - '/mozilla/security/manager/ssl', - '/mozilla/security/pkix/include', + '/%s/security/certverifier' % CONFIG['mozreltopsrcdir'], + '/%s/security/manager/ssl' % CONFIG['mozreltopsrcdir'], + '/%s/security/pkix/include' % CONFIG['mozreltopsrcdir'], ] EXTRA_COMPONENTS += [ diff --git a/mailnews/moz.build b/mailnews/moz.build index 935fb239a4..050dbffe2a 100644 --- a/mailnews/moz.build +++ b/mailnews/moz.build @@ -77,12 +77,17 @@ TESTING_JS_MODULES.mailnews += [ 'test/resources/PromiseTestUtils.jsm', ] -TEST_HARNESS_FILES.xpcshell.mailnews.data += [ - '/mailnews/test/data/**', +if 'comm' in CONFIG['MOZ_BUILD_APP']: + test_harness_base = TEST_HARNESS_FILES.xpcshell.comm +else: + test_harness_base = TEST_HARNESS_FILES.xpcshell + +test_harness_base.mailnews.data += [ + '/%s/mailnews/test/data/**' % CONFIG['commreltopsrcdir'], ] -TEST_HARNESS_FILES.xpcshell.mailnews.resources += [ - '/mailnews/test/resources/**', +test_harness_base.mailnews.resources += [ + '/%s/mailnews/test/resources/**' % CONFIG['commreltopsrcdir'], ] JS_PREFERENCE_PP_FILES += [ diff --git a/suite/Makefile.in b/suite/Makefile.in index 0afeeea44b..2dfd39f7cd 100644 --- a/suite/Makefile.in +++ b/suite/Makefile.in @@ -3,7 +3,7 @@ # 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/. -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk ifdef MAKENSISU # For Windows build the uninstaller during the application build since the @@ -17,7 +17,7 @@ endif # platform.ini are the same, which isn't a problem for Firefox, but # it's not right for anything else. So we correct platform.ini here. -MOZ_REV=$(shell hg -R "$(MOZILLA_SRCDIR)" parent --template="{node}" 2>/dev/null) +MOZ_REV=$(shell hg -R "$(moztopsrcdir)" parent --template="{node}" 2>/dev/null) libs:: $(DIST)/bin/platform.ini sed -e "s/^\(SourceStamp=\).*/\1$(MOZ_REV)/" $(DIST)/bin/platform.ini \ diff --git a/suite/app-config.mk b/suite/app-config.mk new file mode 100644 index 0000000000..0d3d6bd3f0 --- /dev/null +++ b/suite/app-config.mk @@ -0,0 +1,9 @@ +# 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/. + +ifeq ($(findstring comm,$(MOZ_BUILD_APP)),) +COMMDEPTH = $(DEPTH) +else +COMMDEPTH = $(DEPTH)/comm +endif diff --git a/suite/app.mozbuild b/suite/app.mozbuild index b8a65b8cde..a9b3b00cad 100644 --- a/suite/app.mozbuild +++ b/suite/app.mozbuild @@ -3,7 +3,7 @@ # 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/. -include('/mailnews/mailnews.mozbuild') +include('/%s/mailnews/mailnews.mozbuild' % CONFIG['commreltopsrcdir']) include('/toolkit/toolkit.mozbuild') @@ -11,17 +11,17 @@ if CONFIG['MOZ_EXTENSIONS']: DIRS += ['/extensions'] if CONFIG['MOZ_COMPOSER']: - DIRS += ['/editor/ui'] + DIRS += ['/%s/editor/ui' % CONFIG['commreltopsrcdir']] DIRS += ['/%s' % CONFIG['MOZ_BRANDING_DIRECTORY']] if CONFIG['MOZ_CALENDAR']: DIRS += [ - '/calendar/lightning', - '/calendar/timezones' + '/%s/calendar/lightning' % CONFIG['commreltopsrcdir'], + '/%s/calendar/timezones' % CONFIG['commreltopsrcdir'] ] DIRS += [ '/xpfe/components/autocomplete', - '/suite', + '/%s/suite' % CONFIG['commreltopsrcdir'], ] diff --git a/suite/app/Makefile.in b/suite/app/Makefile.in index 7927e2b1ab..1830a58f8c 100644 --- a/suite/app/Makefile.in +++ b/suite/app/Makefile.in @@ -23,7 +23,7 @@ endif # shouldn't get 755 perms need $(IFLAGS1) for either way of calling nsinstall. NSDISTMODE = copy -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk # If we are trying to show an error dialog about the lack of SSE2 support, # make sure that code itself doesn't use SSE2. @@ -42,14 +42,14 @@ ifeq ($(OS_ARCH),WINNT) EXTRA_DEPS += seamonkey.exe.manifest endif -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk libs:: ifeq ($(OS_ARCH),WINNT) $(EXIT_ON_ERROR) \ - $(PERL) -pe 's/(? $(DIST)/bin/license.txt + $(PERL) -pe 's/(? $(DIST)/bin/license.txt else - $(INSTALL) $(IFLAGS1) $(topsrcdir)/suite/installer/license.txt $(DIST)/bin/ + $(INSTALL) $(IFLAGS1) $(commtopsrcdir)/suite/installer/license.txt $(DIST)/bin/ endif ifneq ($(OS_ARCH),WINNT) diff --git a/suite/app/moz.build b/suite/app/moz.build index 6d4d1ce0f2..b78034fa7d 100644 --- a/suite/app/moz.build +++ b/suite/app/moz.build @@ -8,9 +8,9 @@ USE_LIBS += ['mozglue'] SOURCES += ['nsSuiteApp.cpp'] LOCAL_INCLUDES += [ '!/build', - '/mozilla/toolkit/xre', - '/mozilla/xpcom/base', - '/mozilla/xpcom/build', + '/%s/toolkit/xre' % CONFIG['mozreltopsrcdir'], + '/%s/xpcom/base' % CONFIG['mozreltopsrcdir'], + '/%s/xpcom/build' % CONFIG['mozreltopsrcdir'], ] if CONFIG['OS_ARCH'] == 'WINNT': @@ -20,7 +20,7 @@ if CONFIG['OS_ARCH'] == 'WINNT': if CONFIG['LIBFUZZER']: USE_LIBS += [ 'fuzzer' ] LOCAL_INCLUDES += [ - '/mozilla//tools/fuzzing/libfuzzer', + '/%s/tools/fuzzing/libfuzzer' % CONFIG['mozreltopsrcdir'], ] if CONFIG['_MSC_VER']: @@ -31,8 +31,8 @@ if CONFIG['_MSC_VER']: if CONFIG['MOZ_SANDBOX'] and CONFIG['OS_ARCH'] == 'WINNT': # For sandbox includes and the include dependencies those have LOCAL_INCLUDES += [ - '/mozilla/security/sandbox/chromium', - '/mozilla/security/sandbox/chromium-shim', + '/%s/security/sandbox/chromium' % CONFIG['mozreltopsrcdir'], + '/%s/security/sandbox/chromium-shim' % CONFIG['mozreltopsrcdir'], ] USE_LIBS += [ diff --git a/suite/branding/nightly/Makefile.in b/suite/branding/nightly/Makefile.in index f6597f8335..b0264f861a 100644 --- a/suite/branding/nightly/Makefile.in +++ b/suite/branding/nightly/Makefile.in @@ -6,7 +6,7 @@ # Note: mac icons are handled in /suite/app during the final application # packaging -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk export:: $(NSINSTALL) -D $(DIST)/branding diff --git a/suite/browser/Makefile.in b/suite/browser/Makefile.in index a080ae4149..072cb31596 100644 --- a/suite/browser/Makefile.in +++ b/suite/browser/Makefile.in @@ -3,7 +3,7 @@ # 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/. -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk # channel-prefs.js is handled separate from other prefs due to bug 756325. libs:: $(srcdir)/channel-prefs.js diff --git a/suite/build/Makefile.in b/suite/build/Makefile.in index 2387227ab4..60ec669540 100644 --- a/suite/build/Makefile.in +++ b/suite/build/Makefile.in @@ -2,7 +2,7 @@ # 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/. -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk # Ensure that we don't embed a manifest referencing the CRT. EMBED_MANIFEST_AT = diff --git a/suite/build/moz.build b/suite/build/moz.build index a52dfc7282..f85e8693a6 100644 --- a/suite/build/moz.build +++ b/suite/build/moz.build @@ -15,8 +15,8 @@ Library('suite') FINAL_LIBRARY = 'xul' LOCAL_INCLUDES += [ - '/suite/feeds/src', - '/suite/profile', - '/suite/profile/migration/src', - '/suite/shell/src', + '../feeds/src', + '../profile', + '../profile/migration/src', + '../shell/src', ] diff --git a/suite/common/jar.mn b/suite/common/jar.mn index 2eb8709c05..239e7bda9a 100644 --- a/suite/common/jar.mn +++ b/suite/common/jar.mn @@ -1,3 +1,5 @@ +#filter substitution + comm.jar: % content communicator %content/communicator/ contentaccessible=yes % content help %content/communicator/helpviewer/ @@ -71,9 +73,9 @@ comm.jar: content/communicator/helpEditorOverlay.xul content/communicator/helpMessengerOverlay.xul content/communicator/helpSecurityOverlay.xul - content/communicator/labelsencodings.properties (/mozilla/dom/encoding/labelsencodings.properties) + content/communicator/labelsencodings.properties (/@mozreltopsrcdir@/dom/encoding/labelsencodings.properties) # the following file is a suite-specific override of the generic license.html, using suite/common/app-license.html as input: -* content/communicator/license.html (/mozilla/toolkit/content/license.html) +* content/communicator/license.html (/@mozreltopsrcdir@/toolkit/content/license.html) content/communicator/nsContextMenu.js content/communicator/openLocation.js content/communicator/openLocation.xul diff --git a/suite/common/moz.build b/suite/common/moz.build index 12eabf5eb7..8abb14b833 100644 --- a/suite/common/moz.build +++ b/suite/common/moz.build @@ -41,5 +41,5 @@ JAR_MANIFESTS += ['jar.mn'] # chrome://global/content/license.html (about:license) DEFINES['APP_LICENSE_BLOCK'] = '%s/app-license.html' % SRCDIR -for var in ('MOZ_APP_NAME', 'MOZ_MACBUNDLE_NAME'): +for var in ('MOZ_APP_NAME', 'MOZ_MACBUNDLE_NAME', 'mozreltopsrcdir'): DEFINES[var] = CONFIG[var] diff --git a/suite/configure.in b/suite/configure.in index 94d4e98330..82a02f7072 100644 --- a/suite/configure.in +++ b/suite/configure.in @@ -12,6 +12,12 @@ AC_SUBST(SEAMONKEY_VERSION) AC_DEFINE(MOZ_SEPARATE_MANIFEST_FOR_THEME_OVERRIDES) AC_SUBST(MOZ_BUNDLED_FONTS) +dnl More things we need to carry from confvars.sh +AC_SUBST(moztopsrcdir) +AC_SUBST(commtopsrcdir) +AC_SUBST(mozreltopsrcdir) +AC_SUBST(commreltopsrcdir) + dnl Optional parts of the build. AC_SUBST(MOZ_MORK) if test "$MOZ_MORK"; then diff --git a/suite/confvars.sh b/suite/confvars.sh index c8b7f8efe1..21c41f277e 100755 --- a/suite/confvars.sh +++ b/suite/confvars.sh @@ -3,6 +3,8 @@ # 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/. +source ${_topsrcdir}/$MOZ_BUILD_APP/../comm-confvars.sh + MOZ_APP_BASENAME=SeaMonkey MOZ_APP_VENDOR=Mozilla MOZ_APP_NAME=seamonkey @@ -10,8 +12,8 @@ MOZ_APP_DISPLAYNAME=SeaMonkey MOZ_LDAP_XPCOM=1 MOZ_COMPOSER=1 MOZ_SUITE=1 -MOZ_BRANDING_DIRECTORY=suite/branding/nightly -MOZ_OFFICIAL_BRANDING_DIRECTORY=suite/branding/nightly +MOZ_BRANDING_DIRECTORY=$commreltopsrcdir/suite/branding/nightly +MOZ_OFFICIAL_BRANDING_DIRECTORY=$commreltopsrcdir/suite/branding/nightly MOZ_EXTENSIONS_DEFAULT=" inspector irc" MOZ_UPDATER=1 # This should usually be the same as the value MAR_CHANNEL_ID. diff --git a/suite/installer/Makefile.in b/suite/installer/Makefile.in index 556e5f89ab..a3ca8b5be5 100644 --- a/suite/installer/Makefile.in +++ b/suite/installer/Makefile.in @@ -4,7 +4,7 @@ STANDALONE_MAKEFILE := 1 -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk MOZ_PKG_REMOVALS = $(srcdir)/removed-files.in @@ -17,7 +17,7 @@ endif MOZ_PKG_DUPEFLAGS = \ -w \ -f $(srcdir)/allowed-dupes.mn \ - -f $(MOZILLA_DIR)/browser/installer/allowed-dupes.mn \ + -f $(moztopsrcdir)/browser/installer/allowed-dupes.mn \ $(NULL) MOZ_NONLOCALIZED_PKG_LIST = \ @@ -158,7 +158,7 @@ NON_OMNIJAR_FILES = \ defaults/profile/chrome/userContent-example.css \ $(NULL) -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/packager.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/packager.mk ifeq (Darwin, $(OS_ARCH)) BINPATH = $(_BINPATH) @@ -231,7 +231,7 @@ ifdef INSTALLER_DIR endif # The comm-* source stamp is already there. -PLATFORM_SOURCE_STAMP = $(firstword $(shell hg -R "$(MOZILLA_SRCDIR)" parent --template="{node|short}\n" 2>/dev/null)) -PLATFORM_SOURCE_REPO = $(shell hg -R "$(MOZILLA_SRCDIR)" showconfig paths.default 2>/dev/null | sed -e "s/^ssh:/https:/") +PLATFORM_SOURCE_STAMP = $(firstword $(shell hg -R "$(moztopsrcdir)" parent --template="{node|short}\n" 2>/dev/null)) +PLATFORM_SOURCE_REPO = $(shell hg -R "$(moztopsrcdir)" showconfig paths.default 2>/dev/null | sed -e "s/^ssh:/https:/") make-sourcestamp-file:: @echo "$(PLATFORM_SOURCE_REPO)/rev/$(PLATFORM_SOURCE_STAMP)" >> $(MOZ_SOURCESTAMP_FILE) diff --git a/suite/installer/windows/Makefile.in b/suite/installer/windows/Makefile.in index 6ba7a71f74..9fee49b304 100644 --- a/suite/installer/windows/Makefile.in +++ b/suite/installer/windows/Makefile.in @@ -2,10 +2,10 @@ # 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/. -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/package-name.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/package-name.mk CONFIG_DIR = instgen -SFX_MODULE = $(topsrcdir)/other-licenses/7zstub/seamonkey/7zSD.sfx +SFX_MODULE = $(commtopsrcdir)/other-licenses/7zstub/seamonkey/7zSD.sfx INSTALLER_FILES = \ app.tag \ @@ -26,7 +26,7 @@ ifdef MOZ_UPDATER DEFINES += -DMOZ_UPDATER=1 endif -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk OVERRIDE_DEFAULT_GOAL := installer installer:: @@ -41,21 +41,21 @@ uninstaller:: $(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) $(CONFIG_DIR) $(call py_action,preprocessor,-Fsubstitution $(DEFINES) $(ACDEFINES) \ $(srcdir)/nsis/defines.nsi.in -o $(CONFIG_DIR)/defines.nsi) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --preprocess-locale $(MOZILLA_SRCDIR) \ + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --preprocess-locale $(moztopsrcdir) \ $(call EXPAND_LOCALE_SRCDIR,suite/locales)/installer/windows $(AB_CD) $(CONFIG_DIR) $(CONFIG_DIR)/setup.exe:: $(RM) -r $(CONFIG_DIR) && mkdir $(CONFIG_DIR) $(INSTALL) $(addprefix $(srcdir)/,$(INSTALLER_FILES)) $(CONFIG_DIR) $(INSTALL) $(addprefix $(DIST)/branding/,$(BRANDING_FILES)) $(CONFIG_DIR) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --convert-utf8-utf16le $(topsrcdir)/suite/installer/license.txt $(CONFIG_DIR)/license.txt + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --convert-utf8-utf16le $(commtopsrcdir)/suite/installer/license.txt $(CONFIG_DIR)/license.txt $(call py_action,preprocessor,-Fsubstitution $(DEFINES) $(ACDEFINES) \ $(srcdir)/nsis/defines.nsi.in -o $(CONFIG_DIR)/defines.nsi) - $(PYTHON) $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ - --preprocess-locale $(MOZILLA_SRCDIR) \ + $(PYTHON) $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/preprocess-locale.py \ + --preprocess-locale $(moztopsrcdir) \ $(call EXPAND_LOCALE_SRCDIR,suite/locales)/installer/windows $(AB_CD) $(CONFIG_DIR) -include $(topsrcdir)/config/rules.mk -include $(MOZILLA_SRCDIR)/toolkit/mozapps/installer/windows/nsis/makensis.mk +include $(moztopsrcdir)/config/rules.mk +include $(moztopsrcdir)/toolkit/mozapps/installer/windows/nsis/makensis.mk diff --git a/suite/locales/Makefile.in b/suite/locales/Makefile.in index 6b16dd5ad9..bcf45ecabb 100644 --- a/suite/locales/Makefile.in +++ b/suite/locales/Makefile.in @@ -2,9 +2,9 @@ # 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/. -include $(topsrcdir)/config/config.mk +include $(moztopsrcdir)/config/config.mk -_ABS_SRCDIR := $(abspath $(topsrcdir)) +_ABS_SRCDIR := $(abspath $(commtopsrcdir)) vpath %.xml @srcdir@/en-US/searchplugins vpath %.xml $(LOCALE_SRCDIR)/searchplugins @@ -38,8 +38,8 @@ MOZ_PKG_MAC_ICON=$(ABS_DIST)/branding/disk.icns MOZ_PKG_MAC_EXTRA=--symlink '/Applications:/ ' endif -MOZ_SFX_PACKAGE=$(topsrcdir)/other-licenses/7zstub/seamonkey/7zSD.sfx -MOZ_INSTALLER_PATH=$(topsrcdir)/suite/installer/windows +MOZ_SFX_PACKAGE=$(commtopsrcdir)/other-licenses/7zstub/seamonkey/7zSD.sfx +MOZ_INSTALLER_PATH=$(commtopsrcdir)/suite/installer/windows ifeq (WINNT,$(OS_ARCH)) UNINSTALLER_PACKAGE_HOOK = $(RM) -r $(STAGEDIST)/uninstall; \ @@ -68,9 +68,9 @@ SEARCH_PLUGINS := $(foreach plugin,$(addsuffix .xml,$(SEARCH_PLUGINS_NAMES)),$(o SEARCH_PLUGINS_FLAGS := --silence-missing-directive-warnings PP_TARGETS += SEARCH_PLUGINS -include $(topsrcdir)/config/rules.mk +include $(moztopsrcdir)/config/rules.mk -include $(topsrcdir)/mozilla/toolkit/locales/l10n.mk +include $(moztopsrcdir)/toolkit/locales/l10n.mk $(DIST)/branding: $(NSINSTALL) -D $@ @@ -183,19 +183,19 @@ endif ident: @printf 'comm_revision ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/application.ini App SourceStamp @printf 'moz_revision ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/platform.ini Build SourceStamp @printf 'buildid ' - @$(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py \ + @$(PYTHON) $(moztopsrcdir)/config/printconfigsetting.py \ $(STAGEDIST)/application.ini App BuildID merge-%: ifdef LOCALE_MERGEDIR $(RM) -rf $(LOCALE_MERGEDIR) - $(topsrcdir)/mozilla/mach compare-locales --merge-dir $(LOCALE_MERGEDIR) --l10n-ini $(srcdir)/l10n.ini $* + $(moztopsrcdir)/mach compare-locales --merge-dir $(LOCALE_MERGEDIR) --l10n-ini $(srcdir)/l10n.ini $* endif @echo diff --git a/suite/moz.build b/suite/moz.build index bc488144b7..2265860fbe 100644 --- a/suite/moz.build +++ b/suite/moz.build @@ -30,7 +30,7 @@ if CONFIG['MAKENSISU']: DIRS += ['installer/windows'] if CONFIG['MOZ_BUNDLED_FONTS']: - DIRS += ['/mozilla/browser/fonts'] + DIRS += ['/%s/browser/fonts' % CONFIG['mozreltopsrcdir']] # app is always last as it packages up the built files on mac. DIRS += [ diff --git a/suite/themes/modern/moz.build b/suite/themes/modern/moz.build index 95700686a6..ad62e18fb6 100644 --- a/suite/themes/modern/moz.build +++ b/suite/themes/modern/moz.build @@ -12,6 +12,7 @@ JAR_MANIFESTS += ['jar.mn'] USE_EXTENSION_MANIFEST = True DEFINES['SEAMONKEY_VERSION'] = CONFIG['SEAMONKEY_VERSION'] +DEFINES['mozreltopsrcdir'] = CONFIG['mozreltopsrcdir'] FINAL_TARGET_FILES += [ 'icon.png',