Assembly description has been moved to a separate file
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
cmake_minimum_required(VERSION 3.0)
|
||||
project(jlv135_cli C)
|
||||
|
||||
if(CMAKE_BUILD_TYPE STREQUAL "Release")
|
||||
option(BUILD_FOR_JLV135 "Build for JLV135 firmware" ON)
|
||||
|
||||
if (BUILD_FOR_JLV135)
|
||||
# Настройка кросс-компиляции
|
||||
set(CMAKE_SYSTEM_NAME Linux)
|
||||
set(CMAKE_C_COMPILER arm-uclinuxfdpiceabi-gcc)
|
||||
@@ -25,12 +27,14 @@ target_link_libraries(${CMAKE_PROJECT_NAME} pthread)
|
||||
target_include_directories(${CMAKE_PROJECT_NAME} PRIVATE
|
||||
inc)
|
||||
|
||||
# Опция strip
|
||||
if(CMAKE_BUILD_TYPE STREQUAL "Release")
|
||||
add_custom_command(
|
||||
TARGET ${CMAKE_PROJECT_NAME} POST_BUILD
|
||||
COMMAND ${CMAKE_STRIP} $<TARGET_FILE:${CMAKE_PROJECT_NAME}>
|
||||
COMMENT "Stripping debug symbols (Release only)"
|
||||
DEPENDS $<TARGET_FILE:${CMAKE_PROJECT_NAME}>
|
||||
)
|
||||
if (BUILD_FOR_JLV135)
|
||||
# Опция strip
|
||||
if(CMAKE_BUILD_TYPE STREQUAL "Release")
|
||||
add_custom_command(
|
||||
TARGET ${CMAKE_PROJECT_NAME} POST_BUILD
|
||||
COMMAND ${CMAKE_STRIP} $<TARGET_FILE:${CMAKE_PROJECT_NAME}>
|
||||
COMMENT "Stripping debug symbols (Release only)"
|
||||
DEPENDS $<TARGET_FILE:${CMAKE_PROJECT_NAME}>
|
||||
)
|
||||
endif()
|
||||
endif()
|
||||
Reference in New Issue
Block a user