blob: 778d7303f3e002f5060b0af904b6b7d97e8f2d3c [file] [log] [blame]
Joey Armstrong3f575f72023-01-15 23:49:19 -05001# -*- makefile -*-
2# -----------------------------------------------------------------------
Joey Armstronga516c322023-01-25 17:40:42 -05003# Copyright 2022-2023 Open Networking Foundation (ONF) and the ONF Contributors
Joey Armstrong3f575f72023-01-15 23:49:19 -05004#
5# Licensed under the Apache License, Version 2.0 (the "License");
6# you may not use this file except in compliance with the License.
7# You may obtain a copy of the License at
8#
9# http://www.apache.org/licenses/LICENSE-2.0
10#
11# Unless required by applicable law or agreed to in writing, software
12# distributed under the License is distributed on an "AS IS" BASIS,
13# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14# See the License for the specific language governing permissions and
15# limitations under the License.
16#
Joey Armstrongdd334492023-07-09 17:59:02 -040017# SPDX-FileCopyrightText: 2022-2023 Open Networking Foundation (ONF) and the ONF Contributors
Joey Armstrong3f575f72023-01-15 23:49:19 -050018# SPDX-License-Identifier: Apache-2.0
19# -----------------------------------------------------------------------
Joey Armstrongdd334492023-07-09 17:59:02 -040020# https://gerrit.opencord.org/plugins/gitiles/onf-make
21# ONF.makefiles.include.version = 1.1
22# -----------------------------------------------------------------------
23
24ifndef mk-include--onf-make # single-include guard macro
Joey Armstrong3f575f72023-01-15 23:49:19 -050025
26$(if $(DEBUG),$(warning ENTER))
27
Joey Armstrongdd334492023-07-09 17:59:02 -040028## -----------------------------------------------------------------------
29## Define vars based on relative import (normalize symlinks)
30## Usage: include makefiles/onf/include.mk
31## -----------------------------------------------------------------------
32onf-mk-abs ?= $(abspath $(lastword $(MAKEFILE_LIST)))
33onf-mk-top := $(subst /include.mk,$(null),$(onf-mk-abs))
34ONF_MAKEDIR := $(onf-mk-top)
Joey Armstrongb3a06412023-02-06 09:58:58 -050035
Joey Armstrongdd334492023-07-09 17:59:02 -040036TOP ?= $(patsubst %/makefiles/include.mk,%,$(onf-mk-abs))
Joey Armstrong3f575f72023-01-15 23:49:19 -050037
Joey Armstrongdd334492023-07-09 17:59:02 -040038include $(ONF_MAKEDIR)/consts.mk
39include $(ONF_MAKEDIR)/help/include.mk # render target help
40include $(ONF_MAKEDIR)/utils/include.mk # dependency-less helper macros
41include $(ONF_MAKEDIR)/etc/include.mk # banner macros
42include $(ONF_MAKEDIR)/commands/include.mk # Tools and local installers
Joey Armstrongb3a06412023-02-06 09:58:58 -050043
Joey Armstrongdd334492023-07-09 17:59:02 -040044include $(ONF_MAKEDIR)/virtualenv.mk# # lint-{jjb,python} depends on venv
45include $(ONF_MAKEDIR)/lint/include.mk
Joey Armstrong01bbf8d2023-03-05 06:20:14 -050046
Joey Armstrongdd334492023-07-09 17:59:02 -040047include $(ONF_MAKEDIR)/gerrit/include.mk
48include $(ONF_MAKEDIR)/git/include.mk
49include $(ONF_MAKEDIR)/jjb/include.mk
Joey Armstrongf3208602023-06-03 15:12:23 -040050
Joey Armstrongdd334492023-07-09 17:59:02 -040051$(if $(USE-VOLTHA-RELEASE-MK),\
52 $(eval include $(ONF_MAKEDIR)/release/include.mk))
Joey Armstrong7ee65262023-06-02 09:55:04 -040053
Joey Armstrongdd334492023-07-09 17:59:02 -040054include $(ONF_MAKEDIR)/todo.mk
55include $(ONF_MAKEDIR)/help/variables.mk
56
57##---------------------##
58##---] ON_DEMAND [---##
59##---------------------##
60$(if $(USE-ONF-GERRIT-MK),$(eval include $(ONF_MAKEDIR)/gerrit/include.mk))
61$(if $(USE-ONF-DOCKER-MK),$(eval include $(ONF_MAKEDIR)/docker/include.mk))
Joey Armstrong3f575f72023-01-15 23:49:19 -050062
Joey Armstrong01bbf8d2023-03-05 06:20:14 -050063##-------------------##
64##---] TARGETS [---##
65##-------------------##
Joey Armstrongdd334492023-07-09 17:59:02 -040066include $(ONF_MAKEDIR)/targets/include.mk # clean, sterile
Joey Armstrong01bbf8d2023-03-05 06:20:14 -050067
Joey Armstrong3f575f72023-01-15 23:49:19 -050068$(if $(DEBUG),$(warning LEAVE))
69
Joey Armstrongdd334492023-07-09 17:59:02 -040070mk-include--onf-make := true
71
72endif # mk-include--onf-make
Joey Armstrong01bbf8d2023-03-05 06:20:14 -050073
Joey Armstrong3f575f72023-01-15 23:49:19 -050074# [EOF]