mangOH Yellow WP77 Build Fails

I configured my system as described here:

The command-line build fails:

[1278/1345] Running external build step
FAILED: bluezDBusExternalBuild_line0
cd /home/awn/le-wsp/mangOH/build/yellow_wp77xx/component/04edc864bff17962d539a13ab07d1878 && export CFLAGS="--sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi -O2 -DSIERRA_MDM9X28 -DSIERRA_WP76XX -DPCM_IF=SEC_AUX -DI2S_IF=SEC_MI2S -DUSB_IF=AFE_PCM -DCODEC_IF=PRI_MI2S -DMM_1_ALSA_MIXER_CTRL=MultiMedia1 -DMM_1_ALSA_PCM_DEVICE_ID=0 -DMM_2_ALSA_MIXER_CTRL=MultiMedia2 -DMM_2_ALSA_PCM_DEVICE_ID=13 -DADC_BEGIN_NUM=0 -DADC_COUNT=4 -DPDP_MAX_PROFILE=16 -DPDP_MAX_MULTIPDP=8 -DEUICC -DLWM2M_OBJECT_3_BATTERY -DLWM2M_OBJECT_9 -I /home/awn/le-wsp/mangOH/build/yellow_wp77xx -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/framework/include -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/build/wp77xx/framework/include -I. -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/modemServices -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/positioning -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/atServices -I/home/awn/le-wsp/mangOH/interfaces -I/home/awn/le-wsp/mangOH/apps/LedService -I/home/awn/le-wsp/mangOH/apps/DataHub -I/home/awn/le-wsp/mangOH/apps/BatteryService -I/home/awn/le-wsp/mangOH/apps/Bme680EnvironmentalSensor -I/home/awn/le-wsp/mangOH/apps/YellowSensor/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/wifi" CXXFLAGS="--sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi -I /home/awn/le-wsp/mangOH/build/yellow_wp77xx -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/framework/include -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/build/wp77xx/framework/include -I. -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/modemServices -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/positioning -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/atServices -I/home/awn/le-wsp/mangOH/interfaces -I/home/awn/le-wsp/mangOH/apps/LedService -I/home/awn/le-wsp/mangOH/apps/DataHub -I/home/awn/le-wsp/mangOH/apps/BatteryService -I/home/awn/le-wsp/mangOH/apps/Bme680EnvironmentalSensor -I/home/awn/le-wsp/mangOH/apps/YellowSensor/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/wifi" LDFLAGS="--sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi " CPPFLAGS="--sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi " PATH="${LEGATO_ROOT}/bin:/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi:/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/x86_64-pokysdk-linux/usr/bin:/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/x86_64-pokysdk-linux/bin:/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/x86_64-pokysdk-linux/sbin:$PATH" && . /home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi/../../environment-setup-armv7a-neon-poky-linux-gnueabi && cmake -G Ninja /home/awn/le-wsp/mangOH/components/bluezDBus
/bin/sh: 15: export: Files/WindowsApps/CanonicalGroupLimited.Ubuntu18.04onWindows_1804.2020.824.0_x64__79rhkp1fndgsc:/mnt/c/apps/Python27/:/mnt/c/apps/Python27/Scripts:/mnt/c/Program: bad variable name
[1287/1345] Compiling C++ source
ninja: build stopped: subcommand failed.
Makefile:122: recipe for target 'yellow_wp77xx' failed
make: *** [yellow_wp77xx] Error 1
(lsh:mangOH-yellow-wp77) awn@Lap_Nova_01:~/le-wsp/mangOH$

and there’s a load of warnings:

