Shave 350K off of the compressed size of thunderbird by unzipping all of the JARs in a temporary chrome directory.

Then we repackage the JARs according to thunderbird specific manifests, leaving behind chrome, localization files and
content files we don't want (such as browser skin elements).
This commit is contained in:
scott%scott-macgregor.org 2003-05-01 02:36:51 +00:00
parent 8920a10716
commit c57ef3ac52
5 changed files with 56 additions and 9 deletions

View File

@ -31,12 +31,50 @@ BASEMAIL_SUPP = basemail-win-supp
APP_NAME=thunderbird
_PLATFORM = dos
mail_chrome: mail-jar.mn
-$(RM) -rf $(DIST)/$(APP_NAME)/
ifeq ($(OS_ARCH),WINNT)
$(NSINSTALL) -D $(DIST)/$(APP_NAME)/tmpchrome/comm
$(UNZIP) -o -d $(DIST)/$(APP_NAME)/tmpchrome/comm $(DIST)/bin/chrome/comm.jar
$(NSINSTALL) -D $(DIST)/$(APP_NAME)/tmpchrome/toolkit
$(UNZIP) -o -d $(DIST)/$(APP_NAME)/tmpchrome/toolkit $(DIST)/bin/chrome/toolkit.jar
$(NSINSTALL) -D $(DIST)/$(APP_NAME)/tmpchrome/msg
$(UNZIP) -o -d $(DIST)/$(APP_NAME)/tmpchrome/msg $(DIST)/bin/chrome/messenger.jar
$(NSINSTALL) -D $(DIST)/$(APP_NAME)/tmpchrome/classic
$(UNZIP) -o -d $(DIST)/$(APP_NAME)/tmpchrome/classic $(DIST)/bin/chrome/classic.jar
$(NSINSTALL) -D $(DIST)/$(APP_NAME)/tmpchrome/en-US
$(UNZIP) -o -d $(DIST)/$(APP_NAME)/tmpchrome/en-US $(DIST)/bin/chrome/en-US.jar
$(NSINSTALL) -D $(DIST)/$(APP_NAME)/tmpchrome/US
$(UNZIP) -o -d $(DIST)/$(APP_NAME)/tmpchrome/US $(DIST)/bin/chrome/US.jar
endif
$(PERL) -I$(srcdir) $(srcdir)/gen_mn.pl -manifest $(MOZILLA_DIR)/mail/config/mail-jar.mn -mozpath $(MOZILLA_DIR) -jarfile mail.jar -chrome $(DIST)/$(APP_NAME)/tmpchrome > $(MOZILLA_DIR)/mail/config/mail-tmp.mn
$(PERL) -I$(MOZILLA_DIR)/config $(MOZILLA_DIR)/config/make-jars.pl -a -v -f $(MOZ_CHROME_FILE_FORMAT) -d $(DIST)/bin/chrome -s $(DIST)/$(APP_NAME)/tmpchrome -z $(ZIP) < $(MOZILLA_DIR)/mail/config/mail-tmp.mn
$(PERL) -I$(srcdir) $(srcdir)/gen_mn.pl -manifest $(MOZILLA_DIR)/mail/config/qute-jar.mn -mozpath $(MOZILLA_DIR) -jarfile qute.jar -chrome $(DIST)/$(APP_NAME)/tmpchrome > $(MOZILLA_DIR)/mail/config/qute-tmp.mn
$(PERL) -I$(MOZILLA_DIR)/config $(MOZILLA_DIR)/config/make-jars.pl -a -v -f $(MOZ_CHROME_FILE_FORMAT) -d $(DIST)/bin/chrome -s $(DIST)/$(APP_NAME)/tmpchrome -z $(ZIP) < $(MOZILLA_DIR)/mail/config/qute-tmp.mn
$(PERL) -I$(srcdir) $(srcdir)/gen_mn.pl -manifest $(MOZILLA_DIR)/mail/config/en-US-jar.mn -mozpath $(MOZILLA_DIR) -jarfile en-US-mail.jar -chrome $(DIST)/$(APP_NAME)/tmpchrome > $(MOZILLA_DIR)/mail/config/en-US-tmp.mn
$(PERL) -I$(MOZILLA_DIR)/config $(MOZILLA_DIR)/config/make-jars.pl -a -v -f $(MOZ_CHROME_FILE_FORMAT) -d $(DIST)/bin/chrome -s $(DIST)/$(APP_NAME)/tmpchrome -z $(ZIP) < $(MOZILLA_DIR)/mail/config/en-US-tmp.mn
-$(RM) -f $(MOZILLA_DIR)/mail/config/mail-tmp.mn
-$(RM) -f $(MOZILLA_DIR)/mail/config/qute-tmp.mn
-$(RM) -f $(MOZILLA_DIR)/mail/config/en-US-tmp.mn
-$(RM) -rf $(DIST)/$(APP_NAME)/tmpchrome
mail_copy::
$(PERL) $(topsrcdir)/xpinstall/packager/pkgcp.pl -s $(DIST)/bin -d $(DIST) --f $(srcdir)/$(BASEMAIL) -o $(_PLATFORM) -v
$(NSINSTALL) -t $(DIST)/bin/$(APP_NAME)$(BIN_SUFFIX) $(DIST)/$(APP_NAME)/
$(NSINSTALL) -t $(DIST)/bin/chrome/installed-chrome.txt $(DIST)/$(APP_NAME)/chrome
$(NSINSTALL) -t $(MOZILLA_DIR)/mail/config/installed-chrome.txt $(DIST)/$(APP_NAME)/chrome
libs::
$(MAKE) mail_chrome
$(MAKE) mail_copy

