1999-12-15 12:40:24 +03:00
|
|
|
#
|
1999-11-06 06:43:54 +03:00
|
|
|
# The contents of this file are subject to the Netscape 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/NPL/
|
1998-08-21 07:34:44 +04:00
|
|
|
#
|
1999-11-06 06:43:54 +03:00
|
|
|
# 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-08-21 07:34:44 +04:00
|
|
|
#
|
1999-11-06 06:43:54 +03:00
|
|
|
# The Original Code is mozilla.org code.
|
|
|
|
#
|
|
|
|
# The Initial Developer of the Original Code is Netscape
|
1998-08-21 07:34:44 +04:00
|
|
|
# Communications Corporation. Portions created by Netscape are
|
1999-11-06 06:43:54 +03:00
|
|
|
# Copyright (C) 1998 Netscape Communications Corporation. All
|
|
|
|
# Rights Reserved.
|
|
|
|
#
|
|
|
|
# Contributor(s):
|
1998-08-21 07:34:44 +04:00
|
|
|
#
|
|
|
|
|
|
|
|
DEPTH = .
|
|
|
|
topsrcdir = @top_srcdir@
|
|
|
|
srcdir = @srcdir@
|
|
|
|
VPATH = @srcdir@
|
|
|
|
|
|
|
|
include $(DEPTH)/config/autoconf.mk
|
|
|
|
|
2000-04-18 13:42:12 +04:00
|
|
|
include $(topsrcdir)/build/unix/modules.mk
|
|
|
|
|
|
|
|
ifneq ($(BUILD_MODULES),all)
|
|
|
|
|
|
|
|
DIRS = $(BUILD_MODULE_DIRS)
|
2000-12-11 09:52:25 +03:00
|
|
|
EXPORT_DIRS = $(BUILD_MODULE_DEP_DIRS)
|
2000-06-28 08:32:15 +04:00
|
|
|
|
2000-04-18 13:42:12 +04:00
|
|
|
else
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
#
|
|
|
|
# And now for something completely different...
|
|
|
|
# Divide the default build into tiers.
|
|
|
|
# Tiers must be defined on module boundaries
|
|
|
|
#
|
2001-11-21 10:10:52 +03:00
|
|
|
default: $(SUBMAKEFILES)
|
2001-12-10 09:13:54 +03:00
|
|
|
$(MAKE) tier_0
|
2002-01-26 01:29:51 +03:00
|
|
|
$(MAKE) nspr
|
|
|
|
$(MAKE) ldap
|
2002-02-26 22:57:34 +03:00
|
|
|
ifdef MOZ_ENABLE_XFT
|
|
|
|
$(MAKE) freetype
|
|
|
|
$(MAKE) expat
|
|
|
|
endif
|
2001-12-10 09:13:54 +03:00
|
|
|
$(MAKE) tier_1
|
|
|
|
$(MAKE) tier_9
|
|
|
|
ifdef MOZ_PSM
|
|
|
|
$(MAKE) tier_95
|
|
|
|
endif
|
|
|
|
ifdef MOZ_MAIL_NEWS
|
|
|
|
$(MAKE) tier_97
|
|
|
|
endif
|
|
|
|
ifdef MOZ_CALENDAR
|
|
|
|
$(MAKE) tier_98
|
|
|
|
endif
|
|
|
|
$(MAKE) tier_99
|
1998-11-11 04:53:49 +03:00
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
# Make sure that the existing rulesets work
|
2002-01-26 01:29:51 +03:00
|
|
|
DIRS = \
|
2001-12-10 09:25:40 +03:00
|
|
|
$(tier_0_dirs) \
|
|
|
|
$(tier_1_dirs) \
|
|
|
|
$(tier_9_dirs) \
|
|
|
|
$(NULL)
|
|
|
|
|
2002-01-26 01:29:51 +03:00
|
|
|
ifdef GC_LEAK_DETECTOR
|
|
|
|
DIRS += gc/boehm
|
2001-12-10 11:06:51 +03:00
|
|
|
endif
|
|
|
|
|
2001-12-10 09:25:40 +03:00
|
|
|
ifdef MOZ_PSM
|
|
|
|
DIRS += $(tier_95_dirs)
|
|
|
|
endif
|
|
|
|
ifdef MOZ_MAIL_NEWS
|
|
|
|
DIRS += $(tier_97_dirs)
|
|
|
|
endif
|
|
|
|
ifdef MOZ_CALENDAR
|
|
|
|
DIRS += $(tier_98_dirs)
|
|
|
|
endif
|
|
|
|
|
|
|
|
DIRS += $(tier_99_dirs)
|
1999-10-08 05:32:44 +04:00
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
#
|
|
|
|
# tier 0 - base build config dirs
|
|
|
|
#
|
|
|
|
tier_0_dirs = \
|
|
|
|
config \
|
|
|
|
build \
|
|
|
|
include \
|
|
|
|
$(NULL)
|
1999-10-19 03:14:16 +04:00
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
#
|
|
|
|
# tier 1 - base libraries
|
|
|
|
#
|
|
|
|
tier_1_dirs = js
|
2000-08-11 04:13:39 +04:00
|
|
|
|
2001-10-27 11:38:18 +04:00
|
|
|
# MacOSX needs to build lib for MoreFiles before xpcom
|
2002-01-24 18:11:18 +03:00
|
|
|
ifneq (,$(filter mac cocoa,$(MOZ_WIDGET_TOOLKIT)))
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_1_dirs += lib/mac/MoreFiles
|
2001-10-27 11:38:18 +04:00
|
|
|
endif
|
|
|
|
|
2001-12-10 07:30:31 +03:00
|
|
|
#
|
|
|
|
# tier 9 - core components (xpcom,necko,gecko)
|
|
|
|
#
|
|
|
|
|
2001-10-23 03:14:19 +04:00
|
|
|
# intl should not be in here - it's just temporary until
|
|
|
|
# xpconnect's dependency on intl is repaired - see bug 106130
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += \
|
|
|
|
modules/libreg \
|
|
|
|
string \
|
|
|
|
xpcom \
|
|
|
|
intl \
|
|
|
|
$(NULL)
|
2000-05-20 06:45:59 +04:00
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
ifndef MOZ_NATIVE_ZLIB
|
|
|
|
tier_9_dirs += modules/zlib
|
2000-05-20 06:45:59 +04:00
|
|
|
endif
|
1998-11-11 04:53:49 +03:00
|
|
|
|
2001-12-18 12:14:29 +03:00
|
|
|
# Installer needs standalone libjar, hence standalone zlib
|
|
|
|
ifneq (,$(filter Linux SunOS WINNT,$(OS_ARCH)))
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += modules/zlib/standalone
|
2001-05-16 00:42:29 +04:00
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += \
|
|
|
|
modules/libjar \
|
|
|
|
$(NULL)
|
|
|
|
|
|
|
|
ifdef MOZ_JAVA_SUPPLEMENT
|
|
|
|
tier_9_dirs += \
|
|
|
|
java/util \
|
|
|
|
java/webclient \
|
|
|
|
$(NULL)
|
1998-11-11 04:53:49 +03:00
|
|
|
endif
|
|
|
|
|
1999-02-02 20:39:01 +03:00
|
|
|
ifndef MOZ_NATIVE_JPEG
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += jpeg
|
1999-02-02 20:39:01 +03:00
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += dbm js/src/xpconnect
|
|
|
|
|
|
|
|
ifdef MOZ_OJI
|
|
|
|
tier_9_dirs += js/src/liveconnect
|
2001-11-05 15:08:31 +03:00
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
ifdef MOZ_JSDEBUGGER
|
|
|
|
tier_9_dirs += js/jsd
|
2001-11-05 15:08:31 +03:00
|
|
|
endif
|
|
|
|
|
2002-02-26 22:57:34 +03:00
|
|
|
ifdef MOZ_ENABLE_XFT
|
|
|
|
tier_9_dirs += other-licenses/Xft
|
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
ifdef MOZ_ENABLE_XLIB
|
|
|
|
tier_9_dirs += gfx/src/xlibrgb widget/src/xlibxtbin
|
2000-08-20 03:33:23 +04:00
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
ifdef MOZ_ENABLE_GTK
|
|
|
|
tier_9_dirs += widget/src/gtksuperwin widget/src/gtkxtbin
|
|
|
|
endif
|
|
|
|
|
2001-12-12 10:59:31 +03:00
|
|
|
ifdef MOZ_INTERNAL_LIBART_LGPL
|
|
|
|
tier_9_dirs += other-licenses/libart_lgpl
|
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += \
|
1999-12-22 02:55:04 +03:00
|
|
|
modules/libutil \
|
2000-09-14 23:27:23 +04:00
|
|
|
netwerk \
|
2000-09-22 07:46:18 +04:00
|
|
|
modules/mpfilelocprovider \
|
1999-11-18 09:03:27 +03:00
|
|
|
uriloader \
|
1999-09-09 02:59:23 +04:00
|
|
|
modules/libpref \
|
|
|
|
modules/libimg \
|
|
|
|
modules/oji \
|
|
|
|
caps \
|
2001-02-22 06:01:34 +03:00
|
|
|
rdf \
|
1999-09-09 02:59:23 +04:00
|
|
|
expat \
|
|
|
|
htmlparser \
|
|
|
|
gfx \
|
2001-08-12 04:38:38 +04:00
|
|
|
gfx2 \
|
|
|
|
modules/libpr0n \
|
2000-07-22 05:27:15 +04:00
|
|
|
modules/plugin \
|
1999-09-09 02:59:23 +04:00
|
|
|
dom \
|
|
|
|
view \
|
|
|
|
widget \
|
2001-02-20 00:50:04 +03:00
|
|
|
content \
|
1999-09-09 02:59:23 +04:00
|
|
|
layout \
|
|
|
|
db \
|
1999-11-30 01:22:20 +03:00
|
|
|
docshell \
|
1999-09-09 02:59:23 +04:00
|
|
|
webshell \
|
2000-08-10 11:07:13 +04:00
|
|
|
embedding \
|
1999-09-09 02:59:23 +04:00
|
|
|
editor \
|
|
|
|
sun-java \
|
|
|
|
profile \
|
2000-08-10 10:43:05 +04:00
|
|
|
themes \
|
1999-09-09 02:59:23 +04:00
|
|
|
$(NULL)
|
1998-11-19 01:35:21 +03:00
|
|
|
|
2001-08-17 07:13:07 +04:00
|
|
|
ifdef ACCESSIBILITY
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += accessible
|
2001-08-17 07:13:07 +04:00
|
|
|
endif
|
|
|
|
|
2001-12-10 07:30:31 +03:00
|
|
|
ifdef MOZ_LDAP_XPCOM
|
2001-12-10 11:06:51 +03:00
|
|
|
tier_9_dirs += directory/xpcom
|
2001-12-10 07:30:31 +03:00
|
|
|
endif
|
|
|
|
|
2000-03-04 04:50:50 +03:00
|
|
|
# This must preceed xpfe
|
|
|
|
ifdef MOZ_JPROF
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += tools/jprof
|
2000-03-04 04:50:50 +03:00
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += xpfe xpinstall
|
2001-04-19 07:00:55 +04:00
|
|
|
|
1999-11-16 18:56:31 +03:00
|
|
|
ifdef MOZ_EXTENSIONS
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += extensions
|
1999-02-18 07:19:43 +03:00
|
|
|
endif
|
1998-10-28 06:40:33 +03:00
|
|
|
|
1999-09-26 00:44:48 +04:00
|
|
|
ifdef MOZ_LEAKY
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += tools/leaky
|
1999-09-26 00:44:48 +04:00
|
|
|
endif
|
|
|
|
|
2000-03-02 16:29:03 +03:00
|
|
|
ifdef ENABLE_TESTS
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += xpcom/tests
|
2000-03-02 16:29:03 +03:00
|
|
|
endif
|
|
|
|
|
2001-09-08 22:29:24 +04:00
|
|
|
ifdef NS_TRACE_MALLOC
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += tools/trace-malloc
|
2001-09-08 22:29:24 +04:00
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_9_dirs += l10n
|
2000-06-27 04:24:48 +04:00
|
|
|
|
2001-12-10 07:30:31 +03:00
|
|
|
#
|
|
|
|
# tier 9x - application features
|
|
|
|
#
|
|
|
|
|
|
|
|
ifdef MOZ_PSM
|
|
|
|
tier_95_dirs += security/manager
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef MOZ_MAIL_NEWS
|
|
|
|
tier_97_dirs += mailnews
|
|
|
|
endif
|
|
|
|
|
|
|
|
ifdef MOZ_CALENDAR
|
|
|
|
tier_98_dirs += calendar
|
|
|
|
endif
|
|
|
|
|
|
|
|
#
|
|
|
|
# tier 99 - application binaries
|
|
|
|
#
|
|
|
|
|
2001-06-21 00:21:49 +04:00
|
|
|
ifneq (,$(MOZ_STATIC_COMPONENTS)$(MOZ_META_COMPONENTS))
|
2001-12-10 07:30:31 +03:00
|
|
|
tier_99_dirs += modules/staticmod
|
2001-11-13 10:57:31 +03:00
|
|
|
endif
|
|
|
|
|
2001-12-10 07:30:31 +03:00
|
|
|
tier_99_dirs += xpfe/bootstrap
|
2001-04-28 21:26:54 +04:00
|
|
|
|
2002-01-25 06:33:27 +03:00
|
|
|
ifdef MOZ_ENABLE_GTK
|
2002-01-25 02:09:31 +03:00
|
|
|
tier_99_dirs += embedding/browser/gtk/tests
|
|
|
|
endif
|
|
|
|
|
2000-04-18 13:42:12 +04:00
|
|
|
endif # BUILD_MODULES == all
|
|
|
|
|
2002-01-26 01:29:51 +03:00
|
|
|
STATIC_MAKEFILES := nsprpub directory/c-sdk/ldap
|
2000-05-04 02:49:47 +04:00
|
|
|
|
2001-04-16 14:48:48 +04:00
|
|
|
ifdef MOZ_PSM
|
|
|
|
STATIC_MAKEFILES += security/nss
|
2001-04-09 13:38:30 +04:00
|
|
|
endif
|
|
|
|
|
2000-08-30 05:15:32 +04:00
|
|
|
GARBAGE_DIRS += dist
|
2000-03-17 03:49:15 +03:00
|
|
|
DIST_GARBAGE = config.cache config.log config.status config-defs.h \
|
2000-06-13 03:02:14 +04:00
|
|
|
dependencies.beos config/autoconf.mk config/myrules.mk config/myconfig.mk \
|
2000-12-13 00:28:24 +03:00
|
|
|
unallmakefiles \
|
2000-07-07 14:34:45 +04:00
|
|
|
$(topsrcdir)/.mozconfig.mk $(topsrcdir)/.mozconfig.out
|
1998-10-28 06:40:33 +03:00
|
|
|
|
2002-01-29 02:30:47 +03:00
|
|
|
ifeq ($(BUILD_MODULES),all)
|
2002-01-26 01:29:51 +03:00
|
|
|
# Build psuedo-external modules first when export is explicitly called
|
|
|
|
export::
|
|
|
|
$(MAKE) -C config export
|
|
|
|
$(MAKE) nspr
|
|
|
|
$(MAKE) ldap
|
2002-02-26 22:57:34 +03:00
|
|
|
ifdef MOZ_ENABLE_XFT
|
|
|
|
$(MAKE) freetype
|
|
|
|
$(MAKE) expat
|
|
|
|
endif
|
2002-01-29 02:30:47 +03:00
|
|
|
endif
|
2002-01-26 01:29:51 +03:00
|
|
|
|
2000-03-14 09:16:27 +03:00
|
|
|
include $(topsrcdir)/config/rules.mk
|
2000-02-24 01:47:39 +03:00
|
|
|
|
2002-01-29 02:30:47 +03:00
|
|
|
ifeq ($(BUILD_MODULES),all)
|
2002-01-26 01:29:51 +03:00
|
|
|
# Clean up after psuedo-external modules
|
|
|
|
clean clobber realclean clobber_all distclean::
|
|
|
|
ifndef MOZ_NATIVE_NSPR
|
|
|
|
$(MAKE) -C nsprpub $@
|
|
|
|
endif
|
|
|
|
ifdef MOZ_LDAP_XPCOM
|
|
|
|
$(MAKE) -C directory/c-sdk/ldap $@
|
|
|
|
endif
|
2002-01-29 02:30:47 +03:00
|
|
|
endif
|
2002-01-26 01:29:51 +03:00
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
tier_%:
|
|
|
|
@echo "$@: $($@_dirs)"
|
2001-12-10 09:25:40 +03:00
|
|
|
@$(EXIT_ON_ERROR) \
|
2001-12-10 07:30:31 +03:00
|
|
|
for d in $($@_dirs); do $(UPDATE_TITLE) \
|
|
|
|
$(MAKE) -C $$d export; \
|
|
|
|
done ; \
|
|
|
|
$(PERL) $(MOZILLA_DIR)/config/purge-old-headers.pl $(DIST)/include ;\
|
|
|
|
for d in $($@_dirs); do $(UPDATE_TITLE) \
|
|
|
|
$(MAKE) -C $$d libs; \
|
2001-12-10 09:25:40 +03:00
|
|
|
done
|
2001-11-16 10:40:42 +03:00
|
|
|
#
|
|
|
|
# Individual modules
|
|
|
|
#
|
|
|
|
boehm:
|
|
|
|
ifdef GC_LEAK_DETECTOR
|
|
|
|
$(MAKE) -C gc/boehm
|
|
|
|
endif
|
|
|
|
|
|
|
|
nspr: boehm
|
2002-01-26 01:29:51 +03:00
|
|
|
ifndef MOZ_NATIVE_NSPR
|
|
|
|
$(MAKE) -C nsprpub
|
|
|
|
endif
|
|
|
|
|
|
|
|
ldap:
|
|
|
|
ifdef MOZ_LDAP_XPCOM
|
2002-01-26 02:46:34 +03:00
|
|
|
$(MAKE) -C directory/c-sdk/ldap export
|
|
|
|
$(MAKE) -C directory/c-sdk/ldap install
|
2001-11-16 10:40:42 +03:00
|
|
|
endif
|
|
|
|
|
2002-02-26 22:57:34 +03:00
|
|
|
freetype:
|
|
|
|
ifdef MOZ_ENABLE_XFT
|
2002-02-28 18:43:17 +03:00
|
|
|
ifndef MOZ_XFT_SYSTEM_FREETYPE2
|
2002-02-26 22:57:34 +03:00
|
|
|
$(MAKE) -C other-licenses/freetype
|
|
|
|
$(MAKE) -C other-licenses/freetype install
|
|
|
|
endif
|
2002-02-28 18:43:17 +03:00
|
|
|
endif
|
2002-02-26 22:57:34 +03:00
|
|
|
|
|
|
|
expat:
|
|
|
|
ifdef MOZ_ENABLE_XFT
|
|
|
|
$(MAKE) -C other-licenses/expat
|
|
|
|
$(MAKE) -C other-licenses/expat install
|
|
|
|
endif
|
|
|
|
|
2001-11-16 10:40:42 +03:00
|
|
|
# For modules.mk standalone build
|
2000-12-11 09:52:25 +03:00
|
|
|
export::
|
|
|
|
+$(LOOP_OVER_EXPORT_DIRS)
|
|
|
|
|
2001-09-12 10:42:26 +04:00
|
|
|
export::
|
|
|
|
@$(PERL) $(MOZILLA_DIR)/config/purge-old-headers.pl $(DIST)/include
|
|
|
|
|
2000-12-13 00:28:24 +03:00
|
|
|
distclean::
|
|
|
|
cat unallmakefiles | $(XARGS) rm -f
|
|
|
|
rm -f unallmakefiles $(DIST_GARBAGE)
|