1 #########################################################################
4 # Copyright (C) 2009-2013, Intel Corporation
8 # Redistribution and use in source and binary forms, with or without
9 # modification, are permitted provided that the following conditions
12 # * Redistributions of source code must retain the above copyright
13 # notice, this list of conditions and the following disclaimer.
14 # * Redistributions in binary form must reproduce the above copyright
15 # notice, this list of conditions and the following disclaimer in
16 # the documentation and/or other materials provided with the
18 # * Neither the name of Intel Corporation nor the names of its
19 # contributors may be used to endorse or promote products derived
20 # from this software without specific prior written permission.
23 # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
24 # "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
25 # LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
26 # A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
27 # HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
28 # INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
29 # BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
30 # OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED
31 # AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
32 # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY
33 # WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
34 # POSSIBILITY OF SUCH DAMAGE.
35 ###########################################################################
38 # The one place we look up information from the code management system
40 # Note that the build number is *only* valid on the build machines
42 ifeq ($(wildcard $(TOP
)/..
/.hg
),)
43 # If this is the open source release, there is no Mercurial repository,
44 # so set some reasonable defaults.
45 CILK_VERSION_MAJOR
:= 2
46 CILK_VERSION_MINOR
:= 0
47 CILK_VERSION_BUILD
:= 1
50 CILK_VERSION_HASH
:= 000000000000
51 CILK_VERSION_BRANCH
:= oss
53 CILK_VERSION_MAJOR
:= 2
54 CILK_VERSION_MINOR
:= 0
55 CILK_VERSION_BUILD
:= $(firstword $(subst +, ,$(shell hg id
--num
)))
58 CILK_VERSION_HASH
:= $(firstword $(subst +, ,$(shell hg id
--id
)))
59 CILK_VERSION_BRANCH
:= $(shell hg id
--branch
)