/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc --sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi -O2 -DSIERRA_MDM9X28 -DSIERRA_WP76XX -DPCM_IF=SEC_AUX -DI2S_IF=SEC_MI2S -DUSB_IF=AFE_PCM -DCODEC_IF=PRI_MI2S -DMM_1_ALSA_MIXER_CTRL=MultiMedia1 -DMM_1_ALSA_PCM_DEVICE_ID=0 -DMM_2_ALSA_MIXER_CTRL=MultiMedia2 -DMM_2_ALSA_PCM_DEVICE_ID=13 -DADC_BEGIN_NUM=0 -DADC_COUNT=4 -DPDP_MAX_PROFILE=16 -DPDP_MAX_MULTIPDP=8 -DEUICC -DLWM2M_OBJECT_3_BATTERY -DLWM2M_OBJECT_9 -I /home/awn/le-wsp/mangOH/build/yellow_wp77xx -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/framework/include -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/build/wp77xx/framework/include -I. -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/modemServices -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/positioning -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/atServices -I/home/awn/le-wsp/mangOH/interfaces -I/home/awn/le-wsp/mangOH/apps/LedService -I/home/awn/le-wsp/mangOH/apps/DataHub -I/home/awn/le-wsp/mangOH/apps/BatteryService -I/home/awn/le-wsp/mangOH/apps/Bme680EnvironmentalSensor -I/home/awn/le-wsp/mangOH/apps/YellowSensor/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/wifi --sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi  -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src -DTINYCBOR_VERSION_SUFFIX=\"\" -std=c99 --sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi -O2 -DSIERRA_MDM9X28 -DSIERRA_WP76XX -DPCM_IF=SEC_AUX -DI2S_IF=SEC_MI2S -DUSB_IF=AFE_PCM -DCODEC_IF=PRI_MI2S -DMM_1_ALSA_MIXER_CTRL=MultiMedia1 -DMM_1_ALSA_PCM_DEVICE_ID=0 -DMM_2_ALSA_MIXER_CTRL=MultiMedia2 -DMM_2_ALSA_PCM_DEVICE_ID=13 -DADC_BEGIN_NUM=0 -DADC_COUNT=4 -DPDP_MAX_PROFILE=16 -DPDP_MAX_MULTIPDP=8 -DEUICC -DLWM2M_OBJECT_3_BATTERY -DLWM2M_OBJECT_9 -I /home/awn/le-wsp/mangOH/build/yellow_wp77xx -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/framework/include -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/build/wp77xx/framework/include -I. -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/modemServices -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/positioning -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/atServices -I/home/awn/le-wsp/mangOH/interfaces -I/home/awn/le-wsp/mangOH/apps/LedService -I/home/awn/le-wsp/mangOH/apps/DataHub -I/home/awn/le-wsp/mangOH/apps/BatteryService -I/home/awn/le-wsp/mangOH/apps/Bme680EnvironmentalSensor -I/home/awn/le-wsp/mangOH/apps/YellowSensor/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/wifi  -c -o src/cborerrorstrings.o /home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src/cborerrorstrings.c
/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/x86_64-pokysdk-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc --sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi -O2 -DSIERRA_MDM9X28 -DSIERRA_WP76XX -DPCM_IF=SEC_AUX -DI2S_IF=SEC_MI2S -DUSB_IF=AFE_PCM -DCODEC_IF=PRI_MI2S -DMM_1_ALSA_MIXER_CTRL=MultiMedia1 -DMM_1_ALSA_PCM_DEVICE_ID=0 -DMM_2_ALSA_MIXER_CTRL=MultiMedia2 -DMM_2_ALSA_PCM_DEVICE_ID=13 -DADC_BEGIN_NUM=0 -DADC_COUNT=4 -DPDP_MAX_PROFILE=16 -DPDP_MAX_MULTIPDP=8 -DEUICC -DLWM2M_OBJECT_3_BATTERY -DLWM2M_OBJECT_9 -I /home/awn/le-wsp/mangOH/build/yellow_wp77xx -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/framework/include -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/build/wp77xx/framework/include -I. -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/modemServices -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/positioning -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/atServices -I/home/awn/le-wsp/mangOH/interfaces -I/home/awn/le-wsp/mangOH/apps/LedService -I/home/awn/le-wsp/mangOH/apps/DataHub -I/home/awn/le-wsp/mangOH/apps/BatteryService -I/home/awn/le-wsp/mangOH/apps/Bme680EnvironmentalSensor -I/home/awn/le-wsp/mangOH/apps/YellowSensor/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/wifi --sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi  -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src -DTINYCBOR_VERSION_SUFFIX=\"\" -std=c99 --sysroot=/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-toolchain/sysroots/armv7a-neon-poky-linux-gnueabi -O2 -DSIERRA_MDM9X28 -DSIERRA_WP76XX -DPCM_IF=SEC_AUX -DI2S_IF=SEC_MI2S -DUSB_IF=AFE_PCM -DCODEC_IF=PRI_MI2S -DMM_1_ALSA_MIXER_CTRL=MultiMedia1 -DMM_1_ALSA_PCM_DEVICE_ID=0 -DMM_2_ALSA_MIXER_CTRL=MultiMedia2 -DMM_2_ALSA_PCM_DEVICE_ID=13 -DADC_BEGIN_NUM=0 -DADC_COUNT=4 -DPDP_MAX_PROFILE=16 -DPDP_MAX_MULTIPDP=8 -DEUICC -DLWM2M_OBJECT_3_BATTERY -DLWM2M_OBJECT_9 -I /home/awn/le-wsp/mangOH/build/yellow_wp77xx -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/framework/include -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/build/wp77xx/framework/include -I. -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/modemServices -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/positioning -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/atServices -I/home/awn/le-wsp/mangOH/interfaces -I/home/awn/le-wsp/mangOH/apps/LedService -I/home/awn/le-wsp/mangOH/apps/DataHub -I/home/awn/le-wsp/mangOH/apps/BatteryService -I/home/awn/le-wsp/mangOH/apps/Bme680EnvironmentalSensor -I/home/awn/le-wsp/mangOH/apps/YellowSensor/interfaces -I/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/interfaces/wifi  -c -o src/cborencoder.o /home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src/cborencoder.c
In file included from /home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src/cborencoder.c:33:0:
/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src/compilersupport_p.h:175:11: warning: bad option '-ffunction-sections' to pragma 'optimize' [-Wpragmas]
 #  pragma GCC optimize("-ffunction-sections")
           ^~~
