author | sgehwolf |
Wed, 03 Feb 2016 12:19:03 +0100 | |
changeset 35928 | 084d5cb04276 |
parent 29662 | 78c47f0002c3 |
child 41040 | 7b919a4497ff |
permissions | -rw-r--r-- |
0 | 1 |
# |
29662 | 2 |
# Copyright (c) 2012, 2015, Oracle and/or its affiliates. All rights reserved. |
0 | 3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 |
# |
|
5 |
# This code is free software; you can redistribute it and/or modify it |
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
|
5499 | 7 |
# published by the Free Software Foundation. Oracle designates this |
0 | 8 |
# particular file as subject to the "Classpath" exception as provided |
5499 | 9 |
# by Oracle in the LICENSE file that accompanied this code. |
0 | 10 |
# |
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
|
15 |
# accompanied this code). |
|
16 |
# |
|
17 |
# You should have received a copy of the GNU General Public License version |
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
20 |
# |
|
5499 | 21 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
22 |
# or visit www.oracle.com if you need additional information or have any |
|
23 |
# questions. |
|
0 | 24 |
# |
25 |
||
29662 | 26 |
### |
27 |
### This file is just a very small wrapper needed to run the real make/Init.gmk. |
|
28 |
### It also performs some sanity checks on make. |
|
29 |
### |
|
17
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
30 |
|
29662 | 31 |
# The shell code below will be executed on /usr/ccs/bin/make on Solaris, but not in GNU Make. |
32 |
# /usr/ccs/bin/make lacks basically every other flow control mechanism. |
|
33 |
.TEST_FOR_NON_GNUMAKE:sh=echo You are not using GNU Make/gmake, this is a requirement. Check your path. 1>&2 && exit 1 |
|
9618 | 34 |
|
29662 | 35 |
# The .FEATURES variable is likely to be unique for GNU Make. |
36 |
ifeq ($(.FEATURES), ) |
|
37 |
$(info Error: '$(MAKE)' does not seem to be GNU Make, which is a requirement.) |
|
38 |
$(info Check your path, or upgrade to GNU Make 3.81 or newer.) |
|
39 |
$(error Cannot continue) |
|
40 |
endif |
|
0 | 41 |
|
29662 | 42 |
# Assume we have GNU Make, but check version. |
21759 | 43 |
ifeq ($(strip $(foreach v, 3.81% 3.82% 4.%, $(filter $v, $(MAKE_VERSION)))), ) |
29662 | 44 |
$(info Error: This version of GNU Make is too low ($(MAKE_VERSION)).) |
45 |
$(info Check your path, or upgrade to GNU Make 3.81 or newer.) |
|
46 |
$(error Cannot continue) |
|
47 |
endif |
|
48 |
||
49 |
# In Cygwin, the MAKE variable gets prepended with the current directory if the |
|
50 |
# make executable is called using a Windows mixed path (c:/cygwin/bin/make.exe). |
|
51 |
ifneq ($(findstring :, $(MAKE)), ) |
|
52 |
MAKE := $(patsubst $(CURDIR)%, %, $(patsubst $(CURDIR)/%, %, $(MAKE))) |
|
874
638ddad10e12
6728161: Add SKIP_BOOT_CYCLE feature to create boot jdk and use it during build
ohair
parents:
668
diff
changeset
|
53 |
endif |
638ddad10e12
6728161: Add SKIP_BOOT_CYCLE feature to create boot jdk and use it during build
ohair
parents:
668
diff
changeset
|
54 |
|
21759 | 55 |
# Locate this Makefile |
29662 | 56 |
ifeq ($(filter /%, $(lastword $(MAKEFILE_LIST))),) |
57 |
makefile_path := $(CURDIR)/$(strip $(lastword $(MAKEFILE_LIST))) |
|
21759 | 58 |
else |
29662 | 59 |
makefile_path := $(lastword $(MAKEFILE_LIST)) |
27595
cff167b3bfa2
8065914: Various improvements and cleanup of build system
ihse
parents:
26548
diff
changeset
|
60 |
endif |
29662 | 61 |
topdir := $(strip $(patsubst %/, %, $(dir $(makefile_path)))) |
874
638ddad10e12
6728161: Add SKIP_BOOT_CYCLE feature to create boot jdk and use it during build
ohair
parents:
668
diff
changeset
|
62 |
|
29662 | 63 |
# ... and then we can include the real makefile |
64 |
include $(topdir)/make/Init.gmk |