diff --git a/calendar/sunbird/app/.cvsignore b/calendar/sunbird/app/.cvsignore index f3c7a7c5da6..dc004d8e1a1 100644 --- a/calendar/sunbird/app/.cvsignore +++ b/calendar/sunbird/app/.cvsignore @@ -1 +1,2 @@ Makefile +nsStaticComponents.cpp diff --git a/calendar/sunbird/app/Makefile.in b/calendar/sunbird/app/Makefile.in index d381de5897b..1ffa916431d 100644 --- a/calendar/sunbird/app/Makefile.in +++ b/calendar/sunbird/app/Makefile.in @@ -122,9 +122,9 @@ ifeq ($(OS_ARCH),WINNT) OS_LIBS += $(call EXPAND_LIBNAME,comctl32 comdlg32 uuid shell32 ole32 oleaut32 version winspool gdi32) RCINCLUDE = splash.rc ifndef GNU_CC -RCFLAGS += -DMOZ_PHOENIX -I$(srcdir) +RCFLAGS += -DMOZ_SUNBIRD -I$(srcdir) else -RCFLAGS += -DMOZ_PHOENIX --include-dir $(srcdir) +RCFLAGS += -DMOZ_SUNBIRD --include-dir $(srcdir) endif ifdef BUILD_STATIC_LIBS RCFLAGS += -DMOZ_STATIC_BUILD @@ -134,16 +134,28 @@ RCFLAGS += -DDEBUG endif endif +ifeq ($(OS_ARCH),BeOS) +OS_LIBS += -ltracker +endif + ifeq ($(OS_ARCH),OS2) RESFILE=splashos2.res +RCFLAGS += -DMOZ_SUNBIRD ifdef BUILD_STATIC_LIBS +OS_LIBS += -lpmwinx EXE_DEF_FILE = browser.def -RCFLAGS += -d MOZ_STATIC_BUILD -i $(DIST)/include/widget +RCFLAGS += -DMOZ_STATIC_BUILD -i $(DIST)/include/widget endif +ifdef DEBUG +RCFLAGS += -DDEBUG +endif +RCFLAGS += -DSUNBIRD_ICO=\"$(DIST)/branding/sunbird.ico\" endif include $(topsrcdir)/config/rules.mk +DEFINES += -DSUNBIRD_ICO=\"$(DIST)/branding/sunbird.ico\" + ifdef BUILD_STATIC_LIBS include $(topsrcdir)/config/static-rules.mk endif @@ -198,6 +210,7 @@ endif endif ifneq (,$(filter-out OS2 WINNT,$(OS_ARCH))) + MozillaSunbird:: mozilla.in Makefile.in Makefile $(DEPTH)/config/autoconf.mk cat $< | sed -e "s|%MOZAPPDIR%|$(mozappdir)|" \ -e "s|%MOZ_USER_DIR%|.sunbird|" \ @@ -217,16 +230,37 @@ GARBAGE += $(addprefix $(DIST)/bin/defaults/pref/, sunbird.js) endif ifeq ($(MOZ_WIDGET_TOOLKIT),gtk2) -libs:: default.xpm - $(INSTALL) $^ $(DIST)/bin/chrome/icons/default +libs:: + $(INSTALL) $(DIST)/branding/default.xpm $(DIST)/bin/chrome/icons/default -install:: default.xpm - $(SYSINSTALL) $(IFLAGS1) $^ $(DESTDIR)$(mozappdir)/icons +install:: + $(SYSINSTALL) $(IFLAGS1) $(DIST)/branding/default.xpm $(DESTDIR)$(mozappdir)/icons endif export:: brand.dtd.in $(PERL) $(topsrcdir)/config/preprocessor.pl $(DEFINES) $(ACDEFINES) $^ > brand.dtd +export:: +ifndef MOZ_USE_OFFICIAL_BRANDING + $(NSINSTALL) -D $(DIST)/branding +ifeq ($(OS_ARCH),WINNT) + cp $(srcdir)/sunbird.ico $(DIST)/branding/sunbird.ico + cp $(srcdir)/sunbird.ico $(DIST)/branding/app.ico + cp $(srcdir)/sunbird.ico $(DIST)/branding/document.ico +endif +ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT))) + cp $(srcdir)/macbuild/sunbird.icns $(DIST)/branding/sunbird.icns +endif +ifeq ($(MOZ_WIDGET_TOOLKIT),gtk2) + cp $(srcdir)/default.xpm $(DIST)/branding/default.xpm +endif +ifeq ($(OS_ARCH),OS2) + cp $(srcdir)/sunbird.ico $(DIST)/branding/sunbird.ico + cp $(srcdir)/sunbird.ico $(DIST)/branding/app.ico + cp $(srcdir)/sunbird.ico $(DIST)/branding/document.ico +endif +endif + libs:: touch $(DIST)/bin/.autoreg @@ -239,9 +273,10 @@ libs:: $(PROGRAM) rsync -a --exclude CVS --exclude "*.in" $(srcdir)/macbuild/Contents $(DIST)/$(APP_NAME).app sed -e "s/APP_VERSION/$(APP_VERSION)/" $(srcdir)/macbuild/Contents/Info.plist.in > $(DIST)/$(APP_NAME).app/Contents/Info.plist rsync -a $(DIST)/bin/ $(DIST)/$(APP_NAME).app/Contents/MacOS - rm -f $(DIST)/$(APP_NAME).app/Contents/MacOS/$(PROGRAM) + rm -f $(DIST)/$(APP_NAME).app/Contents/MacOS/$(PROGRAM) $(DIST)/$(APP_NAME).app/Contents/MacOS/mangle $(DIST)/$(APP_NAME).app/Contents/MacOS/shlibsign rsync -aL $(PROGRAM) $(DIST)/$(APP_NAME).app/Contents/MacOS - cp -RL $(srcdir)/macbuild/sunbird.icns $(DIST)/$(APP_NAME).app/Contents/Resources/mach.icns + -cp -L $(DIST)/bin/mangle $(DIST)/bin/shlibsign $(DIST)/$(APP_NAME).app/Contents/MacOS + cp -RL $(DIST)/branding/sunbird.icns $(DIST)/$(APP_NAME).app/Contents/Resources/sunbird.icns echo -n APPLMOZB > $(DIST)/$(APP_NAME).app/Contents/PkgInfo # remove CVS dirs from packaged app find $(DIST)/$(APP_NAME).app -type d -name "CVS" -prune -exec rm -rf {} \; diff --git a/calendar/sunbird/app/brand.dtd.in b/calendar/sunbird/app/brand.dtd.in index 36b1b6f7c4f..b9124fffcb6 100644 --- a/calendar/sunbird/app/brand.dtd.in +++ b/calendar/sunbird/app/brand.dtd.in @@ -1,9 +1,7 @@ - +#expand diff --git a/calendar/sunbird/app/module.ver b/calendar/sunbird/app/module.ver index e7b7e9e922f..9e2f3e84708 100644 --- a/calendar/sunbird/app/module.ver +++ b/calendar/sunbird/app/module.ver @@ -1,7 +1,7 @@ WIN32_MODULE_COMPANYNAME=Mozilla WIN32_MODULE_COPYRIGHT=ŠSunbird and Mozilla Developers, according to the MPL 1.1/GPL 2.0/LGPL 2.1 licenses, as applicable. -WIN32_MODULE_FILEVERSION=0,1,0,0 -WIN32_MODULE_FILEVERSION_STRING=0.1+ +WIN32_MODULE_FILEVERSION=0,2,0,0 +WIN32_MODULE_FILEVERSION_STRING=0.2+ WIN32_MODULE_TRADEMARKS=Blah WIN32_MODULE_DESCRIPTION=Mozilla Sunbird WIN32_MODULE_PRODUCTNAME=Mozilla Sunbird diff --git a/calendar/sunbird/app/mozilla.in b/calendar/sunbird/app/mozilla.in index b70d26c5558..78b8bc08016 100755 --- a/calendar/sunbird/app/mozilla.in +++ b/calendar/sunbird/app/mozilla.in @@ -16,7 +16,7 @@ # Reserved. # -## $Id: mozilla.in,v 1.4 2004-04-07 18:55:07 mostafah%oeone.com Exp $ +## $Id: mozilla.in,v 1.5 2004-06-10 14:10:26 mostafah%oeone.com Exp $ ## ## Usage: ## @@ -119,6 +119,28 @@ moreargs="" debugging=0 MOZILLA_BIN="%MOZILLA-BIN%" +# The following is to check for a currently running instance. +# This is taken almost verbatim from the Mozilla RPM package's launch script. +MOZ_CLIENT_PROGRAM=$dist_bin/mozilla-xremote-client +check_running() { + $MOZ_CLIENT_PROGRAM -a sunbird 'ping()' 2>/dev/null >/dev/null + RETURN_VAL=$? + if [ $RETURN_VAL -eq 0 ]; then + echo 1 + return 1 + else + echo 0 + return 0 + fi +} + +ALREADY_RUNNING=`check_running` + +if [ $ALREADY_RUNNING -eq 1 ] && [ -z "$1" ]; then + exec $MOZ_CLIENT_PROGRAM -a firefox "xfeDoCommand(openBrowser)" 2>/dev/null >/dev/null +fi +# End of section that checks for currently running instance. - jtg + if [ "$OSTYPE" = "beos" ]; then mimeset -F $MOZILLA_BIN fi diff --git a/calendar/sunbird/app/splashos2.rc b/calendar/sunbird/app/splashos2.rc index e9f19deed73..98cc980b107 100644 --- a/calendar/sunbird/app/splashos2.rc +++ b/calendar/sunbird/app/splashos2.rc @@ -33,7 +33,7 @@ #define ID_DDE_APPLICATION_NAME 102 -ICON 1 "mozos2.ico" +ICON 1 SUNBIRD_ICO DLGTEMPLATE IDD_SPLASH DISCARDABLE BEGIN @@ -46,7 +46,11 @@ END STRINGTABLE DISCARDABLE BEGIN +#ifdef DEBUG + ID_DDE_APPLICATION_NAME, "Mozilla Sunbird Debug" +#else ID_DDE_APPLICATION_NAME, "Mozilla Sunbird" +#endif END #ifdef MOZ_STATIC_BUILD