summaryrefslogtreecommitdiff
path: root/examples/device/mtp
diff options
context:
space:
mode:
Diffstat (limited to 'examples/device/mtp')
-rw-r--r--examples/device/mtp/CMakeLists.txt9
1 files changed, 3 insertions, 6 deletions
diff --git a/examples/device/mtp/CMakeLists.txt b/examples/device/mtp/CMakeLists.txt
index e91eb8fd9..a9f2f1a90 100644
--- a/examples/device/mtp/CMakeLists.txt
+++ b/examples/device/mtp/CMakeLists.txt
@@ -2,13 +2,10 @@ cmake_minimum_required(VERSION 3.20)
include(${CMAKE_CURRENT_SOURCE_DIR}/../../../hw/bsp/family_support.cmake)
-# gets PROJECT name for the example (e.g. <BOARD>-<DIR_NAME>)
-family_get_project_name(PROJECT ${CMAKE_CURRENT_LIST_DIR})
-
-project(${PROJECT} C CXX ASM)
+project(mtp C CXX ASM)
# Checks this example is valid for the family and initializes the project
-family_initialize_project(${PROJECT} ${CMAKE_CURRENT_LIST_DIR})
+family_initialize_project(${PROJECT_NAME} ${CMAKE_CURRENT_LIST_DIR})
# Espressif has its own cmake build system
if(FAMILY STREQUAL "espressif")
@@ -18,7 +15,7 @@ endif()
if (RTOS STREQUAL zephyr)
set(EXE_NAME app)
else()
- set(EXE_NAME ${PROJECT})
+ set(EXE_NAME ${PROJECT_NAME})
add_executable(${EXE_NAME})
endif()