Bug 1160666 - Allow per-product b2g branding. r=fabrice

This commit is contained in:
Kevin Grandon 2015-05-07 11:44:24 -07:00
parent 0a6373bdc4
commit b5b02224c8
11 changed files with 60 additions and 8 deletions

View File

@ -20,7 +20,7 @@ NSDISTMODE = copy
include $(topsrcdir)/config/rules.mk
APP_ICON = b2g
APP_ICON = app
ifeq ($(OS_ARCH),WINNT)
REDIT_PATH = $(LIBXUL_DIST)/bin
@ -64,7 +64,7 @@ else
$(RM) $(DIST)/$(APP_NAME).app/Contents/MacOS/$(PROGRAM)
rsync -aL $(PROGRAM) $(DIST)/$(APP_NAME).app/Contents/MacOS
endif
cp -RL $(srcdir)/b2g.icns $(DIST)/$(APP_NAME).app/Contents/Resources/$(MOZ_APP_NAME).icns
cp -RL $(DIST)/branding/app.icns $(DIST)/$(APP_NAME).app/Contents/Resources/$(MOZ_APP_NAME).icns
printf APPLMOZB > $(DIST)/$(APP_NAME).app/Contents/PkgInfo
else # MOZ_WIDGET_TOOLKIT != cocoa
@ -79,11 +79,11 @@ endif
# Copy the app icon for b2g-desktop
ifeq ($(OS_ARCH),WINNT)
cp $(srcdir)/$(APP_ICON).ico $(DIST)/bin/chrome/icons/default/$(APP_ICON).ico
$(REDIT_PATH)/redit$(HOST_BIN_SUFFIX) $(DIST)/bin/$(APP_BINARY) $(srcdir)/$(APP_ICON).ico
cp $(srcdir)/$(APP_ICON).ico $(DIST)/bin/chrome/icons/default/default.ico
cp $(DIST)/branding/$(APP_ICON).ico $(DIST)/bin/chrome/icons/default/$(APP_ICON).ico
$(REDIT_PATH)/redit$(HOST_BIN_SUFFIX) $(DIST)/bin/$(APP_BINARY) $(DIST)/branding/$(APP_ICON).ico
cp $(DIST)/branding/$(APP_ICON).ico $(DIST)/bin/chrome/icons/default/default.ico
else ifneq (gonk,$(MOZ_WIDGET_TOOLKIT))
cp $(srcdir)/default.png $(DIST)/bin/chrome/icons/default/default.png
cp $(DIST)/branding/default.png $(DIST)/bin/chrome/icons/default/default.png
endif
endif

View File

@ -0,0 +1,27 @@
# 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
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
BRANDING_FILES := \
app.ico \
$(NULL)
endif
ifeq ($(MOZ_WIDGET_TOOLKIT),cocoa)
BRANDING_FILES := \
app.icns \
$(NULL)
endif
ifdef MOZ_WIDGET_GTK
BRANDING_FILES := \
default.png \
$(NULL)
endif
BRANDING_DEST := $(DIST)/branding
BRANDING_TARGET := export
INSTALL_TARGETS += BRANDING

View File

Before

Width:  |  Height:  |  Size: 4.2 KiB

After

Width:  |  Height:  |  Size: 4.2 KiB

View File

@ -3,5 +3,4 @@
# file, You can obtain one at http://mozilla.org/MPL/2.0/.
MOZ_APP_DISPLAYNAME=B2G
ANDROID_PACKAGE_NAME=org.mozilla.b2g
MOZ_UPDATER=

View File

Before

Width:  |  Height:  |  Size: 4.7 KiB

After

Width:  |  Height:  |  Size: 4.7 KiB

View File

@ -0,0 +1,27 @@
# 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
ifeq ($(MOZ_WIDGET_TOOLKIT),windows)
BRANDING_FILES := \
app.ico \
$(NULL)
endif
ifeq ($(MOZ_WIDGET_TOOLKIT),cocoa)
BRANDING_FILES := \
app.icns \
$(NULL)
endif
ifdef MOZ_WIDGET_GTK
BRANDING_FILES := \
default.png \
$(NULL)
endif
BRANDING_DEST := $(DIST)/branding
BRANDING_TARGET := export
INSTALL_TARGETS += BRANDING

Binary file not shown.

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

View File

@ -2,6 +2,5 @@
# 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/.
ANDROID_PACKAGE_NAME=org.mozilla.b2g_`echo $USER | sed 's/-/_/g'`
MOZ_APP_DISPLAYNAME=B2G
MOZ_UPDATER=

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB