ARMmbed / mbed-os

Arm Mbed OS is a platform operating system designed for the internet of things
https://mbed.com
Other
4.68k stars 2.98k forks source link

mbed compile --profile debug fails build at EventQueue.h@52,7 #10670

Closed cederom closed 5 years ago

cederom commented 5 years ago

Description

Both mbed compile --color -j8 --profile mbed-os/tools/profiles/debug.json and mbed compile --color -j8 --profile debug fails with the following error that does not occur when building without a debug profile:

[Error] EventQueue.h@52,7: 'mbed::NonCopyable<T>& mbed::NonCopyable<T>::operator=(const mbed::NonCopyable<T>&) [with T = events::EventQueue]' is private within this context

This build type is necessary to have insight into a variables when debugging. This command is described in [1]. This seems blocker since I cannot effectively debug my firmware (pyOCD+GDB). Tested with 5.9.7 and 5.12.4.

[1] https://os.mbed.com/docs/mbed-os/v5.12/tools/debug-builds-cli.html

(venv37mac) arm-none-eabi-g++ -v
Using built-in specs.
COLLECT_GCC=arm-none-eabi-g++
COLLECT_LTO_WRAPPER=/Users/cederom/cederom/work/CeDeROM/lab/ARM/SDK/gcc-arm-none-eabi-8-2018-q4-major/bin/../lib/gcc/arm-none-eabi/8.2.1/lto-wrapper
Target: arm-none-eabi
Configured with: /tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_1544945247/src/gcc/configure --target=arm-none-eabi --prefix=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_15449$5247/install-native --libexecdir=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_1544945247/install-native/lib --infodir=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_1544945247$install-native/share/doc/gcc-arm-none-eabi/info --mandir=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_1544945247/install-native/share/doc/gcc-arm-none-eabi/man --htmldir=/tmp/jenkins-GCC-8$build-toolchain-mac_cluster-128_20181216_1544945247/install-native/share/doc/gcc-arm-none-eabi/html --pdfdir=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_1544945247/install-native/share/do$/gcc-arm-none-eabi/pdf --enable-languages=c,c++ --enable-plugins --disable-decimal-float --disable-libffi --disable-libgomp --disable-libmudflap --disable-libquadmath --disable-libssp  --disable-libstdcxx-
pch --disable-nls --disable-shared --disable-threads --disable-tls --with-gnu-as --with-gnu-ld --with-newlib --with-headers=yes --with-python-dir=share/gcc-arm-none-eabi --with-sysroot=/tmp/jenkins-GCC-8-
build-toolchain-mac_cluster-128_20181216_1544945247/install-native/arm-none-eabi --build=x86_64-apple-darwin10 --host=x86_64-apple-darwin10 --with-gmp=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20
181216_1544945247/build-native/host-libs/usr --with-mpfr=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_1544945247/build-native/host-libs/usr --with-mpc=/tmp/jenkins-GCC-8-build-toolchain-mac
_cluster-128_20181216_1544945247/build-native/host-libs/usr --with-isl=/tmp/jenkins-GCC-8-build-toolchain-mac_cluster-128_20181216_1544945247/build-native/host-libs/usr --with-libelf=/tmp/jenkins-GCC-8-bu
ild-toolchain-mac_cluster-128_20181216_1544945247/build-native/host-libs/usr --with-host-libstdcxx='-static-libgcc -Wl,-lstdc++ -lm' --with-pkgversion='GNU Tools for Arm Embedded Processors 8-2018-q4-majo
r' --with-multilib-list=rmprofile
Thread model: single
gcc version 8.2.1 20181213 (release) [gcc-8-branch revision 267074] (GNU Tools for Arm Embedded Processors 8-2018-q4-major)

(venv37mac) python -V
Python 3.7.3

(venv37mac) uname -a
Darwin iCeDeROM.local 18.6.0 Darwin Kernel Version 18.6.0: Thu Apr 25 23:16:27 PDT 2019; root:xnu-4903.261.4~2/RELEASE_X86_64 x86_64

Issue request type

[ ] Question
[ ] Enhancement
[X] Bug
ciarmcom commented 5 years ago

Internal Jira reference: https://jira.arm.com/browse/MBOCUSTRIA-1227

cederom commented 5 years ago

My mistake, sorry!! I have put that eventQueue() into a context. This needs to be put as pointer into a context. Now debug with symbols works. Problem solved :-)