config/makefiles/rcs.mk
author Philipp Kewisch <mozilla@kewis.ch>
Sat, 01 Mar 2014 18:47:43 +0100
branchGECKO2410_2013102317_RELBRANCH
changeset 16082 4ac7c5c82012268524c83f6b388a55a8a569bdb1
parent 14871 bce8262aabcc6bb720ed18ec46b47e1f691be5ca
permissions -rw-r--r--
Added tag THUNDERBIRD_24_1_1_RELEASE, THUNDERBIRD_24_1_1_BUILD1 for changeset cbcdcd77d6f8 DONTBUILD CLOSED TREE a=release

# -*- makefile -*-
# vim:set ts=8 sw=8 sts=8 noet:
#
# 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/.
#

ifdef USE_RCS_MK #{

ifndef INCLUDED_RCS_MK #{

MOZ_RCS_TYPE ?= $(notdir $(wildcard $(topsrcdir)/.hg))


###########################################################################
# HAVE_MERCURIAL_RCS
###########################################################################
ifeq (.hg,$(MOZ_RCS_TYPE)) #{

# Intent: Retrieve the http:// repository path for a directory.
# Usage: $(call getSourceRepo[,repo_dir|args])
# Args:
#   path (optional): repository to query.  Defaults to $(topsrcdir)
getSourceRepo = \
  $(call FUNC_getSourceRepo,$(if $(1),cd $(1) && hg,hg --repository $(topsrcdir)))

# return: http://hg.mozilla.org/mozilla-central
FUNC_getSourceRepo = \
  $(strip \
    $(patsubst %/,%,\
    $(patsubst ssh://%,http://%,\
    $(firstword $(shell $(getargv) showconfig paths.default))\
    )))

endif #} HAVE_MERCURIAL_RCS


INCLUDED_RCS_MK := 1
endif #}

endif #}