Skip to content

Commit debade9

Browse files
marc-hbcarlescufi
authored andcommitted
tests: make find_package(Zephyr...) REQUIRED
... because it is (required). This makes a difference when building with CMake and forgetting ZEPHYR_BASE or not registering Zephyr in the CMake package registry. In this particular case, REQUIRED turns this harmless looking log statement: -- Could NOT find Zephyr (missing: Zephyr_DIR) -- The C compiler identification is GNU 9.3.0 -- The CXX compiler identification is GNU 9.3.0 -- Check for working C compiler: /usr/bin/cc -- ... -- ... -- ... -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at CMakeLists.txt:8 (target_sources): Cannot specify sources for target "app" which is not built by this project. ... into this louder, clearer, faster and (last but not least) final error: CMake Error at CMakeLists.txt:5 (find_package): Could not find a package configuration file provided by "Zephyr" with any of the following names: ZephyrConfig.cmake zephyr-config.cmake Add the installation prefix of "Zephyr" to CMAKE_PREFIX_PATH or set "Zephyr_DIR" to a directory containing one of the above files. If "Zephyr" provides a separate development package or SDK, be sure it has been installed. -- Configuring incomplete, errors occurred! Signed-off-by: Marc Herbert <marc.herbert@intel.com>
1 parent 32ebe3c commit debade9

File tree

275 files changed

+275
-275
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

275 files changed

+275
-275
lines changed

tests/application_development/cpp/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: Apache-2.0
22

33
cmake_minimum_required(VERSION 3.13.1)
4-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
4+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
55
project(cpp)
66

77
FILE(GLOB app_sources src/*.cpp)

tests/application_development/gen_inc_file/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: Apache-2.0
22

33
cmake_minimum_required(VERSION 3.13.1)
4-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
4+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
55
project(gen_inc_file)
66

77
FILE(GLOB app_sources src/*.c)

tests/application_development/libcxx/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: Apache-2.0
22

33
cmake_minimum_required(VERSION 3.13.1)
4-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
4+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
55
project(cpp)
66

77
FILE(GLOB app_sources src/*.cpp)

tests/arch/arm/arm_interrupt/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
cmake_minimum_required(VERSION 3.13.1)
44

5-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
5+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
66
project(arm_interrupt)
77

88
FILE(GLOB app_sources src/*.c)

tests/arch/arm/arm_irq_advanced_features/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
cmake_minimum_required(VERSION 3.13.1)
44

5-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
5+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
66
project(arm_zero_latency_irqs)
77

88
FILE(GLOB app_sources src/*.c)

tests/arch/arm/arm_irq_vector_table/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
cmake_minimum_required(VERSION 3.13.1)
44

5-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
5+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
66
project(arm_irq_vector_table)
77

88
FILE(GLOB app_sources src/*.c)

tests/arch/arm/arm_ramfunc/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
cmake_minimum_required(VERSION 3.13.1)
44

5-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
5+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
66
project(arm_zero_latency_irqs)
77

88
FILE(GLOB app_sources src/*.c)

tests/arch/arm/arm_runtime_nmi/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: Apache-2.0
22

33
cmake_minimum_required(VERSION 3.13.1)
4-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
4+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
55
project(arm_runtime_nmi)
66

77
FILE(GLOB app_sources src/*.c)

tests/arch/arm/arm_thread_swap/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: Apache-2.0
22

33
cmake_minimum_required(VERSION 3.13.1)
4-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
4+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
55
project(arm_swap)
66

77
FILE(GLOB app_sources src/*.c)

tests/arch/x86/boot_page_table/CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# SPDX-License-Identifier: Apache-2.0
22

33
cmake_minimum_required(VERSION 3.13.1)
4-
find_package(Zephyr HINTS $ENV{ZEPHYR_BASE})
4+
find_package(Zephyr REQUIRED HINTS $ENV{ZEPHYR_BASE})
55
project(boot_page_table)
66

77
FILE(GLOB app_sources src/*.c)

0 commit comments

Comments
 (0)