From 8f749c1f021f372f70d3281b2a58e3296be63388 Mon Sep 17 00:00:00 2001 From: imi415 Date: Thu, 4 Feb 2021 02:08:44 +0800 Subject: [PATCH] Removed unused windows files, added CI configuration. --- .drone.yml | 12 +++++++ CMakeLists.txt | 4 --- build_all.bat | 43 ------------------------- build_all.sh | 59 +++++++++++++---------------------- build_debug.bat | 6 ---- build_flexspi_nor_debug.bat | 6 ---- build_flexspi_nor_release.bat | 6 ---- build_release.bat | 6 ---- build_sdram_debug.bat | 6 ---- build_sdram_release.bat | 6 ---- clean.bat | 3 -- 11 files changed, 33 insertions(+), 124 deletions(-) create mode 100644 .drone.yml delete mode 100644 build_all.bat delete mode 100644 build_debug.bat delete mode 100644 build_flexspi_nor_debug.bat delete mode 100644 build_flexspi_nor_release.bat delete mode 100644 build_release.bat delete mode 100644 build_sdram_debug.bat delete mode 100644 build_sdram_release.bat delete mode 100644 clean.bat diff --git a/.drone.yml b/.drone.yml new file mode 100644 index 0000000..2d3d500 --- /dev/null +++ b/.drone.yml @@ -0,0 +1,12 @@ +kind: pipeline +type: kubernetes +name: default + +steps: +- name: build + image: registry.aws.minori.work/imi415/arm-none-toolchain:latest + commands: + - bash build_all.sh + +image_pull_secrets: +- pull-secret diff --git a/CMakeLists.txt b/CMakeLists.txt index 505be10..be969e2 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -18,10 +18,6 @@ SET(CMAKE_EXECUTABLE_LIBRARY_SUFFIX) # CURRENT DIRECTORY SET(ProjDirPath ${CMAKE_CURRENT_SOURCE_DIR}) -SET(EXECUTABLE_OUTPUT_PATH ${ProjDirPath}/${CMAKE_BUILD_TYPE}) -SET(LIBRARY_OUTPUT_PATH ${ProjDirPath}/${CMAKE_BUILD_TYPE}) - - project(rt1050_freertos_hello) set(MCUX_SDK_PROJECT_NAME rt1050_rt1050_freertos_hello.elf) diff --git a/build_all.bat b/build_all.bat deleted file mode 100644 index 2df2e4e..0000000 --- a/build_all.bat +++ /dev/null @@ -1,43 +0,0 @@ -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=debug . -mingw32-make -j - -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=release . -mingw32-make -j - -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=sdram_debug . -mingw32-make -j - -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=sdram_release . -mingw32-make -j - -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=flexspi_nor_debug . -mingw32-make -j - -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=flexspi_nor_release . -mingw32-make -j - -IF "%1" == "" ( pause ) diff --git a/build_all.sh b/build_all.sh index c9416a4..afe1bb2 100644 --- a/build_all.sh +++ b/build_all.sh @@ -1,43 +1,26 @@ #!/bin/sh -if [ -d "CMakeFiles" ];then rm -rf CMakeFiles; fi -if [ -f "Makefile" ];then rm -f Makefile; fi -if [ -f "cmake_install.cmake" ];then rm -f cmake_install.cmake; fi -if [ -f "CMakeCache.txt" ];then rm -f CMakeCache.txt; fi -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=debug . -make -j -if [ -d "CMakeFiles" ];then rm -rf CMakeFiles; fi -if [ -f "Makefile" ];then rm -f Makefile; fi -if [ -f "cmake_install.cmake" ];then rm -f cmake_install.cmake; fi -if [ -f "CMakeCache.txt" ];then rm -f CMakeCache.txt; fi -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=release . -make -j +if [ ! -d "build" ]; then mkdir build; fi -if [ -d "CMakeFiles" ];then rm -rf CMakeFiles; fi -if [ -f "Makefile" ];then rm -f Makefile; fi -if [ -f "cmake_install.cmake" ];then rm -f cmake_install.cmake; fi -if [ -f "CMakeCache.txt" ];then rm -f CMakeCache.txt; fi -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=sdram_debug . -make -j +cd build -if [ -d "CMakeFiles" ];then rm -rf CMakeFiles; fi -if [ -f "Makefile" ];then rm -f Makefile; fi -if [ -f "cmake_install.cmake" ];then rm -f cmake_install.cmake; fi -if [ -f "CMakeCache.txt" ];then rm -f CMakeCache.txt; fi -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=sdram_release . -make -j - -if [ -d "CMakeFiles" ];then rm -rf CMakeFiles; fi -if [ -f "Makefile" ];then rm -f Makefile; fi -if [ -f "cmake_install.cmake" ];then rm -f cmake_install.cmake; fi -if [ -f "CMakeCache.txt" ];then rm -f CMakeCache.txt; fi -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=flexspi_nor_debug . -make -j - -if [ -d "CMakeFiles" ];then rm -rf CMakeFiles; fi -if [ -f "Makefile" ];then rm -f Makefile; fi -if [ -f "cmake_install.cmake" ];then rm -f cmake_install.cmake; fi -if [ -f "CMakeCache.txt" ];then rm -f CMakeCache.txt; fi -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=flexspi_nor_release . -make -j +TARGETS=( + "debug" + "release" + "sdram_debug" + "sdram_release" + "flexspi_nor_debug" + "flexspi_nor_release" +) +for TARGET in "${TARGETS[@]}" ; do + if [ -d "${TARGET}" ]; then rm -rf ${TARGET}; fi + mkdir ${TARGET} && cd ${TARGET} + if [ -d "CMakeFiles" ];then rm -rf CMakeFiles; fi + if [ -f "Makefile" ];then rm -f Makefile; fi + if [ -f "cmake_install.cmake" ];then rm -f cmake_install.cmake; fi + if [ -f "CMakeCache.txt" ];then rm -f CMakeCache.txt; fi + cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "Unix Makefiles" -DCMAKE_BUILD_TYPE=${TARGET} ../.. + make -j + cd .. +done diff --git a/build_debug.bat b/build_debug.bat deleted file mode 100644 index d46e34c..0000000 --- a/build_debug.bat +++ /dev/null @@ -1,6 +0,0 @@ -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=debug . -mingw32-make -j 2> build_log.txt diff --git a/build_flexspi_nor_debug.bat b/build_flexspi_nor_debug.bat deleted file mode 100644 index 5c2dbf3..0000000 --- a/build_flexspi_nor_debug.bat +++ /dev/null @@ -1,6 +0,0 @@ -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=flexspi_nor_debug . -mingw32-make -j diff --git a/build_flexspi_nor_release.bat b/build_flexspi_nor_release.bat deleted file mode 100644 index 7c4c211..0000000 --- a/build_flexspi_nor_release.bat +++ /dev/null @@ -1,6 +0,0 @@ -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=flexspi_nor_release . -mingw32-make -j diff --git a/build_release.bat b/build_release.bat deleted file mode 100644 index 75cfd88..0000000 --- a/build_release.bat +++ /dev/null @@ -1,6 +0,0 @@ -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=release . -mingw32-make -j diff --git a/build_sdram_debug.bat b/build_sdram_debug.bat deleted file mode 100644 index 2b41484..0000000 --- a/build_sdram_debug.bat +++ /dev/null @@ -1,6 +0,0 @@ -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=sdram_debug . -mingw32-make -j diff --git a/build_sdram_release.bat b/build_sdram_release.bat deleted file mode 100644 index fa07c40..0000000 --- a/build_sdram_release.bat +++ /dev/null @@ -1,6 +0,0 @@ -if exist CMakeFiles (RD /s /Q CMakeFiles) -if exist Makefile (DEL /s /Q /F Makefile) -if exist cmake_install.cmake (DEL /s /Q /F cmake_install.cmake) -if exist CMakeCache.txt (DEL /s /Q /F CMakeCache.txt) -cmake -DCMAKE_TOOLCHAIN_FILE="armgcc.cmake" -G "MinGW Makefiles" -DCMAKE_BUILD_TYPE=sdram_release . -mingw32-make -j diff --git a/clean.bat b/clean.bat deleted file mode 100644 index 0dcc6eb..0000000 --- a/clean.bat +++ /dev/null @@ -1,3 +0,0 @@ -RD /s /Q debug release sdram_debug sdram_release flexspi_nor_debug flexspi_nor_release CMakeFiles -DEL /s /Q /F Makefile cmake_install.cmake CMakeCache.txt -pause