Update repository to use repo:onf-make/makefiles
.gitmodules
Makefile
config.mk -> lf/config.mk
lf/include.mk
lf/local/include.mk
lf/onf-make
makefiles/README.md
-------------------------
o Initial staging to remove per-repository makefiles/ directory.
o Add repo:onf-make as a git submodule.
o lf/include.mk is central access for loading all library logic.
o lf/local/ replaces $(sandbox-root)/makefiles.
*.groovy, *.sh, *.yaml
----------------------
o Include source edits to force pipeline to rebuild.
o Added SPDX copyright notice tokens.
Change-Id: Ia6b95880e720956d01af2c5966f7ae5d0f4c13b1
diff --git a/.gitmodules b/.gitmodules
index c815615..c0cb8ec 100644
--- a/.gitmodules
+++ b/.gitmodules
@@ -7,3 +7,6 @@
[submodule "packer/common-packer"]
path = packer/common-packer
url = https://github.com/lfit/releng-common-packer.git
+[submodule "lf/onf-make"]
+ path = lf/onf-make
+ url = http://gerrit.opencord.org/onf-make
diff --git a/Makefile b/Makefile
index 489303c..b064411 100644
--- a/Makefile
+++ b/Makefile
@@ -25,8 +25,9 @@
##--------------------##
##---] INCLUDES [---##
##--------------------##
-include config.mk
-include makefiles/include.mk
+# include config.mk
+include lf/include.mk
+
ONF_MAKEDIR ?= $(error ONF_MAKEDIR= is required)
# [TODO]
diff --git a/jjb/pipeline/bbsim-validation.groovy b/jjb/pipeline/bbsim-validation.groovy
index 1b3d38f..0706a07 100644
--- a/jjb/pipeline/bbsim-validation.groovy
+++ b/jjb/pipeline/bbsim-validation.groovy
@@ -1,4 +1,5 @@
-// Copyright 2017-2024 Open Networking Foundation (ONF) and the ONF Contributors
+// -----------------------------------------------------------------------
+// Copyright 2017-2024 Open Networking Foundation Contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -11,9 +12,15 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
-
-// chart-api-test-helm.groovy
-// Checks functionality of the helm-chart, without overriding the version/tag used
+// -----------------------------------------------------------------------
+// SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+// SPDX-License-Identifier: Apache-2.0
+// -----------------------------------------------------------------------
+// Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+// -----------------------------------------------------------------------
+// Intent: chart-api-test-helm.groovy
+// Checks functionality of the helm-chart, without overriding the ver/tag used
+// -----------------------------------------------------------------------
pipeline {
@@ -201,3 +208,5 @@
}
}
}
+
+// [EOF]
diff --git a/jjb/pipeline/voltha/bbsim-tests.groovy b/jjb/pipeline/voltha/bbsim-tests.groovy
index 9983ee9..b0ba1a3 100644
--- a/jjb/pipeline/voltha/bbsim-tests.groovy
+++ b/jjb/pipeline/voltha/bbsim-tests.groovy
@@ -1,4 +1,5 @@
-// Copyright 2021-2024 Open Networking Foundation (ONF) and the ONF Contributors
+// -----------------------------------------------------------------------
+// Copyright 2021-2024 Open Networking Foundation Contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -11,9 +12,13 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
-
+// -----------------------------------------------------------------------
+// SPDX-FileCopyrightText: 2021-2024 Open Networking Foundation Contributors
+// SPDX-License-Identifier: Apache-2.0
+// -----------------------------------------------------------------------
// voltha-2.x e2e tests for openonu-go
// uses bbsim to simulate OLT/ONUs
+// -----------------------------------------------------------------------
// [TODO] Update library() to the latest DSL syntax supported by jenkins
library identifier: 'cord-jenkins-libraries@master',
diff --git a/jjb/pipeline/voltha/physical-build.groovy b/jjb/pipeline/voltha/physical-build.groovy
index 5cab632..e9f3818 100755
--- a/jjb/pipeline/voltha/physical-build.groovy
+++ b/jjb/pipeline/voltha/physical-build.groovy
@@ -1,4 +1,6 @@
-// Copyright 2017-2024 Open Networking Foundation (ONF) and the ONF Contributors
+#!/usr/bin/env groovy
+// -----------------------------------------------------------------------
+// Copyright 2017-2024 Open Networking Foundation Contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -11,8 +13,14 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
-
-// used to deploy VOLTHA and configure ONOS physical PODs
+// -----------------------------------------------------------------------
+// SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+// SPDX-License-Identifier: Apache-2.0
+// -----------------------------------------------------------------------
+// Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+// -----------------------------------------------------------------------
+// Intent: used to deploy VOLTHA and configure ONOS physical PODs
+// -----------------------------------------------------------------------
// NOTE we are importing the library even if it's global so that it's
// easier to change the keywords during a replay
@@ -427,3 +435,5 @@
}
}
}
+
+// [EOF]
diff --git a/jjb/pipeline/voltha/software-upgrades.groovy b/jjb/pipeline/voltha/software-upgrades.groovy
index b5455e6..e169d1b 100755
--- a/jjb/pipeline/voltha/software-upgrades.groovy
+++ b/jjb/pipeline/voltha/software-upgrades.groovy
@@ -1,4 +1,6 @@
-// Copyright 2021-2024 Open Networking Foundation (ONF) and the ONF Contributors
+#!/usr/bin/env groovy
+// -----------------------------------------------------------------------
+// Copyright 2021-2024 Open Networking Foundation Contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -11,10 +13,18 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
-// voltha-2.x e2e tests
-// uses bbsim to simulate OLT/ONUs
-// NOTE we are importing the library even if it's global so that it's
+// -----------------------------------------------------------------------
+// SPDX-FileCopyrightText: 2021-2024 Open Networking Foundation Contributors
+// SPDX-License-Identifier: Apache-2.0
+// -----------------------------------------------------------------------
+// Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+// -----------------------------------------------------------------------
+// Intent: voltha-2.x e2e tests, uses bbsim to simulate OLT/ONUs
+// -----------------------------------------------------------------------
+// NOTE: we are importing the library even if it's global so that it's
// easier to change the keywords during a replay
+// -----------------------------------------------------------------------
+
library identifier: 'cord-jenkins-libraries@master',
retriever: modernSCM([
$class: 'GitSCMSource',
@@ -380,3 +390,5 @@
} // always
} // post
} // pipeline
+
+// [EOF]
diff --git a/jjb/pipeline/voltha/voltha-physical-functional-tests.groovy b/jjb/pipeline/voltha/voltha-physical-functional-tests.groovy
index 7da5a31..61c85b6 100644
--- a/jjb/pipeline/voltha/voltha-physical-functional-tests.groovy
+++ b/jjb/pipeline/voltha/voltha-physical-functional-tests.groovy
@@ -1,6 +1,6 @@
#!/usr/bin/env groovy
// -----------------------------------------------------------------------
-// Copyright 2017-2024 Open Networking Foundation (ONF) and the ONF Contributors
+// Copyright 2017-2024 Open Networking Foundation Contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -14,6 +14,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
// -----------------------------------------------------------------------
+// SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+// SPDX-License-Identifier: Apache-2.0
+// -----------------------------------------------------------------------
+// Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+// -----------------------------------------------------------------------
+// Intent:
+// -----------------------------------------------------------------------
library identifier: 'cord-jenkins-libraries@master',
retriever: modernSCM([
@@ -267,3 +274,5 @@
}
}
}
+
+// [EOF]
diff --git a/jjb/pipeline/voltha/voltha-scale-multi-stack.groovy b/jjb/pipeline/voltha/voltha-scale-multi-stack.groovy
old mode 100644
new mode 100755
index 42b8e73..7ea3737
--- a/jjb/pipeline/voltha/voltha-scale-multi-stack.groovy
+++ b/jjb/pipeline/voltha/voltha-scale-multi-stack.groovy
@@ -1,4 +1,7 @@
-// Copyright 2019-2024 Open Networking Foundation (ONF) and the ONF Contributors
+#!/usr/bin/env groovy
+// -----------------------------------------------------------------------
+// Copyright 2019-2024 Open Networking Foundation Contributors
+//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
@@ -10,8 +13,14 @@
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
-
-// deploy VOLTHA using kind-voltha and performs a scale test
+// -----------------------------------------------------------------------
+// SPDX-FileCopyrightText: 2019-2024 Open Networking Foundation Contributors
+// SPDX-License-Identifier: Apache-2.0
+// -----------------------------------------------------------------------
+// Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+// -----------------------------------------------------------------------
+// Intent: Deploy VOLTHA using kind-voltha and performs a scale test
+// -----------------------------------------------------------------------
// NOTE we are importing the library even if it's global so that it's
// easier to change the keywords during a replay
@@ -454,3 +463,5 @@
}
}
}
+
+// [EOF]
diff --git a/jjb/pipeline/voltha/voltha-tt-physical-functional-tests.groovy b/jjb/pipeline/voltha/voltha-tt-physical-functional-tests.groovy
index 461ce88..6cebea7 100644
--- a/jjb/pipeline/voltha/voltha-tt-physical-functional-tests.groovy
+++ b/jjb/pipeline/voltha/voltha-tt-physical-functional-tests.groovy
@@ -1,6 +1,6 @@
-// -*- groovy -*-
+#!/usr/bin/env groovy
// -----------------------------------------------------------------------
-// Copyright 2017-2024 Open Networking Foundation (ONF) and the ONF Contributors
+// Copyright 2017-2024 Open Networking Foundation Contributors
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -14,6 +14,13 @@
// See the License for the specific language governing permissions and
// limitations under the License.
// -----------------------------------------------------------------------
+// SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+// SPDX-License-Identifier: Apache-2.0
+// -----------------------------------------------------------------------
+// Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+// -----------------------------------------------------------------------
+// Intent:
+// -----------------------------------------------------------------------
library identifier: 'cord-jenkins-libraries@master',
retriever: modernSCM([
@@ -268,3 +275,5 @@
}
}
}
+
+// [EOF]
diff --git a/jjb/release.yaml b/jjb/release.yaml
index 9a37aba..33cfe96 100644
--- a/jjb/release.yaml
+++ b/jjb/release.yaml
@@ -1,5 +1,27 @@
---
-# release and repo manifest related jobs
+
+# -----------------------------------------------------------------------
+# Copyright 2017-2024 Open Networking Foundation Contributors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http:#www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# -----------------------------------------------------------------------
+# SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+# SPDX-License-Identifier: Apache-2.0
+# -----------------------------------------------------------------------
+# Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+# -----------------------------------------------------------------------
+# Intent: release and repo manifest related jobs
+# -----------------------------------------------------------------------
- job-template:
id: verify-repo-manifest
@@ -47,5 +69,4 @@
set -eu -o pipefail
./validate_manifest.sh
-
# [EOF]
diff --git a/jjb/shell/shcheck.sh b/jjb/shell/shcheck.sh
index 7a1fd80..d1fbc4a 100755
--- a/jjb/shell/shcheck.sh
+++ b/jjb/shell/shcheck.sh
@@ -1,20 +1,26 @@
#!/usr/bin/env bash
-
-# Copyright 2017-2024 Open Networking Foundation (ONF) and the ONF Contributors
+# -----------------------------------------------------------------------
+# Copyright 2017-2024 Open Networking Foundation Contributors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
-# http://www.apache.org/licenses/LICENSE-2.0
+# http:#www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
-
-# shcheck.sh - check shell scripts with shellcheck
+# -----------------------------------------------------------------------
+# SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+# SPDX-License-Identifier: Apache-2.0
+# -----------------------------------------------------------------------
+# Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+# -----------------------------------------------------------------------
+# Intent: Syntax check shell scripts with shellcheck
+# -----------------------------------------------------------------------
set +e -u -o pipefail
fail_shellcheck=0
diff --git a/jjb/verify/bbsim-sadis-server.yaml b/jjb/verify/bbsim-sadis-server.yaml
index 7460606..e7be2f6 100644
--- a/jjb/verify/bbsim-sadis-server.yaml
+++ b/jjb/verify/bbsim-sadis-server.yaml
@@ -1,5 +1,27 @@
---
-# verification jobs for 'bbsim-sadis-server' repo
+
+# -----------------------------------------------------------------------
+# Copyright 2017-2024 Open Networking Foundation Contributors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http:#www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# -----------------------------------------------------------------------
+# SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+# SPDX-License-Identifier: Apache-2.0
+# -----------------------------------------------------------------------
+# Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+# -----------------------------------------------------------------------
+# Intent: verification jobs for 'bbsim-sadis-server' repo
+# -----------------------------------------------------------------------
- project:
name: bbsim-sadis-server
@@ -35,8 +57,10 @@
name: 'verify-bbsim-sadis-server-jobs-master'
jobs:
- 'voltha-patch-test':
- extraHelmFlags: '--set global.image_tag=master --set onos-classic.image.tag=master'
-
+ extraHelmFlags: >
+ set global.image_tag=master
+ --set onos-classic.image.tag=master
+
- job-group:
name: 'verify-bbsim-sadis-server-jobs-voltha-2.12'
jobs:
@@ -59,4 +83,4 @@
docker-repo: 'voltha'
dependency-jobs: 'version-tag_wildcard'
-# [EOF] x 3
+# [EOF]
diff --git a/jjb/verify/bbsim.yaml b/jjb/verify/bbsim.yaml
index 8036d72..bbba989 100644
--- a/jjb/verify/bbsim.yaml
+++ b/jjb/verify/bbsim.yaml
@@ -1,5 +1,27 @@
---
-# verification jobs for 'bbsim' repo
+
+# -----------------------------------------------------------------------
+# Copyright 2017-2024 Open Networking Foundation Contributors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http:#www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# -----------------------------------------------------------------------
+# SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+# SPDX-License-Identifier: Apache-2.0
+# -----------------------------------------------------------------------
+# Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
+# -----------------------------------------------------------------------
+# Intent: Verification jobs for 'bbsim' repo
+# -----------------------------------------------------------------------
- project:
name: bbsim
@@ -17,10 +39,6 @@
name-extension: '-voltha-2.11'
override-branch: 'voltha-2.11'
branch-regexp: '^voltha-2.11$'
-# - 'verify-bbsim-jobs-voltha-2.8':
-# name-extension: '-voltha-2.8'
-# override-branch: 'voltha-2.8'
-# branch-regexp: '^voltha-2.8$'
- 'verify-bbsim-jobs-master':
branch-regexp: '^master$'
- 'publish-bbsim-jobs':
@@ -38,7 +56,7 @@
unit-test-targets: 'lint sca test'
unit-test-keep-going: 'false'
-#- job-group:
+# - job-group:
# name: 'verify-bbsim-jobs-voltha-2.8'
# jobs:
# - 'voltha-patch-test':
@@ -130,7 +148,7 @@
flags: ""
teardown: true
logging: true
-
+
- job-group:
name: 'publish-bbsim-jobs'
jobs:
@@ -144,4 +162,4 @@
release-targets: 'release'
artifact-glob: 'release/*'
-# [EOF] x 3
+# [EOF]
diff --git a/jjb/voltha-e2e.yaml b/jjb/voltha-e2e.yaml
index 269beef..7a1a99d 100755
--- a/jjb/voltha-e2e.yaml
+++ b/jjb/voltha-e2e.yaml
@@ -1,20 +1,21 @@
---
+
# -----------------------------------------------------------------------
-# Copyright 2019-2024 Open Networking Foundation Contributors
+# Copyright 2017-2024 Open Networking Foundation Contributors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
-# http://www.apache.org/licenses/LICENSE-2.0
+# http:#www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
-#
-# SPDX-FileCopyrightText: 2019-2024 Open Networking Foundation Contributors
+# -----------------------------------------------------------------------
+# SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
# SPDX-License-Identifier: Apache-2.0
# -----------------------------------------------------------------------
# Entropy: 0fcb5ffa-d1a4-11ee-be5e-9f44b7181764
diff --git a/lf/README.md b/lf/README.md
new file mode 100644
index 0000000..a021181
--- /dev/null
+++ b/lf/README.md
@@ -0,0 +1,15 @@
+Library makefiles
+=================
+
+$(sandbox-root)/include.mk
+ Source this makefile to import library makefile logic.
+
+$(sandbox-root)/lf/onf-maker/
+$(sandbox-root)/lf/onf-maker/include.mk
+ repo:onf-make library makefiles
+ checked out (frozen) as a git submodule.
+
+$(sandbox-root)/lf/local/
+$(sandbox-root)/lf/local/include.mk
+ makefile directory for per-repository targets and logic.
+
diff --git a/config.mk b/lf/config.mk
similarity index 100%
rename from config.mk
rename to lf/config.mk
diff --git a/lf/include.mk b/lf/include.mk
new file mode 100644
index 0000000..7034ea3
--- /dev/null
+++ b/lf/include.mk
@@ -0,0 +1,84 @@
+# -*- makefile -*-
+# -----------------------------------------------------------------------
+# Copyright 2023-2024 Open Networking Foundation Contributors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# -----------------------------------------------------------------------
+# SPDX-FileCopyrightText: 2023-2024 Open Networking Foundation Contributors
+# SPDX-License-Identifier: Apache-2.0
+# -----------------------------------------------------------------------
+
+$(if $(DEBUG),$(warning ENTER))
+
+## -----------------------------------------------------------------------
+## Infer path to cloned sandbox root
+## [TODO] Deprecate TOP=
+## -----------------------------------------------------------------------
+lf-sbx-root := $(abspath $(lastword $(MAKEFILE_LIST)))
+lf-sbx-root := $(subst /lf/include.mk,$(null),$(lf-sbx-root))
+
+## -----------------------------------------------------------------------
+## Define vars based on relative import (normalize symlinks)
+## Usage: include makefiles/onf/include.mk
+## -----------------------------------------------------------------------
+onf-mk-abs := $(abspath $(lastword $(MAKEFILE_LIST)))
+onf-mk-top := $(subst /include.mk,$(null),$(onf-mk-abs))
+onf-mk-lib := $(onf-mk-top)/onf-make/makefiles
+onf-mk-loc := $(onf-mk-top)/local
+
+TOP ?= $(patsubst %/makefiles/include.mk,%,$(onf-mk-abs))
+
+## ------------------------------------------------------
+## Two distinct vars needed to access library or project
+## ------------------------------------------------------
+ONF_MAKEDIR ?= $(onf-mk-lib)
+MAKEDIR ?= $(onf-mk-loc)
+
+# Load per-repository conditionals
+# Load late else alter MAKEFILE_LIST
+include $(lf-sbx-root)/lf/config.mk
+
+## -----------------------------------------------------------------------
+## Load makefiles in order:
+## 1) Library constants and logic loaded first
+## 2) Parameterize and augment targets from local (repo specific)
+## -----------------------------------------------------------------------
+include $(onf-mk-lib)/include.mk
+include $(onf-mk-loc)/include.mk
+
+## -----------------------------------------------------------------------
+## Intent: This target will update dependent git-submodule to the latest
+## version available from the remote repository. Subsequently
+## a checkin will be needed to make the submodule update permanent.
+## -----------------------------------------------------------------------
+update-submodules:
+ git submodule foreach git pull
+
+## -----------------------------------------------------------------------
+## Intent: On-demand cloning of git submodule(s).
+## -----------------------------------------------------------------------
+## Trigger: include $(onf-mk-lib)/include.mk
+## - When the make command attempts to include a makefile from the
+## repo:onf-make submodule, this target/dependency will initialize
+## and checkout all submodules the current repository depends on.
+## -----------------------------------------------------------------------
+$(onf-mk-lib)/include.mk:
+ @echo
+ @echo "** Checkout git submodule(s)"
+ @echo "** -----------------------------------------------------------------------"
+ git submodule update --init --recursive
+ @echo "** -----------------------------------------------------------------------"
+
+$(if $(DEBUG),$(warning LEAVE))
+
+# [EOF]
diff --git a/lf/local/include.mk b/lf/local/include.mk
new file mode 100644
index 0000000..1a9e5b3
--- /dev/null
+++ b/lf/local/include.mk
@@ -0,0 +1,37 @@
+# -*- makefile -*-
+# -----------------------------------------------------------------------
+# Copyright 2017-2024 Open Networking Foundation Contributors
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+# -----------------------------------------------------------------------
+# SPDX-FileCopyrightText: 2017-2024 Open Networking Foundation Contributors
+# SPDX-License-Identifier: Apache-2.0
+# -----------------------------------------------------------------------
+
+$(if $(DEBUG),$(warning ENTER))
+
+##-------------------##
+##---] GLOBALS [---##
+##-------------------##
+
+#--------------------##
+##---] INCLUDES [---##
+##--------------------##
+
+##-------------------##
+##---] TARGETS [---##
+##-------------------##
+
+$(if $(DEBUG),$(warning LEAVE))
+
+# [EOF]
diff --git a/lf/onf-make b/lf/onf-make
new file mode 160000
index 0000000..7ebfb1f
--- /dev/null
+++ b/lf/onf-make
@@ -0,0 +1 @@
+Subproject commit 7ebfb1f38c7461d35bc80ebdb3f8eac6b7e25ac3