2004-07-16 18:13:26 +00:00
|
|
|
# ***** BEGIN LICENSE BLOCK *****
|
|
|
|
# Version: MPL 1.1/GPL 2.0/LGPL 2.1
|
1998-11-06 08:39:52 +00:00
|
|
|
#
|
2004-07-16 18:13:26 +00:00
|
|
|
# The contents of this file are subject to the Mozilla Public License Version
|
|
|
|
# 1.1 (the "License"); you may not use this file except in compliance with
|
|
|
|
# the License. You may obtain a copy of the License at
|
|
|
|
# http://www.mozilla.org/MPL/
|
|
|
|
#
|
|
|
|
# Software distributed under the License is distributed on an "AS IS" basis,
|
|
|
|
# WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
|
|
|
|
# for the specific language governing rights and limitations under the
|
|
|
|
# License.
|
1998-11-06 08:39:52 +00:00
|
|
|
#
|
1999-11-06 03:43:54 +00:00
|
|
|
# The Original Code is mozilla.org code.
|
|
|
|
#
|
2004-07-16 18:13:26 +00:00
|
|
|
# The Initial Developer of the Original Code is
|
|
|
|
# Netscape Communications Corporation.
|
|
|
|
# Portions created by the Initial Developer are Copyright (C) 1998
|
|
|
|
# the Initial Developer. All Rights Reserved.
|
|
|
|
#
|
|
|
|
# Contributor(s):
|
|
|
|
# Stephen Lamm
|
|
|
|
#
|
|
|
|
# Alternatively, the contents of this file may be used under the terms of
|
|
|
|
# either the GNU General Public License Version 2 or later (the "GPL"), or
|
|
|
|
# the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
|
|
|
|
# in which case the provisions of the GPL or the LGPL are applicable instead
|
|
|
|
# of those above. If you wish to allow use of your version of this file only
|
|
|
|
# under the terms of either the GPL or the LGPL, and not to allow others to
|
|
|
|
# use your version of this file under the terms of the MPL, indicate your
|
|
|
|
# decision by deleting the provisions above and replace them with the notice
|
|
|
|
# and other provisions required by the GPL or the LGPL. If you do not delete
|
|
|
|
# the provisions above, a recipient may use your version of this file under
|
|
|
|
# the terms of any one of the MPL, the GPL or the LGPL.
|
1999-11-06 03:43:54 +00:00
|
|
|
#
|
2004-07-16 18:13:26 +00:00
|
|
|
# ***** END LICENSE BLOCK *****
|
1998-11-06 08:39:52 +00:00
|
|
|
|
|
|
|
# Build the Mozilla client.
|
|
|
|
#
|
1999-02-17 17:36:29 +00:00
|
|
|
# This needs CVSROOT set to work, e.g.,
|
|
|
|
# setenv CVSROOT :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot
|
|
|
|
# or
|
|
|
|
# setenv CVSROOT :pserver:username%somedomain.org@cvs.mozilla.org:/cvsroot
|
1998-11-06 09:06:37 +00:00
|
|
|
#
|
1999-04-14 02:34:49 +00:00
|
|
|
# To checkout and build a tree,
|
1999-02-19 19:49:15 +00:00
|
|
|
# 1. cvs co mozilla/client.mk
|
|
|
|
# 2. cd mozilla
|
1999-04-14 02:34:49 +00:00
|
|
|
# 3. gmake -f client.mk
|
1998-11-06 08:39:52 +00:00
|
|
|
#
|
1999-02-19 19:49:15 +00:00
|
|
|
# Other targets (gmake -f client.mk [targets...]),
|
2000-03-14 02:59:43 +00:00
|
|
|
# checkout
|
|
|
|
# build
|
|
|
|
# clean (realclean is now the same as clean)
|
|
|
|
# distclean
|
1998-11-06 09:06:37 +00:00
|
|
|
#
|
1999-02-19 19:49:15 +00:00
|
|
|
# See http://www.mozilla.org/build/unix.html for more information.
|
1998-11-06 09:06:37 +00:00
|
|
|
#
|
1999-02-17 17:36:29 +00:00
|
|
|
# Options:
|
1999-04-12 21:20:59 +00:00
|
|
|
# MOZ_OBJDIR - Destination object directory
|
1999-04-21 01:25:26 +00:00
|
|
|
# MOZ_CO_DATE - Date tag to use for checkout (default: none)
|
1999-10-07 21:24:17 +00:00
|
|
|
# MOZ_CO_MODULE - Module to checkout (default: SeaMonkeyAll)
|
1999-04-12 21:20:59 +00:00
|
|
|
# MOZ_CVS_FLAGS - Flags to pass cvs (default: -q -z3)
|
|
|
|
# MOZ_CO_FLAGS - Flags to pass after 'cvs co' (default: -P)
|
1999-08-20 15:02:00 +00:00
|
|
|
# MOZ_MAKE_FLAGS - Flags to pass to $(MAKE)
|
2001-12-23 23:23:41 +00:00
|
|
|
# MOZ_CO_BRANCH - Branch tag (Deprecated. Use MOZ_CO_TAG below.)
|
2004-09-01 20:40:10 +00:00
|
|
|
# MOZ_CO_LOCALES - localizations to pull (MOZ_CO_LOCALES="de-DE pt-BR")
|
|
|
|
# LOCALES_CVSROOT - CVSROOT to use to pull localizations
|
1999-10-09 00:31:17 +00:00
|
|
|
#
|
1999-02-17 17:36:29 +00:00
|
|
|
|
2000-03-17 00:56:58 +00:00
|
|
|
#######################################################################
|
|
|
|
# Checkout Tags
|
|
|
|
#
|
|
|
|
# For branches, uncomment the MOZ_CO_TAG line with the proper tag,
|
|
|
|
# and commit this file on that tag.
|
2002-09-11 18:34:54 +00:00
|
|
|
#MOZ_CO_TAG = <tag>
|
2001-08-17 11:17:02 +00:00
|
|
|
NSPR_CO_TAG = NSPRPUB_PRE_4_2_CLIENT_BRANCH
|
2000-12-22 20:43:27 +00:00
|
|
|
PSM_CO_TAG = #We will now build PSM from the tip instead of a branch.
|
|
|
|
NSS_CO_TAG = NSS_CLIENT_TAG
|
2002-03-27 06:31:38 +00:00
|
|
|
LDAPCSDK_CO_TAG = ldapcsdk_50_client_branch
|
2001-03-28 21:18:29 +00:00
|
|
|
ACCESSIBLE_CO_TAG =
|
2001-03-08 23:18:55 +00:00
|
|
|
IMGLIB2_CO_TAG =
|
2003-11-07 14:56:23 +00:00
|
|
|
IPC_CO_TAG =
|
2003-07-23 04:47:26 +00:00
|
|
|
TOOLKIT_CO_TAG =
|
|
|
|
BROWSER_CO_TAG =
|
|
|
|
MAIL_CO_TAG =
|
2003-09-24 13:59:37 +00:00
|
|
|
STANDALONE_COMPOSER_CO_TAG =
|
2004-09-01 20:40:10 +00:00
|
|
|
LOCALES_CO_TAG =
|
2000-05-04 01:26:34 +00:00
|
|
|
BUILD_MODULES = all
|
2000-03-17 00:56:58 +00:00
|
|
|
|
|
|
|
#######################################################################
|
|
|
|
# Defines
|
|
|
|
#
|
2001-04-17 00:11:22 +00:00
|
|
|
CVS = cvs
|
|
|
|
|
2000-03-17 00:56:58 +00:00
|
|
|
CWD := $(shell pwd)
|
2000-06-08 14:00:17 +00:00
|
|
|
|
|
|
|
ifeq "$(CWD)" "/"
|
|
|
|
CWD := /.
|
|
|
|
endif
|
|
|
|
|
2000-02-29 21:00:21 +00:00
|
|
|
ifneq (, $(wildcard client.mk))
|
2000-03-17 00:56:58 +00:00
|
|
|
# Ran from mozilla directory
|
|
|
|
ROOTDIR := $(shell dirname $(CWD))
|
|
|
|
TOPSRCDIR := $(CWD)
|
1999-02-17 17:36:29 +00:00
|
|
|
else
|
2000-03-17 00:56:58 +00:00
|
|
|
# Ran from mozilla/.. directory (?)
|
|
|
|
ROOTDIR := $(CWD)
|
|
|
|
TOPSRCDIR := $(CWD)/mozilla
|
1999-02-17 17:36:29 +00:00
|
|
|
endif
|
|
|
|
|
2001-01-27 15:36:41 +00:00
|
|
|
# on os2, TOPSRCDIR may have two forward slashes in a row, which doesn't
|
|
|
|
# work; replace first instance with one forward slash
|
2001-01-27 18:42:15 +00:00
|
|
|
TOPSRCDIR := $(shell echo "$(TOPSRCDIR)" | sed -e 's%//%/%')
|
2001-01-27 15:36:41 +00:00
|
|
|
|
2002-01-29 13:12:50 +00:00
|
|
|
ifndef TOPSRCDIR_MOZ
|
|
|
|
TOPSRCDIR_MOZ=$(TOPSRCDIR)
|
|
|
|
endif
|
|
|
|
|
2001-01-27 15:36:41 +00:00
|
|
|
# if ROOTDIR equals only drive letter (i.e. "C:"), set to "/"
|
2001-01-27 18:42:15 +00:00
|
|
|
DIRNAME := $(shell echo "$(ROOTDIR)" | sed -e 's/^.://')
|
2001-01-27 15:36:41 +00:00
|
|
|
ifeq ($(DIRNAME),)
|
|
|
|
ROOTDIR := /.
|
2000-06-08 14:00:17 +00:00
|
|
|
endif
|
|
|
|
|
2000-03-17 00:56:58 +00:00
|
|
|
AUTOCONF := autoconf
|
|
|
|
MKDIR := mkdir
|
|
|
|
SH := /bin/sh
|
1998-11-13 19:42:43 +00:00
|
|
|
ifndef MAKE
|
2000-03-17 00:56:58 +00:00
|
|
|
MAKE := gmake
|
1999-02-17 17:36:29 +00:00
|
|
|
endif
|
1999-02-19 22:55:50 +00:00
|
|
|
|
2000-03-21 21:08:35 +00:00
|
|
|
CONFIG_GUESS_SCRIPT := $(wildcard $(TOPSRCDIR)/build/autoconf/config.guess)
|
|
|
|
ifdef CONFIG_GUESS_SCRIPT
|
|
|
|
CONFIG_GUESS = $(shell $(CONFIG_GUESS_SCRIPT))
|
1999-04-15 19:35:41 +00:00
|
|
|
else
|
1999-04-14 02:34:49 +00:00
|
|
|
_IS_FIRST_CHECKOUT := 1
|
1998-11-13 19:42:43 +00:00
|
|
|
endif
|
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
####################################
|
|
|
|
# CVS
|
1998-11-13 19:42:43 +00:00
|
|
|
|
1999-04-26 21:47:47 +00:00
|
|
|
# Add the CVS root to CVS_FLAGS if needed
|
2000-03-17 00:56:58 +00:00
|
|
|
CVS_ROOT_IN_TREE := $(shell cat $(TOPSRCDIR)/CVS/Root 2>/dev/null)
|
1999-04-14 02:41:50 +00:00
|
|
|
ifneq ($(CVS_ROOT_IN_TREE),)
|
|
|
|
ifneq ($(CVS_ROOT_IN_TREE),$(CVSROOT))
|
1999-04-27 17:10:48 +00:00
|
|
|
CVS_FLAGS := -d $(CVS_ROOT_IN_TREE)
|
1999-02-19 19:49:15 +00:00
|
|
|
endif
|
1998-11-13 19:42:43 +00:00
|
|
|
endif
|
|
|
|
|
2001-04-17 00:11:22 +00:00
|
|
|
CVSCO = $(strip $(CVS) $(CVS_FLAGS) co $(CVS_CO_FLAGS))
|
1999-04-14 02:34:49 +00:00
|
|
|
CVSCO_LOGFILE := $(ROOTDIR)/cvsco.log
|
2001-01-27 15:36:41 +00:00
|
|
|
CVSCO_LOGFILE := $(shell echo $(CVSCO_LOGFILE) | sed s%//%/%)
|
1999-03-26 00:03:10 +00:00
|
|
|
|
2000-03-17 00:56:58 +00:00
|
|
|
ifdef MOZ_CO_TAG
|
2001-08-06 21:19:30 +00:00
|
|
|
CVS_CO_FLAGS := -r $(MOZ_CO_TAG)
|
2000-03-17 00:56:58 +00:00
|
|
|
endif
|
|
|
|
|
2004-09-01 20:40:10 +00:00
|
|
|
# if LOCALES_CVSROOT is not specified, set it here
|
|
|
|
# (and let mozconfig override it)
|
|
|
|
LOCALES_CVSROOT ?= :pserver:anonymous@cvs-mirror.mozilla.org:/l10n
|
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
####################################
|
1999-04-14 02:34:49 +00:00
|
|
|
# Load mozconfig Options
|
1999-02-17 17:36:29 +00:00
|
|
|
|
1999-04-14 02:34:49 +00:00
|
|
|
# See build pages, http://www.mozilla.org/build/unix.html,
|
|
|
|
# for how to set up mozconfig.
|
2000-03-14 02:59:43 +00:00
|
|
|
MOZCONFIG_LOADER := mozilla/build/autoconf/mozconfig2client-mk
|
|
|
|
MOZCONFIG_FINDER := mozilla/build/autoconf/mozconfig-find
|
2002-10-25 09:22:44 +00:00
|
|
|
MOZCONFIG_MODULES := mozilla/build/unix/modules.mk mozilla/build/unix/uniq.pl
|
1999-04-14 02:34:49 +00:00
|
|
|
run_for_side_effects := \
|
|
|
|
$(shell cd $(ROOTDIR); \
|
2000-03-14 02:59:43 +00:00
|
|
|
if test "$(_IS_FIRST_CHECKOUT)"; then \
|
2000-05-04 01:26:34 +00:00
|
|
|
$(CVSCO) $(MOZCONFIG_FINDER) $(MOZCONFIG_LOADER) $(MOZCONFIG_MODULES); \
|
2000-03-14 02:59:43 +00:00
|
|
|
else true; \
|
|
|
|
fi; \
|
2000-03-21 21:08:35 +00:00
|
|
|
$(MOZCONFIG_LOADER) $(TOPSRCDIR) mozilla/.mozconfig.mk > mozilla/.mozconfig.out)
|
|
|
|
include $(TOPSRCDIR)/.mozconfig.mk
|
2000-05-04 01:26:34 +00:00
|
|
|
include $(TOPSRCDIR)/build/unix/modules.mk
|
1999-02-17 17:36:29 +00:00
|
|
|
|
1999-04-14 02:34:49 +00:00
|
|
|
####################################
|
|
|
|
# Options that may come from mozconfig
|
1999-02-17 17:36:29 +00:00
|
|
|
|
2000-02-16 00:37:41 +00:00
|
|
|
# Change CVS flags if anonymous root is requested
|
|
|
|
ifdef MOZ_CO_USE_MIRROR
|
|
|
|
CVS_FLAGS := -d :pserver:anonymous@cvs-mirror.mozilla.org:/cvsroot
|
|
|
|
endif
|
|
|
|
|
1999-04-26 21:47:47 +00:00
|
|
|
# MOZ_CVS_FLAGS - Basic CVS flags
|
|
|
|
ifeq "$(origin MOZ_CVS_FLAGS)" "undefined"
|
2001-09-20 00:02:59 +00:00
|
|
|
CVS_FLAGS := $(CVS_FLAGS) -q -z 3
|
1999-04-26 21:47:47 +00:00
|
|
|
else
|
|
|
|
CVS_FLAGS := $(MOZ_CVS_FLAGS)
|
|
|
|
endif
|
|
|
|
|
2001-12-23 23:23:41 +00:00
|
|
|
# This option is deprecated. The best way to have client.mk pull a tag
|
2000-03-17 00:56:58 +00:00
|
|
|
# is to set MOZ_CO_TAG (see above) and commit that change on the tag.
|
|
|
|
ifdef MOZ_CO_BRANCH
|
2001-08-06 21:19:30 +00:00
|
|
|
$(warning Use MOZ_CO_TAG instead of MOZ_CO_BRANCH)
|
|
|
|
CVS_CO_FLAGS := -r $(MOZ_CO_BRANCH)
|
2000-03-17 00:56:58 +00:00
|
|
|
endif
|
|
|
|
|
1999-04-26 21:47:47 +00:00
|
|
|
# MOZ_CO_FLAGS - Anything that we should use on all checkouts
|
|
|
|
ifeq "$(origin MOZ_CO_FLAGS)" "undefined"
|
2000-03-17 00:56:58 +00:00
|
|
|
CVS_CO_FLAGS := $(CVS_CO_FLAGS) -P
|
1999-04-26 21:47:47 +00:00
|
|
|
else
|
2000-03-17 00:56:58 +00:00
|
|
|
CVS_CO_FLAGS := $(CVS_CO_FLAGS) $(MOZ_CO_FLAGS)
|
1998-11-13 19:42:43 +00:00
|
|
|
endif
|
1998-11-06 08:39:52 +00:00
|
|
|
|
1999-04-21 01:25:26 +00:00
|
|
|
ifdef MOZ_CO_DATE
|
2000-04-28 10:33:50 +00:00
|
|
|
CVS_CO_DATE_FLAGS := -D "$(MOZ_CO_DATE)"
|
1999-04-21 01:25:26 +00:00
|
|
|
endif
|
|
|
|
|
1999-04-14 02:34:49 +00:00
|
|
|
ifdef MOZ_OBJDIR
|
|
|
|
OBJDIR := $(MOZ_OBJDIR)
|
2001-11-22 04:02:28 +00:00
|
|
|
MOZ_MAKE := $(MAKE) $(MOZ_MAKE_FLAGS) -C $(OBJDIR)
|
1999-04-14 02:34:49 +00:00
|
|
|
else
|
|
|
|
OBJDIR := $(TOPSRCDIR)
|
2001-11-22 04:02:28 +00:00
|
|
|
MOZ_MAKE := $(MAKE) $(MOZ_MAKE_FLAGS)
|
1999-02-17 17:36:29 +00:00
|
|
|
endif
|
1998-12-19 00:10:52 +00:00
|
|
|
|
2000-03-21 21:08:35 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for PSM
|
|
|
|
#
|
2001-12-01 04:50:26 +00:00
|
|
|
PSM_CO_MODULE= mozilla/security/manager
|
2000-12-22 20:43:27 +00:00
|
|
|
PSM_CO_FLAGS := -P -A
|
2001-08-06 21:19:30 +00:00
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
PSM_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
2000-03-11 04:33:39 +00:00
|
|
|
ifdef PSM_CO_TAG
|
|
|
|
PSM_CO_FLAGS := $(PSM_CO_FLAGS) -r $(PSM_CO_TAG)
|
|
|
|
endif
|
2001-04-17 00:11:22 +00:00
|
|
|
CVSCO_PSM = $(CVS) $(CVS_FLAGS) co $(PSM_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(PSM_CO_MODULE)
|
2000-03-11 04:33:39 +00:00
|
|
|
|
2000-12-22 20:43:27 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for NSS
|
|
|
|
#
|
2001-04-13 09:01:36 +00:00
|
|
|
NSS_CO_MODULE = mozilla/security/nss \
|
|
|
|
mozilla/security/coreconf \
|
|
|
|
$(NULL)
|
|
|
|
|
2000-12-22 20:43:27 +00:00
|
|
|
NSS_CO_FLAGS := -P
|
2001-08-06 21:19:30 +00:00
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
NSS_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
2000-12-22 20:43:27 +00:00
|
|
|
ifdef NSS_CO_TAG
|
|
|
|
NSS_CO_FLAGS := $(NSS_CO_FLAGS) -r $(NSS_CO_TAG)
|
|
|
|
endif
|
2001-05-15 19:11:49 +00:00
|
|
|
# Cannot pull static tags by date
|
|
|
|
ifeq ($(NSS_CO_TAG),NSS_CLIENT_TAG)
|
2001-05-16 11:16:08 +00:00
|
|
|
CVSCO_NSS = $(CVS) $(CVS_FLAGS) co $(NSS_CO_FLAGS) $(NSS_CO_MODULE)
|
|
|
|
else
|
2001-04-17 00:11:22 +00:00
|
|
|
CVSCO_NSS = $(CVS) $(CVS_FLAGS) co $(NSS_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(NSS_CO_MODULE)
|
2001-05-16 11:16:08 +00:00
|
|
|
endif
|
2000-12-22 20:43:27 +00:00
|
|
|
|
2000-03-21 21:08:35 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for NSPR
|
2000-02-05 21:37:55 +00:00
|
|
|
#
|
2000-03-17 00:56:58 +00:00
|
|
|
NSPR_CO_MODULE = mozilla/nsprpub
|
2000-02-05 21:37:55 +00:00
|
|
|
NSPR_CO_FLAGS := -P
|
2001-08-06 21:19:30 +00:00
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
NSPR_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
2000-02-05 21:37:55 +00:00
|
|
|
ifdef NSPR_CO_TAG
|
|
|
|
NSPR_CO_FLAGS := $(NSPR_CO_FLAGS) -r $(NSPR_CO_TAG)
|
|
|
|
endif
|
2001-08-14 20:54:09 +00:00
|
|
|
# Cannot pull static tags by date
|
2001-08-14 21:31:49 +00:00
|
|
|
ifeq ($(NSPR_CO_TAG),NSPRPUB_CLIENT_TAG)
|
2001-08-14 20:54:09 +00:00
|
|
|
CVSCO_NSPR = $(CVS) $(CVS_FLAGS) co $(NSPR_CO_FLAGS) $(NSPR_CO_MODULE)
|
|
|
|
else
|
2001-04-17 00:11:22 +00:00
|
|
|
CVSCO_NSPR = $(CVS) $(CVS_FLAGS) co $(NSPR_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(NSPR_CO_MODULE)
|
2001-08-14 20:54:09 +00:00
|
|
|
endif
|
2000-02-05 21:37:55 +00:00
|
|
|
|
2000-06-07 03:07:45 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for the C LDAP SDK
|
|
|
|
#
|
2000-06-08 01:50:04 +00:00
|
|
|
LDAPCSDK_CO_MODULE = mozilla/directory/c-sdk
|
2000-06-07 03:07:45 +00:00
|
|
|
LDAPCSDK_CO_FLAGS := -P
|
2001-08-06 21:19:30 +00:00
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
LDAPCSDK_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
2000-06-07 03:07:45 +00:00
|
|
|
ifdef LDAPCSDK_CO_TAG
|
|
|
|
LDAPCSDK_CO_FLAGS := $(LDAPCSDK_CO_FLAGS) -r $(LDAPCSDK_CO_TAG)
|
|
|
|
endif
|
2001-04-17 00:11:22 +00:00
|
|
|
CVSCO_LDAPCSDK = $(CVS) $(CVS_FLAGS) co $(LDAPCSDK_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(LDAPCSDK_CO_MODULE)
|
2000-06-07 03:07:45 +00:00
|
|
|
|
2001-03-28 21:18:29 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for the C LDAP SDK
|
|
|
|
#
|
|
|
|
ACCESSIBLE_CO_MODULE = mozilla/accessible
|
|
|
|
ACCESSIBLE_CO_FLAGS := -P
|
2001-08-06 21:19:30 +00:00
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
ACCESSIBLE_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
2001-03-28 21:18:29 +00:00
|
|
|
ifdef ACCESSIBLE_CO_TAG
|
|
|
|
ACCESSIBLE_CO_FLAGS := $(ACCESSIBLE_CO_FLAGS) -r $(ACCESSIBLE_CO_TAG)
|
|
|
|
endif
|
2001-04-17 00:11:22 +00:00
|
|
|
CVSCO_ACCESSIBLE = $(CVS) $(CVS_FLAGS) co $(ACCESSIBLE_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(ACCESSIBLE_CO_MODULE)
|
2001-03-28 21:18:29 +00:00
|
|
|
|
2001-03-08 23:18:55 +00:00
|
|
|
|
|
|
|
####################################
|
|
|
|
# CVS defines for new image library
|
|
|
|
#
|
|
|
|
IMGLIB2_CO_MODULE = mozilla/modules/libpr0n
|
|
|
|
IMGLIB2_CO_FLAGS := -P
|
2001-08-06 21:19:30 +00:00
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
IMGLIB2_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
2001-03-08 23:18:55 +00:00
|
|
|
ifdef IMGLIB2_CO_TAG
|
|
|
|
IMGLIB2_CO_FLAGS := $(IMGLIB2_CO_FLAGS) -r $(IMGLIB2_CO_TAG)
|
|
|
|
endif
|
2001-04-17 00:11:22 +00:00
|
|
|
CVSCO_IMGLIB2 = $(CVS) $(CVS_FLAGS) co $(IMGLIB2_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(IMGLIB2_CO_MODULE)
|
2001-03-08 23:18:55 +00:00
|
|
|
|
2003-05-02 03:57:15 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for ipc module
|
|
|
|
#
|
|
|
|
IPC_CO_MODULE = mozilla/ipc/ipcd
|
2003-11-07 14:56:23 +00:00
|
|
|
IPC_CO_FLAGS := -P -A
|
2003-05-02 03:57:15 +00:00
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
IPC_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
|
|
|
ifdef IPC_CO_TAG
|
|
|
|
IPC_CO_FLAGS := $(IPC_CO_FLAGS) -r $(IPC_CO_TAG)
|
|
|
|
endif
|
|
|
|
CVSCO_IPC = $(CVS) $(CVS_FLAGS) co $(IPC_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(IPC_CO_MODULE)
|
|
|
|
|
2002-12-11 04:15:45 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for Calendar
|
|
|
|
#
|
|
|
|
CVSCO_CALENDAR := $(CVSCO) $(CVS_CO_DATE_FLAGS) mozilla/calendar mozilla/other-licenses/libical
|
|
|
|
|
2002-12-11 07:06:43 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for SeaMonkey
|
|
|
|
#
|
|
|
|
ifeq ($(MOZ_CO_MODULE),)
|
|
|
|
MOZ_CO_MODULE := SeaMonkeyAll
|
|
|
|
endif
|
|
|
|
CVSCO_SEAMONKEY := $(CVSCO) $(CVS_CO_DATE_FLAGS) $(MOZ_CO_MODULE)
|
|
|
|
|
2000-05-04 01:26:34 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for standalone modules
|
|
|
|
#
|
2002-12-11 07:06:43 +00:00
|
|
|
ifeq ($(BUILD_MODULES),all)
|
|
|
|
CHECKOUT_STANDALONE := true
|
|
|
|
CHECKOUT_STANDALONE_NOSUBDIRS := true
|
|
|
|
else
|
|
|
|
STANDALONE_CO_MODULE := $(filter-out $(NSPRPUB_DIR) security directory/c-sdk, $(BUILD_MODULE_CVS))
|
|
|
|
STANDALONE_CO_MODULE += allmakefiles.sh client.mk aclocal.m4 configure configure.in
|
|
|
|
STANDALONE_CO_MODULE += Makefile.in
|
|
|
|
STANDALONE_CO_MODULE := $(addprefix mozilla/, $(STANDALONE_CO_MODULE))
|
|
|
|
CHECKOUT_STANDALONE := cvs_co $(CVSCO) $(CVS_CO_DATE_FLAGS) $(STANDALONE_CO_MODULE)
|
2000-12-27 05:29:50 +00:00
|
|
|
|
|
|
|
NOSUBDIRS_MODULE := $(addprefix mozilla/, $(BUILD_MODULE_CVS_NS))
|
2001-01-11 11:02:10 +00:00
|
|
|
ifneq ($(NOSUBDIRS_MODULE),)
|
2002-12-11 07:06:43 +00:00
|
|
|
CHECKOUT_STANDALONE_NOSUBDIRS := cvs_co $(CVSCO) -l $(CVS_CO_DATE_FLAGS) $(NOSUBDIRS_MODULE)
|
|
|
|
else
|
|
|
|
CHECKOUT_STANDALONE_NOSUBDIRS := true
|
2001-01-11 11:02:10 +00:00
|
|
|
endif
|
2000-12-27 05:29:50 +00:00
|
|
|
|
2002-12-11 07:06:43 +00:00
|
|
|
CVSCO_SEAMONKEY :=
|
2000-12-27 05:29:50 +00:00
|
|
|
ifeq (,$(filter $(NSPRPUB_DIR), $(BUILD_MODULE_CVS)))
|
2000-05-04 01:26:34 +00:00
|
|
|
CVSCO_NSPR :=
|
|
|
|
endif
|
2001-03-04 22:55:18 +00:00
|
|
|
ifeq (,$(filter security security/manager, $(BUILD_MODULE_CVS)))
|
2000-05-04 01:26:34 +00:00
|
|
|
CVSCO_PSM :=
|
2000-12-22 20:43:27 +00:00
|
|
|
CVSCO_NSS :=
|
2000-05-04 01:26:34 +00:00
|
|
|
endif
|
2000-12-27 05:29:50 +00:00
|
|
|
ifeq (,$(filter directory/c-sdk, $(BUILD_MODULE_CVS)))
|
2000-06-09 01:31:22 +00:00
|
|
|
CVSCO_LDAPCSDK :=
|
|
|
|
endif
|
2001-03-28 21:18:29 +00:00
|
|
|
ifeq (,$(filter accessible, $(BUILD_MODULE_CVS)))
|
|
|
|
CVSCO_ACCESSIBLE :=
|
|
|
|
endif
|
2001-03-08 23:18:55 +00:00
|
|
|
ifeq (,$(filter modules/libpr0n, $(BUILD_MODULE_CVS)))
|
|
|
|
CVSCO_IMGLIB2 :=
|
|
|
|
endif
|
2003-05-09 08:19:58 +00:00
|
|
|
ifeq (,$(filter ipc, $(BUILD_MODULE_CVS)))
|
|
|
|
CVSCO_IPC :=
|
|
|
|
endif
|
2002-12-11 04:15:45 +00:00
|
|
|
ifeq (,$(filter calendar other-licenses/libical, $(BUILD_MODULE_CVS)))
|
|
|
|
CVSCO_CALENDAR :=
|
|
|
|
endif
|
2001-04-13 09:01:36 +00:00
|
|
|
endif
|
2000-05-04 01:26:34 +00:00
|
|
|
|
2001-12-12 07:59:31 +00:00
|
|
|
####################################
|
|
|
|
# CVS defined for libart (pulled and built if MOZ_INTERNAL_LIBART_LGPL is set)
|
|
|
|
#
|
|
|
|
CVSCO_LIBART := $(CVSCO) $(CVS_CO_DATE_FLAGS) mozilla/other-licenses/libart_lgpl
|
|
|
|
|
|
|
|
ifdef MOZ_INTERNAL_LIBART_LGPL
|
|
|
|
FASTUPDATE_LIBART := fast_update $(CVSCO_LIBART)
|
|
|
|
CHECKOUT_LIBART := cvs_co $(CVSCO_LIBART)
|
|
|
|
else
|
|
|
|
CHECKOUT_LIBART := true
|
|
|
|
FASTUPDATE_LIBART := true
|
|
|
|
endif
|
|
|
|
|
2002-08-07 06:37:13 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for Phoenix (pulled and built if MOZ_PHOENIX is set)
|
|
|
|
#
|
2003-07-23 04:47:26 +00:00
|
|
|
BROWSER_CO_FLAGS := -P
|
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
BROWSER_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
|
|
|
ifdef BROWSER_CO_TAG
|
|
|
|
BROWSER_CO_FLAGS := $(BROWSER_CO_FLAGS) -r $(BROWSER_CO_TAG)
|
|
|
|
endif
|
|
|
|
|
2004-05-26 22:06:19 +00:00
|
|
|
BROWSER_CO_DIRS := mozilla/browser mozilla/other-licenses/branding/firefox mozilla/other-licenses/7zstub/firefox
|
2004-03-16 03:56:25 +00:00
|
|
|
|
|
|
|
CVSCO_PHOENIX := $(CVS) $(CVS_FLAGS) co $(BROWSER_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(BROWSER_CO_DIRS)
|
2002-08-07 06:37:13 +00:00
|
|
|
|
|
|
|
ifdef MOZ_PHOENIX
|
|
|
|
FASTUPDATE_PHOENIX := fast_update $(CVSCO_PHOENIX)
|
|
|
|
CHECKOUT_PHOENIX := cvs_co $(CVSCO_PHOENIX)
|
2003-04-17 06:14:23 +00:00
|
|
|
MOZ_XUL_APP = 1
|
2004-09-01 20:40:10 +00:00
|
|
|
LOCALE_DIRS += mozilla/browser/locales
|
2002-08-07 06:37:13 +00:00
|
|
|
else
|
|
|
|
CHECKOUT_PHOENIX := true
|
|
|
|
FASTUPDATE_PHOENIX := true
|
|
|
|
endif
|
|
|
|
|
2003-04-17 06:14:23 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for Thunderbird (pulled and built if MOZ_THUNDERBIRD is set)
|
|
|
|
#
|
|
|
|
|
2003-07-23 04:47:26 +00:00
|
|
|
MAIL_CO_FLAGS := -P
|
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
MAIL_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
|
|
|
ifdef MAIL_CO_TAG
|
|
|
|
MAIL_CO_FLAGS := $(MAIL_CO_FLAGS) -r $(MAIL_CO_TAG)
|
|
|
|
endif
|
|
|
|
|
2004-05-26 22:06:19 +00:00
|
|
|
MAIL_CO_DIRS := mozilla/mail mozilla/other-licenses/branding/thunderbird mozilla/other-licenses/7zstub/thunderbird
|
2004-05-04 22:13:10 +00:00
|
|
|
|
|
|
|
CVSCO_THUNDERBIRD := $(CVS) $(CVS_FLAGS) co $(MAIL_CO_FLAGS) $(CVS_CO_DATE_FLAGS) $(MAIL_CO_DIRS)
|
2003-04-17 06:14:23 +00:00
|
|
|
ifdef MOZ_THUNDERBIRD
|
|
|
|
FASTUPDATE_THUNDERBIRD := fast_update $(CVSCO_THUNDERBIRD)
|
|
|
|
CHECKOUT_THUNDERBIRD := cvs_co $(CVSCO_THUNDERBIRD)
|
|
|
|
MOZ_XUL_APP = 1
|
2004-09-01 20:40:10 +00:00
|
|
|
LOCALE_DIRS += mozilla/mail/locales
|
2003-04-17 06:14:23 +00:00
|
|
|
else
|
|
|
|
FASTUPDATE_THUNDERBIRD := true
|
|
|
|
CHECKOUT_THUNDERBIRD := true
|
|
|
|
endif
|
|
|
|
|
2003-09-24 13:59:37 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for Standalone Composer (pulled and built if MOZ_STANDALONE_COMPOSER is set)
|
|
|
|
#
|
|
|
|
|
|
|
|
STANDALONE_COMPOSER_CO_FLAGS := -P
|
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
STANDALONE_COMPOSER_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
|
|
|
ifdef STANDALONE_COMPOSER_CO_TAG
|
|
|
|
STANDALONE_COMPOSER_CO_FLAGS := $(STANDALONE_COMPOSER_CO_FLAGS) -r $(STANDALONE_COMPOSER_CO_TAG)
|
|
|
|
endif
|
|
|
|
|
|
|
|
CVSCO_STANDALONE_COMPOSER := $(CVS) $(CVS_FLAGS) co $(STANDALONE_COMPOSER_CO_FLAGS) $(CVS_CO_DATE_FLAGS) mozilla/composer
|
|
|
|
ifdef MOZ_STANDALONE_COMPOSER
|
|
|
|
FASTUPDATE_STANDALONE_COMPOSER:= fast_update $(CVSCO_STANDALONE_COMPOSER)
|
|
|
|
CHECKOUT_STANDALONE_COMPOSER:= cvs_co $(CVSCO_STANDALONE_COMPOSER)
|
|
|
|
MOZ_XUL_APP = 1
|
2004-09-01 20:40:10 +00:00
|
|
|
LOCALE_DIRS += mozilla/composer/locales
|
2003-09-24 13:59:37 +00:00
|
|
|
else
|
|
|
|
FASTUPDATE_STANDALONE_COMPOSER:= true
|
|
|
|
CHECKOUT_STANDALONE_COMPOSER:= true
|
|
|
|
endif
|
|
|
|
|
2004-06-02 18:06:03 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for Sunbird (pulled and built if MOZ_SUNBIRD is set)
|
|
|
|
#
|
|
|
|
|
|
|
|
ifdef MOZ_SUNBIRD
|
|
|
|
MOZ_XUL_APP = 1
|
|
|
|
endif
|
|
|
|
|
2003-04-17 06:14:23 +00:00
|
|
|
####################################
|
2004-07-15 22:51:19 +00:00
|
|
|
# CVS defines for mozilla/toolkit
|
2003-04-17 06:14:23 +00:00
|
|
|
#
|
|
|
|
|
2003-07-23 04:47:26 +00:00
|
|
|
TOOLKIT_CO_FLAGS := -P
|
|
|
|
ifdef MOZ_CO_FLAGS
|
|
|
|
TOOLKIT_CO_FLAGS := $(MOZ_CO_FLAGS)
|
|
|
|
endif
|
|
|
|
ifdef TOOLKIT_CO_TAG
|
|
|
|
TOOLKIT_CO_FLAGS := $(TOOLKIT_CO_FLAGS) -r $(TOOLKIT_CO_TAG)
|
|
|
|
endif
|
|
|
|
|
2003-08-08 23:28:27 +00:00
|
|
|
CVSCO_MOZTOOLKIT := $(CVS) $(CVS_FLAGS) co $(TOOLKIT_CO_FLAGS) $(CVS_CO_DATE_FLAGS) mozilla/toolkit mozilla/chrome
|
2003-04-17 06:14:23 +00:00
|
|
|
FASTUPDATE_MOZTOOLKIT := fast_update $(CVSCO_MOZTOOLKIT)
|
|
|
|
CHECKOUT_MOZTOOLKIT := cvs_co $(CVSCO_MOZTOOLKIT)
|
2004-09-01 20:40:10 +00:00
|
|
|
LOCALE_DIRS += mozilla/toolkit/locales
|
2003-04-17 06:14:23 +00:00
|
|
|
|
2002-10-08 21:40:10 +00:00
|
|
|
####################################
|
|
|
|
# CVS defines for codesighs (pulled and built if MOZ_MAPINFO is set)
|
|
|
|
#
|
|
|
|
CVSCO_CODESIGHS := $(CVSCO) $(CVS_CO_DATE_FLAGS) mozilla/tools/codesighs
|
|
|
|
|
|
|
|
ifdef MOZ_MAPINFO
|
|
|
|
FASTUPDATE_CODESIGHS := fast_update $(CVSCO_CODESIGHS)
|
|
|
|
CHECKOUT_CODESIGHS := cvs_co $(CVSCO_CODESIGHS)
|
|
|
|
else
|
|
|
|
CHECKOUT_CODESIGHS := true
|
|
|
|
FASTUPDATE_CODESIGHS := true
|
|
|
|
endif
|
|
|
|
|
2004-09-01 20:40:10 +00:00
|
|
|
###################################
|
|
|
|
# CVS defines for locales
|
|
|
|
#
|
|
|
|
LOCALES_CO_FLAGS := -P
|
|
|
|
|
|
|
|
ifdef LOCALES_CO_TAG
|
|
|
|
LOCALES_CO_FLAGS := $(LOCALES_CO_FLAGS) -r $(LOCALES_CO_TAG)
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifndef MOZ_CO_LOCALES
|
|
|
|
FASTUPDATE_LOCALES := true
|
|
|
|
CHECKOUT_LOCALES := true
|
|
|
|
else
|
|
|
|
ifeq (all,$(MOZ_CO_LOCALES))
|
|
|
|
MOZCONFIG_MODULES += $(addsuffix /all-locales,$(LOCALE_DIRS))
|
|
|
|
|
|
|
|
FASTUPDATE_LOCALES := \
|
|
|
|
for dir in $(LOCALE_DIRS); do \
|
|
|
|
for locale in `cat $$dir/all-locales`; do \
|
|
|
|
fast_update $(CVS) $(CVS_FLAGS) -d $(LOCALES_CVSROOT) co $$dir/$$locale; \
|
|
|
|
done; \
|
|
|
|
done
|
|
|
|
|
|
|
|
CHECKOUT_LOCALES := \
|
|
|
|
for dir in $(LOCALE_DIRS); do \
|
|
|
|
for locale in `cat $$dir/all-locales`; do \
|
|
|
|
cvs_co $(CVS) $(CVS_FLAGS) -d $(LOCALES_CVSROOT) co $(LOCALES_CO_FLAGS) $$dir/$$locale; \
|
|
|
|
done; \
|
|
|
|
done
|
|
|
|
|
|
|
|
else
|
|
|
|
LOCALE_CO_DIRS = $(foreach locale,$(MOZ_CO_LOCALES),$(addsuffix /$(locale),$(LOCALE_DIRS)))
|
|
|
|
|
|
|
|
CVSCO_LOCALES := $(CVS) $(CVS_FLAGS) -d $(LOCALES_CVSROOT) co $(LOCALES_CO_FLAGS) $(LOCALE_CO_DIRS)
|
|
|
|
|
|
|
|
FASTUPDATE_LOCALES := fast_update $(CVSCO_LOCALES)
|
|
|
|
CHECKOUT_LOCALES := cvs_co $(CVSCO_LOCALES)
|
|
|
|
endif
|
|
|
|
endif #MOZ_CO_LOCALES
|
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
#######################################################################
|
1999-02-17 17:36:29 +00:00
|
|
|
# Rules
|
1998-11-13 19:42:43 +00:00
|
|
|
#
|
|
|
|
|
2000-03-21 21:08:35 +00:00
|
|
|
# Print out any options loaded from mozconfig.
|
2001-11-21 08:55:59 +00:00
|
|
|
all build checkout clean depend distclean export libs install realclean::
|
2000-03-21 21:08:35 +00:00
|
|
|
@if test -f .mozconfig.out; then \
|
|
|
|
cat .mozconfig.out; \
|
|
|
|
rm -f .mozconfig.out; \
|
|
|
|
else true; \
|
|
|
|
fi
|
|
|
|
|
1999-04-14 02:34:49 +00:00
|
|
|
ifdef _IS_FIRST_CHECKOUT
|
2000-03-21 21:08:35 +00:00
|
|
|
all:: checkout build
|
1999-03-26 00:03:10 +00:00
|
|
|
else
|
2002-01-31 06:15:19 +00:00
|
|
|
all:: checkout alldep
|
1999-03-26 00:03:10 +00:00
|
|
|
endif
|
1998-11-06 08:39:52 +00:00
|
|
|
|
1999-02-17 17:59:06 +00:00
|
|
|
# Windows equivalents
|
2000-03-17 00:56:58 +00:00
|
|
|
pull_all: checkout
|
|
|
|
build_all: build
|
2002-01-25 08:32:27 +00:00
|
|
|
build_all_dep: alldep
|
|
|
|
build_all_depend: alldep
|
2000-03-17 00:56:58 +00:00
|
|
|
clobber clobber_all: clean
|
2002-01-29 10:25:13 +00:00
|
|
|
pull_and_build_all: checkout alldep
|
1998-11-06 08:39:52 +00:00
|
|
|
|
1999-05-01 02:10:34 +00:00
|
|
|
# Do everything from scratch
|
2000-03-14 02:59:43 +00:00
|
|
|
everything: checkout clean build
|
1999-05-01 02:10:34 +00:00
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
####################################
|
1998-11-13 19:42:43 +00:00
|
|
|
# CVS checkout
|
1999-11-30 02:00:13 +00:00
|
|
|
#
|
2000-03-21 21:08:35 +00:00
|
|
|
checkout::
|
2000-06-09 01:21:45 +00:00
|
|
|
# @: Backup the last checkout log.
|
2000-02-26 03:25:57 +00:00
|
|
|
@if test -f $(CVSCO_LOGFILE) ; then \
|
|
|
|
mv $(CVSCO_LOGFILE) $(CVSCO_LOGFILE).old; \
|
|
|
|
else true; \
|
|
|
|
fi
|
2001-11-12 21:57:55 +00:00
|
|
|
ifdef RUN_AUTOCONF_LOCALLY
|
|
|
|
@echo "Removing local configures" ; \
|
|
|
|
cd $(ROOTDIR) && \
|
|
|
|
$(RM) -f mozilla/configure mozilla/nsprpub/configure \
|
2002-03-27 07:49:23 +00:00
|
|
|
mozilla/directory/c-sdk/configure
|
2001-11-12 21:57:55 +00:00
|
|
|
endif
|
2000-02-22 22:25:56 +00:00
|
|
|
@echo "checkout start: "`date` | tee $(CVSCO_LOGFILE)
|
2002-10-25 09:22:44 +00:00
|
|
|
@echo '$(CVSCO) $(CVS_CO_DATE_FLAGS) mozilla/client.mk $(MOZCONFIG_MODULES)'; \
|
2001-11-13 08:38:56 +00:00
|
|
|
cd $(ROOTDIR) && \
|
2002-10-25 09:22:44 +00:00
|
|
|
$(CVSCO) $(CVS_CO_DATE_FLAGS) mozilla/client.mk $(MOZCONFIG_MODULES)
|
2001-11-13 08:38:56 +00:00
|
|
|
@cd $(ROOTDIR) && $(MAKE) -f mozilla/client.mk real_checkout
|
2000-02-22 22:25:56 +00:00
|
|
|
|
2004-09-01 20:40:10 +00:00
|
|
|
# Start the checkout. Split the output to the tty and a log file.
|
|
|
|
|
2000-02-22 22:25:56 +00:00
|
|
|
real_checkout:
|
2004-09-01 20:40:10 +00:00
|
|
|
@set -e; \
|
|
|
|
cvs_co() { set -e; echo "$$@" ; \
|
|
|
|
"$$@" 2>&1 | tee -a $(CVSCO_LOGFILE); }; \
|
|
|
|
$(CHECKOUT_STANDALONE); \
|
|
|
|
$(CHECKOUT_STANDALONE_NOSUBDIRS); \
|
|
|
|
cvs_co $(CVSCO_NSPR); \
|
|
|
|
cvs_co $(CVSCO_NSS); \
|
|
|
|
cvs_co $(CVSCO_PSM); \
|
|
|
|
cvs_co $(CVSCO_LDAPCSDK); \
|
|
|
|
cvs_co $(CVSCO_ACCESSIBLE); \
|
|
|
|
cvs_co $(CVSCO_IMGLIB2); \
|
|
|
|
cvs_co $(CVSCO_IPC); \
|
|
|
|
cvs_co $(CVSCO_CALENDAR); \
|
|
|
|
$(CHECKOUT_LIBART); \
|
|
|
|
$(CHECKOUT_MOZTOOLKIT); \
|
|
|
|
$(CHECKOUT_PHOENIX); \
|
|
|
|
$(CHECKOUT_THUNDERBIRD); \
|
|
|
|
$(CHECKOUT_STANDALONE_COMPOSER); \
|
|
|
|
$(CHECKOUT_CODESIGHS); \
|
|
|
|
$(CHECKOUT_LOCALES); \
|
|
|
|
cvs_co $(CVSCO_SEAMONKEY);
|
2000-02-22 22:25:56 +00:00
|
|
|
@echo "checkout finish: "`date` | tee -a $(CVSCO_LOGFILE)
|
2003-05-21 20:13:24 +00:00
|
|
|
# update the NSS checkout timestamp
|
|
|
|
@if test `egrep -c '^(U|C) mozilla/security/(nss|coreconf)' $(CVSCO_LOGFILE) 2>/dev/null` != 0; then \
|
|
|
|
touch $(TOPSRCDIR)/security/manager/.nss.checkout; \
|
|
|
|
fi
|
2000-06-22 21:56:41 +00:00
|
|
|
# @: Check the log for conflicts. ;
|
|
|
|
@conflicts=`egrep "^C " $(CVSCO_LOGFILE)` ;\
|
1999-11-30 02:00:13 +00:00
|
|
|
if test "$$conflicts" ; then \
|
|
|
|
echo "$(MAKE): *** Conflicts during checkout." ;\
|
|
|
|
echo "$$conflicts" ;\
|
|
|
|
echo "$(MAKE): Refer to $(CVSCO_LOGFILE) for full log." ;\
|
2000-02-22 22:25:56 +00:00
|
|
|
false; \
|
|
|
|
else true; \
|
|
|
|
fi
|
2001-11-12 21:57:55 +00:00
|
|
|
ifdef RUN_AUTOCONF_LOCALLY
|
|
|
|
@echo Generating configures using $(AUTOCONF) ; \
|
|
|
|
cd $(TOPSRCDIR) && $(AUTOCONF) && \
|
|
|
|
cd $(TOPSRCDIR)/nsprpub && $(AUTOCONF) && \
|
2002-03-27 07:49:23 +00:00
|
|
|
cd $(TOPSRCDIR)/directory/c-sdk && $(AUTOCONF)
|
2001-11-12 21:57:55 +00:00
|
|
|
endif
|
1999-02-17 17:36:29 +00:00
|
|
|
|
2001-08-15 04:20:31 +00:00
|
|
|
fast-update:
|
2001-08-15 23:55:25 +00:00
|
|
|
# @: Backup the last checkout log.
|
|
|
|
@if test -f $(CVSCO_LOGFILE) ; then \
|
|
|
|
mv $(CVSCO_LOGFILE) $(CVSCO_LOGFILE).old; \
|
|
|
|
else true; \
|
|
|
|
fi
|
2001-11-12 21:57:55 +00:00
|
|
|
ifdef RUN_AUTOCONF_LOCALLY
|
|
|
|
@echo "Removing local configures" ; \
|
|
|
|
cd $(ROOTDIR) && \
|
|
|
|
$(RM) -f mozilla/configure mozilla/nsprpub/configure \
|
2002-03-27 07:49:23 +00:00
|
|
|
mozilla/directory/c-sdk/configure
|
2001-11-12 21:57:55 +00:00
|
|
|
endif
|
2001-08-15 23:55:25 +00:00
|
|
|
@echo "checkout start: "`date` | tee $(CVSCO_LOGFILE)
|
2002-10-25 09:22:44 +00:00
|
|
|
@echo '$(CVSCO) mozilla/client.mk $(MOZCONFIG_MODULES)'; \
|
2001-11-13 08:38:56 +00:00
|
|
|
cd $(ROOTDIR) && \
|
2002-10-25 09:22:44 +00:00
|
|
|
$(CVSCO) mozilla/client.mk $(MOZCONFIG_MODULES)
|
2001-11-13 08:38:56 +00:00
|
|
|
@cd $(TOPSRCDIR) && \
|
2001-08-15 23:55:25 +00:00
|
|
|
$(MAKE) -f client.mk real_fast-update
|
|
|
|
|
2004-09-01 20:40:10 +00:00
|
|
|
# Start the update. Split the output to the tty and a log file.
|
2001-08-15 23:55:25 +00:00
|
|
|
real_fast-update:
|
2004-09-01 20:40:10 +00:00
|
|
|
@set -e;
|
|
|
|
fast_update() { set -e; config/cvsco-fast-update.pl $$@ 2>&1 | tee -a $(CVSCO_LOGFILE); }; \
|
|
|
|
cvs_co() { set -e; echo "$$@" ; \
|
|
|
|
"$$@" 2>&1 | tee -a $(CVSCO_LOGFILE); }; \
|
|
|
|
fast_update $(CVSCO_NSPR); \
|
|
|
|
cd $(ROOTDIR); \
|
|
|
|
cvs_co $(CVSCO_NSS); \
|
|
|
|
cd mozilla; \
|
|
|
|
fast_update $(CVSCO_PSM); \
|
|
|
|
fast_update $(CVSCO_LDAPCSDK); \
|
|
|
|
fast_update $(CVSCO_ACCESSIBLE); \
|
|
|
|
fast_update $(CVSCO_IMGLIB2); \
|
|
|
|
fast_update $(CVSCO_IPC); \
|
|
|
|
fast_update $(CVSCO_CALENDAR); \
|
|
|
|
$(FASTUPDATE_LIBART); \
|
|
|
|
$(FASTUPDATE_MOZTOOLKIT); \
|
|
|
|
$(FASTUPDATE_PHOENIX); \
|
|
|
|
$(FASTUPDATE_THUNDERBIRD); \
|
|
|
|
$(FASTUPDATE_STANDALONE_COMPOSER); \
|
|
|
|
$(FASTUPDATE_CODESIGHS); \
|
|
|
|
$(FASTUPDATE_LOCALES); \
|
|
|
|
fast_update $(CVSCO_SEAMONKEY);
|
2001-08-15 04:20:31 +00:00
|
|
|
@echo "fast_update finish: "`date` | tee -a $(CVSCO_LOGFILE)
|
2003-05-21 20:13:24 +00:00
|
|
|
# update the NSS checkout timestamp
|
|
|
|
@if test `egrep -c '^(U|C) mozilla/security/(nss|coreconf)' $(CVSCO_LOGFILE) 2>/dev/null` != 0; then \
|
2003-05-22 21:56:54 +00:00
|
|
|
touch $(TOPSRCDIR)/security/manager/.nss.checkout; \
|
2003-05-21 20:13:24 +00:00
|
|
|
fi
|
2001-08-15 04:20:31 +00:00
|
|
|
# @: Check the log for conflicts. ;
|
|
|
|
@conflicts=`egrep "^C " $(CVSCO_LOGFILE)` ;\
|
|
|
|
if test "$$conflicts" ; then \
|
|
|
|
echo "$(MAKE): *** Conflicts during fast-update." ;\
|
|
|
|
echo "$$conflicts" ;\
|
|
|
|
echo "$(MAKE): Refer to $(CVSCO_LOGFILE) for full log." ;\
|
|
|
|
false; \
|
|
|
|
else true; \
|
|
|
|
fi
|
2001-11-12 21:57:55 +00:00
|
|
|
ifdef RUN_AUTOCONF_LOCALLY
|
|
|
|
@echo Generating configures using $(AUTOCONF) ; \
|
|
|
|
cd $(TOPSRCDIR) && $(AUTOCONF) && \
|
|
|
|
cd $(TOPSRCDIR)/nsprpub && $(AUTOCONF) && \
|
2002-03-27 07:49:23 +00:00
|
|
|
cd $(TOPSRCDIR)/directory/c-sdk && $(AUTOCONF)
|
2001-11-12 21:57:55 +00:00
|
|
|
endif
|
2001-08-15 04:20:31 +00:00
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
####################################
|
1999-02-19 22:55:50 +00:00
|
|
|
# Web configure
|
1999-03-26 00:03:10 +00:00
|
|
|
|
1999-04-14 02:34:49 +00:00
|
|
|
WEBCONFIG_FILE := $(HOME)/.mozconfig
|
|
|
|
|
2000-05-08 20:51:48 +00:00
|
|
|
MOZCONFIG2CONFIGURATOR := build/autoconf/mozconfig2configurator
|
1999-02-19 22:55:50 +00:00
|
|
|
webconfig:
|
2000-05-08 20:51:48 +00:00
|
|
|
@cd $(TOPSRCDIR); \
|
|
|
|
url=`$(MOZCONFIG2CONFIGURATOR) $(TOPSRCDIR)`; \
|
2001-10-13 06:23:28 +00:00
|
|
|
echo Running mozilla with the following url: ;\
|
1999-03-10 21:03:33 +00:00
|
|
|
echo ;\
|
|
|
|
echo $$url ;\
|
2001-10-13 06:23:28 +00:00
|
|
|
mozilla -remote "openURL($$url)" || \
|
|
|
|
netscape -remote "openURL($$url)" || \
|
|
|
|
mozilla $$url || \
|
|
|
|
netscape $$url ;\
|
1999-03-10 21:03:33 +00:00
|
|
|
echo ;\
|
1999-03-26 00:03:10 +00:00
|
|
|
echo 1. Fill out the form on the browser. ;\
|
2000-05-08 20:51:48 +00:00
|
|
|
echo 2. Save the results to $(WEBCONFIG_FILE)
|
1999-02-19 22:55:50 +00:00
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
#####################################################
|
|
|
|
# First Checkout
|
|
|
|
|
1999-04-14 02:34:49 +00:00
|
|
|
ifdef _IS_FIRST_CHECKOUT
|
1999-02-19 19:49:15 +00:00
|
|
|
# First time, do build target in a new process to pick up new files.
|
2000-03-21 21:08:35 +00:00
|
|
|
build::
|
2001-05-07 23:50:39 +00:00
|
|
|
$(MAKE) -f $(TOPSRCDIR)/client.mk build
|
1999-02-17 17:36:29 +00:00
|
|
|
else
|
1998-11-06 08:39:52 +00:00
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
#####################################################
|
|
|
|
# After First Checkout
|
|
|
|
|
|
|
|
|
|
|
|
####################################
|
1999-02-17 17:36:29 +00:00
|
|
|
# Configure
|
|
|
|
|
|
|
|
CONFIG_STATUS := $(wildcard $(OBJDIR)/config.status)
|
|
|
|
CONFIG_CACHE := $(wildcard $(OBJDIR)/config.cache)
|
|
|
|
|
|
|
|
ifdef RUN_AUTOCONF_LOCALLY
|
1999-02-19 19:49:15 +00:00
|
|
|
EXTRA_CONFIG_DEPS := \
|
1999-02-17 17:36:29 +00:00
|
|
|
$(TOPSRCDIR)/aclocal.m4 \
|
2001-11-12 21:57:55 +00:00
|
|
|
$(wildcard $(TOPSRCDIR)/build/autoconf/*.m4) \
|
1999-02-17 17:36:29 +00:00
|
|
|
$(NULL)
|
|
|
|
|
1999-02-19 19:49:15 +00:00
|
|
|
$(TOPSRCDIR)/configure: $(TOPSRCDIR)/configure.in $(EXTRA_CONFIG_DEPS)
|
1998-11-13 19:42:43 +00:00
|
|
|
@echo Generating $@ using autoconf
|
1999-02-17 17:36:29 +00:00
|
|
|
cd $(TOPSRCDIR); $(AUTOCONF)
|
|
|
|
endif
|
1998-11-13 19:42:43 +00:00
|
|
|
|
2000-06-27 00:24:48 +00:00
|
|
|
CONFIG_STATUS_DEPS_L10N := $(wildcard $(TOPSRCDIR)/l10n/makefiles.all)
|
|
|
|
|
1999-04-27 20:57:13 +00:00
|
|
|
CONFIG_STATUS_DEPS := \
|
|
|
|
$(TOPSRCDIR)/configure \
|
|
|
|
$(TOPSRCDIR)/allmakefiles.sh \
|
2000-03-21 21:08:35 +00:00
|
|
|
$(TOPSRCDIR)/.mozconfig.mk \
|
2000-06-14 03:51:17 +00:00
|
|
|
$(wildcard $(TOPSRCDIR)/nsprpub/configure) \
|
2002-03-27 07:49:23 +00:00
|
|
|
$(wildcard $(TOPSRCDIR)/directory/c-sdk/configure) \
|
1999-04-27 20:57:13 +00:00
|
|
|
$(wildcard $(TOPSRCDIR)/mailnews/makefiles) \
|
2000-06-27 00:24:48 +00:00
|
|
|
$(CONFIG_STATUS_DEPS_L10N) \
|
2000-06-14 03:51:17 +00:00
|
|
|
$(wildcard $(TOPSRCDIR)/themes/makefiles) \
|
2003-12-02 23:22:11 +00:00
|
|
|
$(wildcard $(TOPSRCDIR)/config/milestone.txt) \
|
|
|
|
$(wildcard $(TOPSRCDIR)/config/chrome-versions.sh) \
|
1999-04-27 20:57:13 +00:00
|
|
|
$(NULL)
|
|
|
|
|
2000-03-14 02:59:43 +00:00
|
|
|
# configure uses the program name to determine @srcdir@. Calling it without
|
|
|
|
# $(TOPSRCDIR) will set @srcdir@ to "."; otherwise, it is set to the full
|
|
|
|
# path of $(TOPSRCDIR).
|
|
|
|
ifeq ($(TOPSRCDIR),$(OBJDIR))
|
2000-03-14 04:31:49 +00:00
|
|
|
CONFIGURE := ./configure
|
2000-03-14 02:59:43 +00:00
|
|
|
else
|
|
|
|
CONFIGURE := $(TOPSRCDIR)/configure
|
|
|
|
endif
|
|
|
|
|
2002-06-17 17:09:57 +00:00
|
|
|
ifdef MOZ_TOOLS
|
|
|
|
CONFIGURE := $(TOPSRCDIR)/configure
|
2002-04-06 06:20:55 +00:00
|
|
|
endif
|
|
|
|
|
1999-04-27 20:57:13 +00:00
|
|
|
$(OBJDIR)/Makefile $(OBJDIR)/config.status: $(CONFIG_STATUS_DEPS)
|
1999-03-12 02:55:24 +00:00
|
|
|
@if test ! -d $(OBJDIR); then $(MKDIR) $(OBJDIR); else true; fi
|
2000-03-14 02:59:43 +00:00
|
|
|
@echo cd $(OBJDIR);
|
2002-04-06 06:20:55 +00:00
|
|
|
@echo $(CONFIGURE) $(CONFIGURE_ARGS)
|
|
|
|
@cd $(OBJDIR) && $(CONFIGURE_ENV_ARGS) $(CONFIGURE) $(CONFIGURE_ARGS) \
|
1999-04-16 23:47:04 +00:00
|
|
|
|| ( echo "*** Fix above errors and then restart with\
|
|
|
|
\"$(MAKE) -f client.mk build\"" && exit 1 )
|
1999-08-20 15:02:00 +00:00
|
|
|
@touch $(OBJDIR)/Makefile
|
1999-02-17 17:36:29 +00:00
|
|
|
|
|
|
|
ifdef CONFIG_STATUS
|
|
|
|
$(OBJDIR)/config/autoconf.mk: $(TOPSRCDIR)/config/autoconf.mk.in
|
|
|
|
cd $(OBJDIR); \
|
|
|
|
CONFIG_FILES=config/autoconf.mk ./config.status
|
|
|
|
endif
|
1998-11-13 19:42:43 +00:00
|
|
|
|
1998-11-10 01:56:13 +00:00
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
####################################
|
|
|
|
# Depend
|
|
|
|
|
2000-03-21 21:08:35 +00:00
|
|
|
depend:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
|
2001-09-28 00:36:07 +00:00
|
|
|
$(MOZ_MAKE) export && $(MOZ_MAKE) depend
|
1999-03-26 00:03:10 +00:00
|
|
|
|
|
|
|
####################################
|
|
|
|
# Build it
|
|
|
|
|
2000-03-21 21:08:35 +00:00
|
|
|
build:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
|
2001-11-17 03:56:53 +00:00
|
|
|
$(MOZ_MAKE)
|
1999-03-26 00:03:10 +00:00
|
|
|
|
2004-03-21 02:31:17 +00:00
|
|
|
####################################
|
|
|
|
# Profile-feedback build (gcc only)
|
|
|
|
# To use this, you should set the following variables in your mozconfig
|
|
|
|
# mk_add_options PROFILE_GEN_SCRIPT=/path/to/profile-script
|
|
|
|
#
|
|
|
|
# The profile script should exercise the functionality to be included
|
|
|
|
# in the profile feedback.
|
|
|
|
|
|
|
|
profiledbuild:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
|
|
|
|
$(MOZ_MAKE) MOZ_PROFILE_GENERATE=1
|
|
|
|
OBJDIR=${OBJDIR} $(PROFILE_GEN_SCRIPT)
|
|
|
|
$(MOZ_MAKE) clobber_all
|
|
|
|
$(MOZ_MAKE) MOZ_PROFILE_USE=1
|
2004-03-21 19:20:59 +00:00
|
|
|
find $(OBJDIR) -name "*.da" -exec rm {} \;
|
2004-03-21 02:31:17 +00:00
|
|
|
|
1999-03-26 00:03:10 +00:00
|
|
|
####################################
|
|
|
|
# Other targets
|
|
|
|
|
1999-02-17 17:59:06 +00:00
|
|
|
# Pass these target onto the real build system
|
2002-01-25 08:32:27 +00:00
|
|
|
install export libs clean realclean distclean alldep:: $(OBJDIR)/Makefile $(OBJDIR)/config.status
|
2000-03-17 00:56:58 +00:00
|
|
|
$(MOZ_MAKE) $@
|
1999-02-17 17:59:06 +00:00
|
|
|
|
1999-04-23 20:46:22 +00:00
|
|
|
cleansrcdir:
|
|
|
|
@cd $(TOPSRCDIR); \
|
1999-09-22 00:40:11 +00:00
|
|
|
if [ -f webshell/embed/gtk/Makefile ]; then \
|
|
|
|
$(MAKE) -C webshell/embed/gtk distclean; \
|
1999-09-22 06:32:45 +00:00
|
|
|
fi; \
|
2000-12-06 07:14:00 +00:00
|
|
|
if [ -f Makefile ]; then \
|
|
|
|
$(MAKE) distclean ; \
|
|
|
|
else \
|
1999-04-23 20:46:22 +00:00
|
|
|
echo "Removing object files from srcdir..."; \
|
|
|
|
rm -fr `find . -type d \( -name .deps -print -o -name CVS \
|
|
|
|
-o -exec test ! -d {}/CVS \; \) -prune \
|
|
|
|
-o \( -name '*.[ao]' -o -name '*.so' \) -type f -print`; \
|
2000-12-06 07:14:00 +00:00
|
|
|
build/autoconf/clean-config.sh; \
|
|
|
|
fi;
|
1999-04-23 20:46:22 +00:00
|
|
|
|
1999-02-17 17:36:29 +00:00
|
|
|
# (! IS_FIRST_CHECKOUT)
|
|
|
|
endif
|
1999-04-14 02:34:49 +00:00
|
|
|
|
2003-06-02 19:00:57 +00:00
|
|
|
echo_objdir:
|
|
|
|
@echo $(OBJDIR)
|
|
|
|
|
2002-01-25 08:32:27 +00:00
|
|
|
.PHONY: checkout real_checkout depend build export libs alldep install clean realclean distclean cleansrcdir pull_all build_all clobber clobber_all pull_and_build_all everything
|