I'm trying to build rtos c sample from dji psdk here but I messed around with CmakeLists.txt. Here is what I've tried :
goto armgcc folder (contain CMakeLists.txt) run cmake -G "Unix Makefiles" toget an makefile (I don't know if it's good)
CMake Warning:
No source or binary directory provided. Both will be assumed to be the
same as the current working directory, but note that this warning will
become a fatal error in future CMake releases.
-- The C compiler identification is GNU 11.4.0
-- The CXX compiler identification is GNU 11.4.0
-- The ASM compiler identification is GNU
-- Found assembler: /usr/lib/ccache/cc
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/lib/ccache/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/lib/ccache/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Minimal optimization, debug info included
-- Use payload sdk package
-- Configuring done
-- Generating done
-- Build files have been written to: /home/sim/Téléchargements/Payload-SDK-master/samples/sample_c/platform/rtos_freertos/stm32f4_discovery/project/armgcc
After that I've tried make to build :
Scanning dependencies of target dji_sdk_demo_rtos.elf
[ 1%] Building C object CMakeFiles/dji_sdk_demo_rtos.elf.dir/home/sim/Téléchargements/Payload-SDK-master/samples/sample_c/platform/rtos_freertos/common/osal/osal.c.obj
cc: warning: ‘-mcpu=’ is deprecated; use ‘-mtune=’ or ‘-march=’ instead
cc: error: unrecognized command-line option ‘-mfloat-abi=hard’
cc: error: unrecognized command-line option ‘-mfpu=fpv4-sp-d16’
cc: error: unrecognized command-line option ‘-mthumb’
cc: error: unrecognized command-line option ‘-mthumb-interwork’
make[2]: *** [CMakeFiles/dji_sdk_demo_rtos.elf.dir/build.make:76 : CMakeFiles/dji_sdk_demo_rtos.elf.dir/home/sim/Téléchargements/Payload-SDK-master/samples/sample_c/platform/rtos_freertos/common/osal/osal.c.obj] Erreur 1
make[1]: *** [CMakeFiles/Makefile2:83 : CMakeFiles/dji_sdk_demo_rtos.elf.dir/all] Erreur 2
make: *** [Makefile:91 : all] Erreur 2
I want to build the sample for the dev board stm32f4. It's look like if the compiler used is not arm-none-eabi-gcc, is someone has already build psdk from command line with armgcc ?