https://github.com/mozilla/gecko-dev
Raw File
Tip revision: 2bb58d6708560733bd6282089761fc7d89ab4d02 authored by ffxbld on 22 May 2015, 00:49:37 UTC
Added FIREFOX_38_0_5_RELEASE FIREFOX_38_0_5_BUILD3 tag(s) for changeset 7ded72d766cd. DONTBUILD CLOSED TREE a=release
Tip revision: 2bb58d6
Makefile.in
#
# 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/.

USE_RCS_MK := 1
include $(topsrcdir)/config/makefiles/makeutils.mk

ifdef MOZ_APP_BASENAME
DIST_FILES = $(srcdir)/application.ini

ifneq (android,$(MOZ_WIDGET_TOOLKIT))
ifdef MOZ_UPDATER
DIST_FILES += update-settings.ini
endif
endif

ifdef LIBXUL_SDK
APP_INI_DEPS = $(LIBXUL_DIST)/bin/platform.ini
else
APP_INI_DEPS = $(topsrcdir)/config/milestone.txt
endif

APP_BUILDID := $(shell cat $(DEPTH)/config/buildid)
APP_INI_DEPS += $(DEPTH)/config/buildid

DEFINES += -DAPP_BUILDID=$(APP_BUILDID)

APP_INI_DEPS += $(DEPTH)/config/autoconf.mk

MOZ_SOURCE_STAMP := $(firstword $(shell cd $(topsrcdir)/$(MOZ_BUILD_APP)/.. && hg parent --template='{node|short}\n' 2>/dev/null))
ifdef MOZ_SOURCE_STAMP
DEFINES += -DMOZ_SOURCE_STAMP='$(MOZ_SOURCE_STAMP)'
endif

ifdef MOZ_INCLUDE_SOURCE_INFO
source_repo ?= $(call getSourceRepo,$(topsrcdir)/$(MOZ_BUILD_APP)/..)
ifneq (,$(source_repo))
  DEFINES += -DMOZ_SOURCE_REPO='$(source_repo)'
endif
endif

endif

# Put a useful .gdbinit in the bin directory, to be picked up automatically
# by GDB when we debug executables there.
# NOTE: Keep .gdbinit in the topsrcdir for people who run gdb from the topsrcdir.
GDBINIT_FILES := $(topsrcdir)/.gdbinit
GDBINIT_OBJDIR_FILES = $(topsrcdir)/.gdbinit
GDBINIT_DEST = $(FINAL_TARGET)

# needs to be absolute to be distinct from $(topsrcdir)/.gdbinit
GDBINIT_OBJDIR_DEST = $(abspath $(DEPTH))
INSTALL_TARGETS += GDBINIT GDBINIT_OBJDIR

# Put a .lldbinit in the bin directory and the objdir, to be picked up
# automatically by LLDB when we debug executables using either of those two
# directories as the current working directory.  The .lldbinit file will
# load $(topsrcdir)/.lldbinit, which is where the actual debugging commands are.
LLDBINIT_OBJDIR := .lldbinit.in
LLDBINIT_OBJDIR_PATH = $(DEPTH)
LLDBINIT_OBJDIR_FLAGS += -Dtopsrcdir=$(abspath $(topsrcdir))
PP_TARGETS += LLDBINIT_OBJDIR

LLDBINIT_FINAL_TARGET_FILES := $(DEPTH)/.lldbinit
LLDBINIT_FINAL_TARGET_DEST = $(FINAL_TARGET)
INSTALL_TARGETS += LLDBINIT_FINAL_TARGET

ifeq (1_1,$(MOZ_ASAN)_$(CLANG_CL))
# Install the clang-cl runtime library for ASAN next to the binaries we produce.
CLANG_RT_ASAN_FILES := $(MOZ_CLANG_RT_ASAN_LIB_PATH)
CLANG_RT_ASAN_DEST = $(FINAL_TARGET)
INSTALL_TARGETS += CLANG_RT_ASAN
endif

ifdef MOZTTDIR
# Install the Firefox OS fonts.
include $(MOZTTDIR)/fonts.mk
MOZTT_DEST = $(FINAL_TARGET)/fonts
MOZTT_FILES = $(patsubst external/moztt/%,$(MOZTTDIR)/%,$(filter external/moztt/%,$(subst :, ,$(PRODUCT_COPY_FILES))))
INSTALL_TARGETS += MOZTT
endif

include $(topsrcdir)/config/rules.mk

TARGET_DEPTH = ..
include $(srcdir)/automation-build.mk

ifdef MOZ_APP_BASENAME
$(FINAL_TARGET)/application.ini: $(APP_INI_DEPS)

ifdef MOZ_APP_STATIC_INI
application.ini.h: appini_header.py $(FINAL_TARGET)/application.ini
	$(PYTHON) $^ > $@
export:: application.ini.h
GARBAGE += application.ini.h
endif
endif

libs:: automation.py

ifdef MOZ_VALGRIND
_VALGRIND_DIR = $(DEPTH)/_valgrind
GARBAGE_DIRS += $(_VALGRIND_DIR)

_VALGRIND_FILES = \
		$(topsrcdir)/build/valgrind/cross-architecture.sup \
		$(topsrcdir)/build/valgrind/i386-redhat-linux-gnu.sup \
		$(topsrcdir)/build/valgrind/x86_64-redhat-linux-gnu.sup \
		$(NULL)

libs:: $(_VALGRIND_FILES)
	$(INSTALL) $^ $(_VALGRIND_DIR)
endif

ifneq (,$(ENABLE_TESTS)$(MOZ_DMD))
libs:: $(topsrcdir)/tools/rb/fix_stack_using_bpsyms.py
	$(INSTALL) $< $(DIST)/bin

ifeq ($(OS_ARCH),Darwin)
libs:: $(topsrcdir)/tools/rb/fix_macosx_stack.py
	$(INSTALL) $< $(DIST)/bin
endif

ifeq ($(OS_ARCH),Linux)
libs:: $(topsrcdir)/tools/rb/fix_linux_stack.py
	$(INSTALL) $< $(DIST)/bin
endif
endif # ENABLE_TESTS or MOZ_DMD

ifdef ENABLE_TESTS
GARBAGE += $(srcdir)/automationutils.pyc
endif # ENABLE_TESTS

ifdef MOZ_DMD
libs:: $(topsrcdir)/memory/replace/dmd/dmd.py
	$(INSTALL) $< $(DIST)/bin
endif

back to top