/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src/compilersupport_p.h:179:1: warning: bad option '-ffunction-sections' to attribute 'optimize' [-Wattributes]
 {
 ^
/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src/compilersupport_p.h:190:1: warning: bad option '-ffunction-sections' to attribute 'optimize' [-Wattributes]
 {
 ^
/home/awn/le-wsp/leaf-data/mangOH-yellow-wp77/mangOH-yellow-wp77xx-legato/3rdParty/tinycbor/src/cborencoder.c:203:1: warning: bad option '-ffunction-sections' to attribute 'optimize' [-Wattributes]
 {
 ^

etc

Complete log attached.

2021-06-08-01-mangOH-yellow-build-fail.txt (211.6 KB)

Don’t quite suggest you building in windows

/bin/sh: 15: export: Files/WindowsApps/CanonicalGroupLimited.Ubuntu18.04onWindows_1804.2020.824.0_x64__79rhkp1fndgsc:/mnt/c/apps/Python27/:/mnt/c/apps/Python27/Scripts:/mnt/c/Program: bad variable name

So what is “bad” about it?

What should it be?

bad is it will have “bad variable name”
You can try to fix it

In what way is the name “bad” ?

In other words, what would constitute a “good” name ?

It was you who suggested this article in the first place:

yes, but eventually i found that it is experimental and not officially announced in legato.io

Currently I don’t know how to fix it to have the “good” name.

It might be faster if you install VMWARE with Ubuntu now.

I’m thinking it’d be quicker to go back to the Raspberry Pi …

:roll_eyes:

yes, you can also use WP77 to establish LTE data channel to your Raspberry Pi

Ah - it looks like the old “spaces in file/folder names” chestnut.
Definitely not one of Microsoft’s better ideas.

:roll_eyes:

It seems to be falling over at

... :/mnt/c/apps/Python27/Scripts:/mnt/c/Program

which should be

... :/mnt/c/apps/Python27/Scripts:/mnt/c/Program Files (x86)/ ...

which seems to come from the Windows PATH.

EDIT

Seems this is a familiar scenario:

EDIT 2

Seems that we can stop the Windows stuff appearing in the PATH:

Yes, it does need the

wsl --shutdown

(in a Windows command prompt)

Indeed - creating a /stc/wsl.conf file containing:

[interop]
enabled=false           # disable launch of Windows binaries; default is true
appendWindowsPath=false # don’t append Windows path to $PATH variable; default is true

and doing a wsl --shutdown does allow the build to complete successfully.