Okay so there are two pythons as you said.
where python
gave me
C:\cygwin64\bin\python
C:\Users\zinvi\AppData\Local\Microsoft\WindowsApps\python.exe
The output of ./waf configure --board=MatekF405-STD
on cygwin terminal gives:
$ ./waf configure --board=MatekF405-STD
Setting top to : /cygdrive/c/Users/zinvi/Documents/github/ardupilot
Setting out to : /cygdrive/c/Users/zinvi/Documents/github/ardupilot/build
Autoconfiguration : enabled
Setting board to : MatekF405-STD
Using toolchain : arm-none-eabi
Checking for 'g++' (C++ compiler) : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-g++
Checking for 'gcc' (C compiler) : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-gcc
Checking for c flags '-MMD' : yes
Checking for cxx flags '-MMD' : yes
CXX Compiler : g++ 10.2.1
Checking for program 'make' : /usr/bin/make
Checking for program 'arm-none-eabi-objcopy' : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-objcopy
Including /cygdrive/c/Users/zinvi/Documents/github/ardupilot/libraries/AP_HAL_ChibiOS/hwdef/MatekF405/hwdef.dat
Removing IMU
Setup for MCU STM32F405xx
Writing hwdef setup in /cygdrive/c/Users/zinvi/Documents/github/ardupilot/build/MatekF405-STD/hwdef.h
Writing DMA map
Generating ldscript.ld
No default parameter file found
Checking for env.py
env set WITH_FATFS=1
env set PROCESS_STACK=0x1C00
env set MAIN_STACK=0x600
env set IOMCU_FW=0
env set PERIPH_FW=0
env set BOARD_FLASH_SIZE=1024
env set EXTERNAL_PROG_FLASH_MB=0
env set CPU_FLAGS=['-mcpu=cortex-m4', '-mfpu=fpv4-sp-d16', '-mfloat-abi=hard', '-DARM_MATH_CM4', '-u_printf_float']
env set CORTEX=cortex-m4
env set APJ_BOARD_ID=125
env set APJ_BOARD_TYPE=STM32F405xx
env set USBID=0x1209/0x5741
env set BOOTLOADER_EMBED=1
env set FLASH_RESERVE_START_KB=64
env set FLASH_TOTAL=983040
env set HAS_EXTERNAL_FLASH_SECTIONS=0
env set CHIBIOS_BUILD_FLAGS=USE_FATFS=yes CHIBIOS_STARTUP_MK=os/common/startup/ARMCMx/compilers/GCC/mk/startup_stm32f4xx.mk CHIBIOS_PLATFORM_MK=os/hal/ports/STM32/STM32F4xx/platform.mk MCU=cortex-m4 ENV_UDEFS=-DCHPRINTF_USE_FLOAT=1
Enabling ChibiOS asserts : no
Disabling Watchdog : no
Enabling malloc guard : no
Enabling ChibiOS thread statistics : no
Enabling -Werror : yes
Checking for intelhex module: : disabled
Checking for HAVE_CMATH_ISFINITE : no
Checking for HAVE_CMATH_ISINF : no
Checking for HAVE_CMATH_ISNAN : no
Checking for NEED_CMATH_ISFINITE_STD_NAMESPACE : no
Checking for NEED_CMATH_ISINF_STD_NAMESPACE : no
Checking for NEED_CMATH_ISNAN_STD_NAMESPACE : no
Checking for header endian.h : not found
Checking for header byteswap.h : not found
Checking for HAVE_MEMRCHR : no
Configured VSCode Intellisense: : no
Checking for program 'python' : /usr/bin/python
Checking for python version >= 2.7.0 : 3.8.10
Checking for program 'python' : /usr/bin/python
Checking for python version >= 2.7.0 : 3.8.10
Source is git repository : yes
Update submodules : yes
Checking for program 'git' : /usr/bin/git
Gtest : STM32 boards currently don't support compiling gtest
Checking for program 'arm-none-eabi-size' : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-size
Benchmarks : disabled
Unit tests : disabled
Scripting : disabled
Scripting runtime checks : enabled
Debug build : disabled
Coverage build : disabled
SITL 32-bit build : disabled
Checking for program 'rsync' : /usr/bin/rsync
'configure' finished successfully (9.480s)
The output of ./waf configure --board=MatekF405-STD
on Eclipse is slightly different though (python directories and versions are different plus intelhex is disabled on cygwin for some reason):
12:17:35 **** Build of configuration Default for project ardupilot ****
"c:\\cygwin64\\bin\\python3.7m" waf -j8 configure --board=MatekF405-STD
Setting top to : /cygdrive/c/Users/zinvi/Documents/github/ardupilot
Setting out to : /cygdrive/c/Users/zinvi/Documents/github/ardupilot/build
Autoconfiguration : enabled
Setting board to : MatekF405-STD
Using toolchain : arm-none-eabi
Checking for 'g++' (C++ compiler) : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-g++
Checking for 'gcc' (C compiler) : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-gcc
Checking for c flags '-MMD' : yes
Checking for cxx flags '-MMD' : yes
CXX Compiler : g++ 10.2.1
Checking for program 'make' : /usr/bin/make
Checking for program 'arm-none-eabi-objcopy' : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-objcopy
Including /cygdrive/c/Users/zinvi/Documents/github/ardupilot/libraries/AP_HAL_ChibiOS/hwdef/MatekF405/hwdef.dat
Removing IMU
Setup for MCU STM32F405xx
Writing hwdef setup in /cygdrive/c/Users/zinvi/Documents/github/ardupilot/build/MatekF405-STD/hwdef.h
Writing DMA map
Generating ldscript.ld
No default parameter file found
Checking for env.py
env set WITH_FATFS=1
env set PROCESS_STACK=0x1C00
env set MAIN_STACK=0x600
env set IOMCU_FW=0
env set PERIPH_FW=0
env set BOARD_FLASH_SIZE=1024
env set EXTERNAL_PROG_FLASH_MB=0
env set CPU_FLAGS=['-mcpu=cortex-m4', '-mfpu=fpv4-sp-d16', '-mfloat-abi=hard', '-DARM_MATH_CM4', '-u_printf_float']
env set CORTEX=cortex-m4
env set APJ_BOARD_ID=125
env set APJ_BOARD_TYPE=STM32F405xx
env set USBID=0x1209/0x5741
env set BOOTLOADER_EMBED=1
env set FLASH_RESERVE_START_KB=64
env set FLASH_TOTAL=983040
env set HAS_EXTERNAL_FLASH_SECTIONS=0
env set CHIBIOS_BUILD_FLAGS=USE_FATFS=yes CHIBIOS_STARTUP_MK=os/common/startup/ARMCMx/compilers/GCC/mk/startup_stm32f4xx.mk CHIBIOS_PLATFORM_MK=os/hal/ports/STM32/STM32F4xx/platform.mk MCU=cortex-m4 ENV_UDEFS=-DCHPRINTF_USE_FLOAT=1
Enabling ChibiOS asserts : no
Disabling Watchdog : no
Enabling malloc guard : no
Enabling ChibiOS thread statistics : no
Enabling -Werror : yes
Checking for intelhex module: : OK
Checking for HAVE_CMATH_ISFINITE : no
Checking for HAVE_CMATH_ISINF : no
Checking for HAVE_CMATH_ISNAN : no
Checking for NEED_CMATH_ISFINITE_STD_NAMESPACE : no
Checking for NEED_CMATH_ISINF_STD_NAMESPACE : no
Checking for NEED_CMATH_ISNAN_STD_NAMESPACE : no
Checking for header endian.h : not found
Checking for header byteswap.h : not found
Checking for HAVE_MEMRCHR : no
Configured VSCode Intellisense: : no
Checking for program 'python' : /usr/bin/python3.7m.exe
Checking for python version >= 2.7.0 : 3.7.10
Checking for program 'python' : /usr/bin/python3.7m.exe
Checking for python version >= 2.7.0 : 3.7.10
Source is git repository : yes
Update submodules : yes
Checking for program 'git' : /usr/bin/git
Gtest : STM32 boards currently don't support compiling gtest
Checking for program 'arm-none-eabi-size' : /cygdrive/c/Program Files (x86)/GNU Arm Embedded Toolchain/10 2020-q4-major/bin/arm-none-eabi-size
Benchmarks : disabled
Unit tests : disabled
Scripting : disabled
Scripting runtime checks : enabled
Debug build : disabled
Coverage build : disabled
SITL 32-bit build : disabled
Checking for program 'rsync' : /usr/bin/rsync
'configure' finished successfully (8.608s)
12:17:45 Build Finished. 0 errors, 0 warnings. (took 10s.519ms)
I should also mention I can build arducopter.bin with Eclipse fine no errors (just not the ‘with_bl.hex’ i need). But when running ./waf copter
in cygwin I don’t and get the following error:
$ ./waf copter
Waf: Entering directory `/cygdrive/c/Users/zinvi/Documents/github/ardupilot/build/MatekF405-STD'
Checking for env.py
env added WITH_FATFS=1
env added PROCESS_STACK=0x1C00
env added MAIN_STACK=0x600
env added IOMCU_FW=0
env added PERIPH_FW=0
env added BOARD_FLASH_SIZE=1024
env added EXTERNAL_PROG_FLASH_MB=0
env appended CPU_FLAGS=['-mcpu=cortex-m4', '-mfpu=fpv4-sp-d16', '-mfloat-abi=hard', '-DARM_MATH_CM4', '-u_printf_float']
env added CORTEX=cortex-m4
env added APJ_BOARD_ID=125
env added APJ_BOARD_TYPE=STM32F405xx
env added USBID=0x1209/0x5741
env added BOOTLOADER_EMBED=1
env added FLASH_RESERVE_START_KB=64
env added FLASH_TOTAL=983040
env added HAS_EXTERNAL_FLASH_SECTIONS=0
env added CHIBIOS_BUILD_FLAGS=USE_FATFS=yes CHIBIOS_STARTUP_MK=os/common/startup/ARMCMx/compilers/GCC/mk/startup_stm32f4xx.mk CHIBIOS_PLATFORM_MK=os/hal/ports/STM32/STM32F4xx/platform.mk MCU=cortex-m4 ENV_UDEFS=-DCHPRINTF_USE_FLOAT=1
Padded 16 bytes for bootloader.bin to 14176
Embedding file bootloader.bin:/cygdrive/c/Users/zinvi/Documents/github/ardupilot/Tools/bootloaders/MatekF405-STD_bl.bin
Embedding file font0.bin:libraries/AP_OSD/fonts/font0.bin
Embedding file hwdef.dat:/cygdrive/c/Users/zinvi/Documents/github/ardupilot/build/MatekF405-STD/hw.dat
[3/9] Creating build/MatekF405-STD/hwdef.h
[4/9] Creating build/MatekF405-STD/modules/ChibiOS/include_dirs
[5/9] Compiling libraries/AP_Scripting/generator/src/main.c
[6/9] Processing modules/mavlink/message_definitions/v1.0/ardupilotmega.xml
[7/9] Creating build/MatekF405-STD/ap_version.h
Including /cygdrive/c/Users/zinvi/Documents/github/ardupilot/libraries/AP_HAL_ChibiOS/hwdef/MatekF405/hwdef.dat
Removing IMU
Setup for MCU STM32F405xx
Writing hwdef setup in /cygdrive/c/Users/zinvi/Documents/github/ardupilot/build/MatekF405-STD/hwdef.h
Writing DMA map
Generating ldscript.ld
No default parameter file found
Waf: Leaving directory `/cygdrive/c/Users/zinvi/Documents/github/ardupilot/build/MatekF405-STD'
Build failed
Traceback (most recent call last):
File "/cygdrive/c/Users/zinvi/Documents/github/ardupilot/modules/waf/waflib/Task.py", line 348, in process
ret = self.run()
File "/cygdrive/c/Users/zinvi/Documents/github/ardupilot/Tools/ardupilotwaf/mavgen.py", line 55, in run
from pymavlink.generator import mavgen
File "/cygdrive/c/Users/zinvi/Documents/github/ardupilot/modules/mavlink/pymavlink/generator/mavgen.py", line 26, in <module>
from future import standard_library
ModuleNotFoundError: No module named 'future'
Don’t know if that helps but thought I should include