فهرست منبع

CMSIS-DSP: Added possibility to use reference library with test framework.

Christophe Favergeon 5 سال پیش
والد
کامیت
8a4db53f69
3فایلهای تغییر یافته به همراه23 افزوده شده و 2 حذف شده
  1. 7 1
      CMSIS/DSP/.gitignore
  2. 1 1
      CMSIS/DSP/Testing/.gitignore
  3. 15 0
      CMSIS/DSP/Testing/CMakeLists.txt

+ 7 - 1
CMSIS/DSP/.gitignore

@@ -4,4 +4,10 @@ PythonWrapper/cmsisdsp.cp36-win_amd64.pyd
 PythonWrapper/rec_2.dat
 Output.pickle
 build_*/
-
+Examples/ARM/arm_fft_bin_example/RTE/
+Examples/ARM/arm_fft_bin_example/RTE/
+Examples/ARM/arm_fft_bin_example/RTE/
+Examples/ARM/arm_linear_interp_example/RTE/
+Examples/ARM/arm_signal_converge_example/RTE/
+Examples/ARM/arm_svm_example/RTE/
+Projects/ARM/IntermediateFiles/

+ 1 - 1
CMSIS/DSP/Testing/.gitignore

@@ -16,4 +16,4 @@ test.txt
 __pycache__
 bugcheck.py
 fulltests/
-testUNIXrunConfig.yaml
+testUNIXrunConfig.yaml

+ 15 - 0
CMSIS/DSP/Testing/CMakeLists.txt

@@ -1,5 +1,7 @@
 cmake_minimum_required (VERSION 3.6)
 cmake_policy(SET CMP0077 NEW)
+include(CMakePrintHelpers)
+
 # The tests are assuming that MATRIX_CHECK is enabled when building
 # CMSIS-DSP.
 
@@ -69,6 +71,7 @@ endfunction()
 option(BENCHMARK "Benchmarking compiled" OFF)
 option(EXTBENCH "Benchmarking with external traces" OFF)
 option(NN "NN Tests included" OFF)
+option(REFLIB "Use already built reference lib" OFF)
 
 project(Testing)
 
@@ -84,7 +87,10 @@ set(ROOT ${CMAKE_CURRENT_SOURCE_DIR}/../../..)
 set(TESTFRAMEWORK ON)
 include(config)
 
+if (NOT REFLIB)
 add_subdirectory(../Source bin_dsp)
+endif()
+
 if (NN)
 add_subdirectory(${ROOT}/CMSIS/NN/Source bin_nn)
 endif()
@@ -260,7 +266,16 @@ if (EXTBENCH)
 endif()
 
 ### Includes
+if (REFLIB)
+list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/../Source)
+include(configDsp)
+SET(DSP ${ROOT}/CMSIS/DSP)
+target_include_directories(TestingLib PUBLIC "${DSP}/Include")
+target_link_libraries(TestingLib PRIVATE "${REFLIBNAME}")
+else()
 target_link_libraries(TestingLib PRIVATE CMSISDSP)
+endif()
+
 if(NN)
 target_link_libraries(TestingLib PRIVATE CMSISNN)
 endif()