First time Build failure

Hi team, I tried to build using following command, but got following errors.
Need help.

make px4_fmu-v5_default
– PX4 version: v1.11.0-rc3-1543-g59b31e3c5b
– PX4 config file: /home/tushar/PX4-Autopilot/boards/px4/fmu-v5/default.cmake
– PX4 config: px4_fmu-v5_default
– PX4 platform: nuttx
– cmake build type: MinSizeRel
– The CXX compiler identification is GNU 6.3.1
– The C compiler identification is GNU 6.3.1
– The ASM compiler identification is GNU
– Found assembler: /usr/bin/arm-none-eabi-gcc
– Check for working CXX compiler: /usr/bin/arm-none-eabi-g++
– Check for working CXX compiler: /usr/bin/arm-none-eabi-g++ – works
– Detecting CXX compiler ABI info
– Detecting CXX compiler ABI info - done
– Detecting CXX compile features
– Detecting CXX compile features - done
– Check for working C compiler: /usr/bin/arm-none-eabi-gcc
– Check for working C compiler: /usr/bin/arm-none-eabi-gcc – works
– Detecting C compiler ABI info
– Detecting C compiler ABI info - done
– Detecting C compile features
– Detecting C compile features - done
– Enabling double FP precision hardware instructions
– ccache enabled (export CCACHE_DISABLE=1 to disable)
– Found PythonInterp: /usr/bin/python3 (found suitable version “3.6.9”, minimum required is “3”)
– build type is MinSizeRel
– PX4 ECL: Very lightweight Estimation & Control Library v1.9.0-rc1-522-gffab483
– Building and including px4_io-v2_default
– Found PythonInterp: /usr/bin/python3 (found version “3.6.9”)
– Using C++11
– Release build type: MinSizeRel
– ROMFS: px4fmu_common
– ROMFS: Adding rc.board_defaults
– ROMFS: Adding rc.board_sensors
– ROMFS: Adding rc.board_mavlink
– Configuring done
– Generating done
– Build files have been written to: /home/tushar/PX4-Autopilot/build/px4_fmu-v5_default
[0/1471] git submodule platforms/nuttx/NuttX/nuttx
[2/1471] git submodule platforms/nuttx/NuttX/apps
[4/1471] git submodule src/lib/ecl
[12/1471] git submodule src/drivers/gps/devices
[15/1471] git submodule src/drivers/uavcan/libuavcan
[18/1471] git submodule mavlink/include/mavlink/v2.0
[21/1471] git submodule src/examples/gyro_fft/CMSIS_5
[812/1471] Building CXX object src/dri…h__bmi055.dir/BMI055_Gyroscope.cpp.obj
FAILED: src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Gyroscope.cpp.obj
/usr/bin/ccache /usr/bin/arm-none-eabi-g++ -DCONFIG_ARCH_BOARD_PX4_FMU_V5 -DMODULE_NAME=“bmi055” -DPX4_MAIN=bmi055_app_main -D_SYS_CDEFS_H_ -D_SYS_REENT_H_ -D__CUSTOM_FILE_IO__ -D__PX4_NUTTX -D__STDC_FORMAT_MACROS -I…/…/boards/px4/fmu-v5/src -I…/…/platforms/nuttx/src/px4/common/include -I. -Isrc/lib -I…/…/platforms/nuttx/src/px4/stm/stm32f7/include -I…/…/platforms/common/include -I…/…/src -I…/…/src/include -I…/…/src/lib -I…/…/src/lib/matrix -I…/…/src/modules -INuttX/nuttx/arch/arm/src/armv7-m -INuttX/nuttx/arch/arm/src/chip -INuttX/nuttx/arch/arm/src/common -INuttX/apps/include -Iexternal/Install/include -isystem …/…/platforms/nuttx/NuttX/include/cxx -isystem NuttX/nuttx/include/cxx -isystem NuttX/nuttx/include -mcpu=cortex-m7 -mthumb -mfpu=fpv5-d16 -mfloat-abi=hard -Os -DNDEBUG -g -fdata-sections -ffunction-sections -fomit-frame-pointer -fmerge-all-constants -fno-signed-zeros -fno-trapping-math -freciprocal-math -fno-math-errno -fno-strict-aliasing -fvisibility=hidden -include visibility.h -Wall -Wextra -Werror -Warray-bounds -Wcast-align -Wdisabled-optimization -Wdouble-promotion -Wfatal-errors -Wfloat-equal -Wformat-security -Winit-self -Wlogical-op -Wpointer-arith -Wshadow -Wuninitialized -Wunknown-pragmas -Wunused-variable -Wno-missing-field-initializers -Wno-missing-include-dirs -Wno-unused-parameter -fdiagnostics-color=auto -fno-builtin-printf -fno-strength-reduce -Wformat=1 -Wunused-but-set-variable -Wno-format-truncation -fcheck-new -fno-exceptions -fno-rtti -fno-threadsafe-statics -Wreorder -Wno-overloaded-virtual -nostdinc++ -fno-sized-deallocation -Wframe-larger-than=2048 -std=gnu++14 -MD -MT src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Gyroscope.cpp.obj -MF src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Gyroscope.cpp.obj.d -o src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Gyroscope.cpp.obj -c …/…/src/drivers/imu/bosch/bmi055/BMI055_Gyroscope.cpp
In file included from …/…/platforms/common/include/px4_platform_common/i2c_spi_buses.h:43:0,
from …/…/src/drivers/imu/bosch/bmi055/BMI055.hpp:39,
from …/…/src/drivers/imu/bosch/bmi055/BMI055_Gyroscope.hpp:36,
from …/…/src/drivers/imu/bosch/bmi055/BMI055_Gyroscope.cpp:34:
…/…/platforms/common/include/px4_platform_common/atomic.h: In instantiation of ‘bool px4::atomic::compare_exchange(T*, T) [with T = unsigned int]’:
…/…/src/drivers/imu/bosch/bmi055/BMI055_Gyroscope.cpp:326:71: required from here
…/…/platforms/common/include/px4_platform_common/atomic.h:169:34: error: parameter ‘expected’ set but not used [-Werror=unused-but-set-parameter]
inline bool compare_exchange(T *expected, T desired)
^~~~~~~~
compilation terminated due to -Wfatal-errors.
cc1plus: all warnings being treated as errors
[813/1471] Building CXX object src/dri…mi055.dir/BMI055_Accelerometer.cpp.obj
FAILED: src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Accelerometer.cpp.obj
/usr/bin/ccache /usr/bin/arm-none-eabi-g++ -DCONFIG_ARCH_BOARD_PX4_FMU_V5 -DMODULE_NAME=“bmi055” -DPX4_MAIN=bmi055_app_main -D_SYS_CDEFS_H_ -D_SYS_REENT_H_ -D__CUSTOM_FILE_IO__ -D__PX4_NUTTX -D__STDC_FORMAT_MACROS -I…/…/boards/px4/fmu-v5/src -I…/…/platforms/nuttx/src/px4/common/include -I. -Isrc/lib -I…/…/platforms/nuttx/src/px4/stm/stm32f7/include -I…/…/platforms/common/include -I…/…/src -I…/…/src/include -I…/…/src/lib -I…/…/src/lib/matrix -I…/…/src/modules -INuttX/nuttx/arch/arm/src/armv7-m -INuttX/nuttx/arch/arm/src/chip -INuttX/nuttx/arch/arm/src/common -INuttX/apps/include -Iexternal/Install/include -isystem …/…/platforms/nuttx/NuttX/include/cxx -isystem NuttX/nuttx/include/cxx -isystem NuttX/nuttx/include -mcpu=cortex-m7 -mthumb -mfpu=fpv5-d16 -mfloat-abi=hard -Os -DNDEBUG -g -fdata-sections -ffunction-sections -fomit-frame-pointer -fmerge-all-constants -fno-signed-zeros -fno-trapping-math -freciprocal-math -fno-math-errno -fno-strict-aliasing -fvisibility=hidden -include visibility.h -Wall -Wextra -Werror -Warray-bounds -Wcast-align -Wdisabled-optimization -Wdouble-promotion -Wfatal-errors -Wfloat-equal -Wformat-security -Winit-self -Wlogical-op -Wpointer-arith -Wshadow -Wuninitialized -Wunknown-pragmas -Wunused-variable -Wno-missing-field-initializers -Wno-missing-include-dirs -Wno-unused-parameter -fdiagnostics-color=auto -fno-builtin-printf -fno-strength-reduce -Wformat=1 -Wunused-but-set-variable -Wno-format-truncation -fcheck-new -fno-exceptions -fno-rtti -fno-threadsafe-statics -Wreorder -Wno-overloaded-virtual -nostdinc++ -fno-sized-deallocation -Wframe-larger-than=2048 -std=gnu++14 -MD -MT src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Accelerometer.cpp.obj -MF src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Accelerometer.cpp.obj.d -o src/drivers/imu/bosch/bmi055/CMakeFiles/drivers__imu__bosch__bmi055.dir/BMI055_Accelerometer.cpp.obj -c …/…/src/drivers/imu/bosch/bmi055/BMI055_Accelerometer.cpp
In file included from …/…/platforms/common/include/px4_platform_common/i2c_spi_buses.h:43:0,
from …/…/src/drivers/imu/bosch/bmi055/BMI055.hpp:39,
from …/…/src/drivers/imu/bosch/bmi055/BMI055_Accelerometer.hpp:36,
from …/…/src/drivers/imu/bosch/bmi055/BMI055_Accelerometer.cpp:34:
…/…/platforms/common/include/px4_platform_common/atomic.h: In instantiation of ‘bool px4::atomic::compare_exchange(T*, T) [with T = unsigned int]’:
…/…/src/drivers/imu/bosch/bmi055/BMI055_Accelerometer.cpp:328:71: required from here
…/…/platforms/common/include/px4_platform_common/atomic.h:169:34: error: parameter ‘expected’ set but not used [-Werror=unused-but-set-parameter]
inline bool compare_exchange(T *expected, T desired)
^~~~~~~~
compilation terminated due to -Wfatal-errors.
cc1plus: all warnings being treated as errors
[814/1471] Building CXX object src/dri…ensense__icm20602.dir/ICM20602.cpp.obj
FAILED: src/drivers/imu/invensense/icm20602/CMakeFiles/drivers__imu__invensense__icm20602.dir/ICM20602.cpp.obj
/usr/bin/ccache /usr/bin/arm-none-eabi-g++ -DCONFIG_ARCH_BOARD_PX4_FMU_V5 -DMODULE_NAME=“icm20602” -DPX4_MAIN=icm20602_app_main -D_SYS_CDEFS_H_ -D_SYS_REENT_H_ -D__CUSTOM_FILE_IO__ -D__PX4_NUTTX -D__STDC_FORMAT_MACROS -I…/…/boards/px4/fmu-v5/src -I…/…/platforms/nuttx/src/px4/common/include -I. -Isrc/lib -I…/…/platforms/nuttx/src/px4/stm/stm32f7/include -I…/…/platforms/common/include -I…/…/src -I…/…/src/include -I…/…/src/lib -I…/…/src/lib/matrix -I…/…/src/modules -INuttX/nuttx/arch/arm/src/armv7-m -INuttX/nuttx/arch/arm/src/chip -INuttX/nuttx/arch/arm/src/common -INuttX/apps/include -Iexternal/Install/include -isystem …/…/platforms/nuttx/NuttX/include/cxx -isystem NuttX/nuttx/include/cxx -isystem NuttX/nuttx/include -mcpu=cortex-m7 -mthumb -mfpu=fpv5-d16 -mfloat-abi=hard -Os -DNDEBUG -g -fdata-sections -ffunction-sections -fomit-frame-pointer -fmerge-all-constants -fno-signed-zeros -fno-trapping-math -freciprocal-math -fno-math-errno -fno-strict-aliasing -fvisibility=hidden -include visibility.h -Wall -Wextra -Werror -Warray-bounds -Wcast-align -Wdisabled-optimization -Wdouble-promotion -Wfatal-errors -Wfloat-equal -Wformat-security -Winit-self -Wlogical-op -Wpointer-arith -Wshadow -Wuninitialized -Wunknown-pragmas -Wunused-variable -Wno-missing-field-initializers -Wno-missing-include-dirs -Wno-unused-parameter -fdiagnostics-color=auto -fno-builtin-printf -fno-strength-reduce -Wformat=1 -Wunused-but-set-variable -Wno-format-truncation -fcheck-new -fno-exceptions -fno-rtti -fno-threadsafe-statics -Wreorder -Wno-overloaded-virtual -nostdinc++ -fno-sized-deallocation -Wframe-larger-than=2048 -std=gnu++14 -MD -MT src/drivers/imu/invensense/icm20602/CMakeFiles/drivers__imu__invensense__icm20602.dir/ICM20602.cpp.obj -MF src/drivers/imu/invensense/icm20602/CMakeFiles/drivers__imu__invensense__icm20602.dir/ICM20602.cpp.obj.d -o src/drivers/imu/invensense/icm20602/CMakeFiles/drivers__imu__invensense__icm20602.dir/ICM20602.cpp.obj -c …/…/src/drivers/imu/invensense/icm20602/ICM20602.cpp
In file included from …/…/platforms/common/include/px4_platform_common/atomic_bitset.h:36:0,
from …/…/src/modules/uORB/uORBDeviceMaster.hpp:54,
from …/…/src/modules/uORB/uORBDeviceNode.hpp:37,
from …/…/src/modules/uORB/PublicationMulti.hpp:44,
from …/…/src/lib/drivers/accelerometer/PX4Accelerometer.hpp:39,
from …/…/src/drivers/imu/invensense/icm20602/ICM20602.hpp:46,
from …/…/src/drivers/imu/invensense/icm20602/ICM20602.cpp:34:
…/…/platforms/common/include/px4_platform_common/atomic.h: In instantiation of ‘bool px4::atomic::compare_exchange(T*, T) [with T = unsigned int]’:
…/…/src/drivers/imu/invensense/icm20602/ICM20602.cpp:406:76: required from here
…/…/platforms/common/include/px4_platform_common/atomic.h:169:34: error: parameter ‘expected’ set but not used [-Werror=unused-but-set-parameter]
inline bool compare_exchange(T *expected, T desired)
^~~~~~~~
compilation terminated due to -Wfatal-errors.
cc1plus: all warnings being treated as errors
[815/1471] Building CXX object src/dri…ensense__icm20689.dir/ICM20689.cpp.obj
FAILED: src/drivers/imu/invensense/icm20689/CMakeFiles/drivers__imu__invensense__icm20689.dir/ICM20689.cpp.obj
/usr/bin/ccache /usr/bin/arm-none-eabi-g++ -DCONFIG_ARCH_BOARD_PX4_FMU_V5 -DMODULE_NAME=“icm20689” -DPX4_MAIN=icm20689_app_main -D_SYS_CDEFS_H_ -D_SYS_REENT_H_ -D__CUSTOM_FILE_IO__ -D__PX4_NUTTX -D__STDC_FORMAT_MACROS -I…/…/boards/px4/fmu-v5/src -I…/…/platforms/nuttx/src/px4/common/include -I. -Isrc/lib -I…/…/platforms/nuttx/src/px4/stm/stm32f7/include -I…/…/platforms/common/include -I…/…/src -I…/…/src/include -I…/…/src/lib -I…/…/src/lib/matrix -I…/…/src/modules -INuttX/nuttx/arch/arm/src/armv7-m -INuttX/nuttx/arch/arm/src/chip -INuttX/nuttx/arch/arm/src/common -INuttX/apps/include -Iexternal/Install/include -isystem …/…/platforms/nuttx/NuttX/include/cxx -isystem NuttX/nuttx/include/cxx -isystem NuttX/nuttx/include -mcpu=cortex-m7 -mthumb -mfpu=fpv5-d16 -mfloat-abi=hard -Os -DNDEBUG -g -fdata-sections -ffunction-sections -fomit-frame-pointer -fmerge-all-constants -fno-signed-zeros -fno-trapping-math -freciprocal-math -fno-math-errno -fno-strict-aliasing -fvisibility=hidden -include visibility.h -Wall -Wextra -Werror -Warray-bounds -Wcast-align -Wdisabled-optimization -Wdouble-promotion -Wfatal-errors -Wfloat-equal -Wformat-security -Winit-self -Wlogical-op -Wpointer-arith -Wshadow -Wuninitialized -Wunknown-pragmas -Wunused-variable -Wno-missing-field-initializers -Wno-missing-include-dirs -Wno-unused-parameter -fdiagnostics-color=auto -fno-builtin-printf -fno-strength-reduce -Wformat=1 -Wunused-but-set-variable -Wno-format-truncation -fcheck-new -fno-exceptions -fno-rtti -fno-threadsafe-statics -Wreorder -Wno-overloaded-virtual -nostdinc++ -fno-sized-deallocation -Wframe-larger-than=2048 -std=gnu++14 -MD -MT src/drivers/imu/invensense/icm20689/CMakeFiles/drivers__imu__invensense__icm20689.dir/ICM20689.cpp.obj -MF src/drivers/imu/invensense/icm20689/CMakeFiles/drivers__imu__invensense__icm20689.dir/ICM20689.cpp.obj.d -o src/drivers/imu/invensense/icm20689/CMakeFiles/drivers__imu__invensense__icm20689.dir/ICM20689.cpp.obj -c …/…/src/drivers/imu/invensense/icm20689/ICM20689.cpp
In file included from …/…/platforms/common/include/px4_platform_common/atomic_bitset.h:36:0,
from …/…/src/modules/uORB/uORBDeviceMaster.hpp:54,
from …/…/src/modules/uORB/uORBDeviceNode.hpp:37,
from …/…/src/modules/uORB/PublicationMulti.hpp:44,
from …/…/src/lib/drivers/accelerometer/PX4Accelerometer.hpp:39,
from …/…/src/drivers/imu/invensense/icm20689/ICM20689.hpp:46,
from …/…/src/drivers/imu/invensense/icm20689/ICM20689.cpp:34:
…/…/platforms/common/include/px4_platform_common/atomic.h: In instantiation of ‘bool px4::atomic::compare_exchange(T*, T) [with T = unsigned int]’:
…/…/src/drivers/imu/invensense/icm20689/ICM20689.cpp:382:79: required from here
…/…/platforms/common/include/px4_platform_common/atomic.h:169:34: error: parameter ‘expected’ set but not used [-Werror=unused-but-set-parameter]
inline bool compare_exchange(T *expected, T desired)
^~~~~~~~
compilation terminated due to -Wfatal-errors.
cc1plus: all warnings being treated as errors
[817/1471] Performing configure step for ‘px4io_firmware’
– PX4 version: v1.11.0-rc3-1543-g59b31e3c5b
– PX4 config file: /home/tushar/PX4-Autopilot/boards/px4/io-v2/default.cmake
– PX4 config: px4_io-v2_default
– PX4 platform: nuttx
– cmake build type: MinSizeRel
– The CXX compiler identification is GNU 6.3.1
– The C compiler identification is GNU 6.3.1
– The ASM compiler identification is GNU
– Found assembler: /usr/bin/arm-none-eabi-gcc
– Check for working CXX compiler: /usr/bin/arm-none-eabi-g++
– Check for working CXX compiler: /usr/bin/arm-none-eabi-g++ – works
– Detecting CXX compiler ABI info
– Detecting CXX compiler ABI info - done
– Detecting CXX compile features
– Detecting CXX compile features - done
– Check for working C compiler: /usr/bin/arm-none-eabi-gcc
– Check for working C compiler: /usr/bin/arm-none-eabi-gcc – works
– Detecting C compiler ABI info
– Detecting C compiler ABI info - done
– Detecting C compile features
– Detecting C compile features - done
– ccache enabled (export CCACHE_DISABLE=1 to disable)
– Found PythonInterp: /usr/bin/python3 (found suitable version “3.6.9”, minimum required is “3”)
– build type is MinSizeRel
– PX4 ECL: Very lightweight Estimation & Control Library v1.9.0-rc1-522-gffab483
– Configuring done
– Generating done
– Build files have been written to: /home/tushar/PX4-Autopilot/build/px4_fmu-v5_default/external/Build/px4io_firmware
ninja: build stopped: subcommand failed.

Hi @shawngrimm,

Which OS are you using? Have you followed this: https://docs.px4.io/master/en/dev_setup/dev_env.html#development-environment ?

Hi @bresch

Yes I followed that.
I am using Linux 18.04