View File

@ -24,7 +24,7 @@ components\import.xpt
components\impComm4xMail.xpt
components\mailview.xpt
chrome\messenger.jar
chrome\mail.jar
chrome\icons\default\abcardWindow.ico
chrome\icons\default\addressbookWindow.ico
chrome\icons\default\messengerWindow.ico
@ -50,15 +50,12 @@ components\msgsmime.dll
; Chrome Files
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
chrome\comm.jar
chrome\toolkit.jar
chrome\classic.jar
chrome\en-US.jar
chrome\qute.jar
chrome\en-US-mail.jar
chrome\en-win.jar
chrome\US.jar
chrome\pippki.jar
chrome\pipnss.jar
chrome\chrome.rdf
;chrome\chrome.rdf
chrome\overlayinfo\messenger\content\overlays.rdf
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@ -300,6 +297,7 @@ res\quirk.css
res\forms.css
res\platform-forms.css
res\builtin\*
res\entityTables\htmlEntityVersions.properties

View File

@ -12,6 +12,7 @@ locale/en-US/messenger, en-US/locale/en-US/mes
locale/en-US/messenger-mdn, en-US/locale/en-US/messenger-mdn
locale/en-US/messenger/addressbook, en-US/locale/en-US/messenger/addressbook
locale/en-US/messenger/messengercompose, en-US/locale/en-US/messenger/messengercompose
locale/en-US/messenger-smime, en-US/locale/en-US/messenger-smime
#################################################################################################
@ -21,6 +22,8 @@ locale/en-US/mozldap, en-US/locale/en-US/moz
locale/en-US/wallet, en-US/locale/en-US/wallet
locale/en-US/necko, en-US/locale/en-US/necko
locale/en-US/navigator/contents.rdf, en-US/locale/en-US/navigator/contents.rdf
locale/en-US/navigator/navigator.properties, en-US/locale/en-US/navigator/navigator.properties
#################################################################################################
@ -76,6 +79,10 @@ locale/en-US/editor/EditorReplace.dtd, en-US/locale/en-US/edi
locale/en-US/editor/EditorColorProperties.dtd, en-US/locale/en-US/editor/EditorColorProperties.dtd
locale/en-US/editor/EditorSpellCheck.dtd, en-US/locale/en-US/editor/EditorSpellCheck.dtd
locale/en-US/editor/EditorTableProperties.dtd, en-US/locale/en-US/editor/EditorTableProperties.dtd
locale/en-US/editor/EdColorPicker.dtd, en-US/locale/en-US/editor/EdColorPicker.dtd
locale/en-US/editor/editor.properties, en-US/locale/en-US/editor/editor.properties
locale/en-US/editor/EdNamedAnchorProperties.dtd, en-US/locale/en-US/editor/EdNamedAnchorProperties.dtd
locale/en-US/editor/EdAdvancedEdit.dtd, en-US/locale/en-US/editor/EdAdvancedEdit.dtd
#################################################################################################

View File

@ -3,6 +3,7 @@ locale,install,url,jar:resource:/chrome/en-US-mail.jar!/locale/en-US/necko/
content,install,url,jar:resource:/chrome/mail.jar!/content/xbl-marquee/
content,install,url,jar:resource:/chrome/mail.jar!/content/editor/
content,install,url,jar:resource:/chrome/mail.jar!/content/editor-region/
content,install,url,jar:resource:/chrome/mail.jar!/content/help/
locale,install,url,jar:resource:/chrome/en-US-mail.jar!/locale/en-US/editor/
skin,install,url,jar:resource:/chrome/qute.jar!/skin/classic/global/
skin,install,url,jar:resource:/chrome/qute.jar!/skin/classic/communicator/

View File

@ -23,6 +23,7 @@ content/messenger/addressbook, msg/content/messenger/addressbook
content/editor, comm/content/editor
content/editor-region, comm/content/editor-region
content/editor/images, comm/content/editor/images
content/communicator-region, comm/content/communicator-region,
content/communicator-platform, comm/content/communicator-platform
content/communicator/contents.rdf, comm/content/communicator/contents.rdf
@ -74,6 +75,8 @@ content/communicator/pref/pref.xul, comm/content/communicator/
content/communicator/pref/nsPrefWindow.js, comm/content/communicator/pref/nsPrefWindow.js
content/communicator/downloadmanager, comm/content/communicator/downloadmanager
content/help/contextHelp.js, comm/content/help/contextHelp.js
# from profile
content/communicator/profile, comm/content/communicator/profile