1# SPDX-License-Identifier: Apache-2.0
2
3######################################
4# The use of this file is deprecated #
5######################################
6
7# To build a Zephyr application it must start with one of those lines:
8#
9# find_package(Zephyr)
10# find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
11#
12# The `REQUIRED HINTS $ENV{ZEPHYR_BASE}` variant is required for any application
13# inside the Zephyr repository.
14#
15# Loading of this file directly is deprecated and only kept for backward compatibility.
16
17if(NOT DEFINED Zephyr_DIR)
18  # When `find_package(Zephyr)` is used then `Zephyr_DIR` is defined, else
19  # old style inclusion is used. Warning is only printed in first invocation.
20  message(WARNING "Loading of Zephyr boilerplate.cmake directly is deprecated, "
21          "please use 'find_package(Zephyr)'"
22  )
23endif()
24
25find_package(Zephyr REQUIRED PATHS ${CMAKE_CURRENT_LIST_DIR}/../.. NO_DEFAULT_PATH)
26