From 5a7d989fcd3106c55a43dec677faeb40cbb1b3b7 Mon Sep 17 00:00:00 2001 From: GongT Date: Wed, 29 May 2019 20:13:15 +0800 Subject: [PATCH] update for IDE --- cmake/ide.cmake | 7 +++++ kendryte-package.json | 73 ++++++++++++++++++++++++++++++++++++++++++++++++--- package.json | 6 +++++ 3 files changed, 82 insertions(+), 4 deletions(-) create mode 100644 cmake/ide.cmake create mode 100644 package.json diff --git a/cmake/ide.cmake b/cmake/ide.cmake new file mode 100644 index 0000000..0c3db5f --- /dev/null +++ b/cmake/ide.cmake @@ -0,0 +1,7 @@ +FILE(GLOB_RECURSE ASSEMBLY_FILES + "${CMAKE_CURRENT_LIST_DIR}/*.s" + "${CMAKE_CURRENT_LIST_DIR}/*.S" +) + +SET_PROPERTY(SOURCE ${ASSEMBLY_FILES} PROPERTY LANGUAGE C) +SET_SOURCE_FILES_PROPERTIES(${ASSEMBLY_FILES} PROPERTIES COMPILE_FLAGS "-x assembler-with-cpp -D __riscv64") diff --git a/kendryte-package.json b/kendryte-package.json index d56a8b6..6c6237b 100644 --- a/kendryte-package.json +++ b/kendryte-package.json @@ -1,6 +1,71 @@ { - "name": "framework-kendryte210-standalone-sdk", - "description": "This SDK is for Kendryte K210 without OS support.", - "version": "0.5.4", - "url": "https://github.com/kendryte/kendryte-standalone-sdk" + "$schema": "vscode://schemas/CMakeLists", + "name": "kendryte-standalone-sdk", + "version": "develop", + "type": "library", + "extraList": "cmake/ide.cmake", + "include": [ + "lib/drivers/include", + "lib/bsp/include", + "lib/utils/include", + "lib/freertos/include", + "lib/freertos/conf", + "lib/freertos/portable" + ], + "source": [ + "lib/**/*.c", + "lib/**/*.cpp", + "lib/**/*.s", + "lib/**/*.S" + ], + "c_flags": [ + "-std=gnu11", + "-Wno-pointer-to-int-cast", + "-Wno-old-style-declaration" + ], + "cpp_flags": [ + "-std=gnu++17" + ], + "c_cpp_flags": [ + "-mcmodel=medany", + "-fno-common", + "-ffunction-sections", + "-fdata-sections", + "-fstrict-volatile-bitfields", + "-fno-zero-initialized-in-bss", + "-Os", + "-ggdb", + "-Wall", + "-Werror=all", + "-Wno-error=unused-function", + "-Wno-error=unused-but-set-variable", + "-Wno-error=unused-variable", + "-Wno-error=deprecated-declarations", + "-Wextra", + "-Werror=frame-larger-than=65536", + "-Wno-unused-parameter", + "-Wno-sign-compare", + "-Wno-error=missing-braces", + "-Wno-error=return-type", + "-Wno-error=pointer-sign", + "-Wno-missing-braces", + "-Wno-strict-aliasing", + "-Wno-implicit-fallthrough", + "-Wno-missing-field-initializers" + ], + "link_flags": [ + "-static", + "-Wl,-static", + "-Wl,-EL" + ], + "ld_file": "lds/kendryte.ld", + "properties": { + "LINKER_LANGUAGE": "C" + }, + "__random": "74211554725553837", + "systemLibrary": [ + "gcc", + "m", + "c" + ] } diff --git a/package.json b/package.json new file mode 100644 index 0000000..d56a8b6 --- /dev/null +++ b/package.json @@ -0,0 +1,6 @@ +{ + "name": "framework-kendryte210-standalone-sdk", + "description": "This SDK is for Kendryte K210 without OS support.", + "version": "0.5.4", + "url": "https://github.com/kendryte/kendryte-standalone-sdk" +}