[GitHub] [mynewt-core] danielkucera commented on issue #2583: Error compiling 1.9.0
danielkucera commented on issue #2583: URL: https://github.com/apache/mynewt-core/issues/2583#issuecomment-828355250 Okay, this has worked: ``` newt target set nrf52_blinky cflags='-DPRIu64="llu" -DPRIx64="llx"' ``` I can live with that. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org
[GitHub] [mynewt-core] danielkucera commented on issue #2583: Error compiling 1.9.0
danielkucera commented on issue #2583: URL: https://github.com/apache/mynewt-core/issues/2583#issuecomment-827473071 Okay, now I'm starting to understand. This has worked for me as a workaround: ``` sudo apt install libnewlib-nano-arm-none-eabi newt target amend nrf52_blinky cflags="-I/usr/lib/newlib-nano/arm-none-eabi/include" ``` Now I'm hitting another error: ``` Compiling repos/apache-mynewt-core/libc/baselibc/src/memccpy.c Error: repos/apache-mynewt-core/libc/baselibc/src/malloc.c:30:8: error: unknown type name 'malloc_lock_t' 30 | static malloc_lock_t malloc_lock = _lock_nop; |^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:30:36: error: initialization of 'int' from '_Bool (*)()' makes integer from pointer without a cast [-Werror=int-conversion] 30 | static malloc_lock_t malloc_lock = _lock_nop; |^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:31:8: error: unknown type name 'malloc_unlock_t' 31 | static malloc_unlock_t malloc_unlock = _unlock_nop; |^~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:31:40: error: initialization of 'int' from 'void (*)()' makes integer from pointer without a cast [-Werror=int-conversion] 31 | static malloc_unlock_t malloc_unlock = _unlock_nop; |^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c: In function 'malloc': repos/apache-mynewt-core/libc/baselibc/src/malloc.c:159:10: error: called object 'malloc_lock' is not a function or function pointer 159 | if (!malloc_lock()) | ^~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:30:22: note: declared here 30 | static malloc_lock_t malloc_lock = _lock_nop; | ^~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:175:13: error: implicit declaration of function 'add_malloc_block' [-Werror=implicit-function-declaration] 175 | add_malloc_block(more_mem, size); | ^~~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:179:5: error: called object 'malloc_unlock' is not a function or function pointer 179 | malloc_unlock(); | ^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:31:24: note: declared here 31 | static malloc_unlock_t malloc_unlock = _unlock_nop; |^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c: At top level: repos/apache-mynewt-core/libc/baselibc/src/malloc.c:184:6: error: conflicting types for 'add_malloc_block' [-Werror] 184 | void add_malloc_block(void *buf, size_t size) | ^~~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:175:13: note: previous implicit declaration of 'add_malloc_block' was here 175 | add_malloc_block(more_mem, size); | ^~~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c: In function 'add_malloc_block': repos/apache-mynewt-core/libc/baselibc/src/malloc.c:198:10: error: called object 'malloc_lock' is not a function or function pointer 198 | if (!malloc_lock()) | ^~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:30:22: note: declared here 30 | static malloc_lock_t malloc_lock = _lock_nop; | ^~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:221:5: error: called object 'malloc_unlock' is not a function or function pointer 221 | malloc_unlock(); | ^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:31:24: note: declared here 31 | static malloc_unlock_t malloc_unlock = _unlock_nop; |^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c: In function 'free': repos/apache-mynewt-core/libc/baselibc/src/malloc.c:238:10: error: called object 'malloc_lock' is not a function or function pointer 238 | if (!malloc_lock()) | ^~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:30:22: note: declared here 30 | static malloc_lock_t malloc_lock = _lock_nop; | ^~~ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:243:5: error: called object 'malloc_unlock' is not a function or function pointer 243 | malloc_unlock(); | ^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c:31:24: note: declared here 31 | static malloc_unlock_t malloc_unlock = _unlock_nop; |^ repos/apache-mynewt-core/libc/baselibc/src/malloc.c: In function 'get_malloc_memory_status': repos/apache-mynewt-core/libc/baselibc/src/malloc.c:252:10: error: called object 'malloc_lock'
[GitHub] [mynewt-core] danielkucera commented on issue #2583: Error compiling 1.9.0
danielkucera commented on issue #2583: URL: https://github.com/apache/mynewt-core/issues/2583#issuecomment-827435178 These macros were already present in 1.8.0: https://github.com/apache/mynewt-core/blob/mynewt_1_8_0_tag/encoding/tinycbor/src/cborpretty.c#L307 And this one compiles without issues. So I presume the problem won't be in my SDK, or? -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org
[GitHub] [mynewt-core] danielkucera commented on issue #2583: Error compiling 1.9.0
danielkucera commented on issue #2583: URL: https://github.com/apache/mynewt-core/issues/2583#issuecomment-827369433 I'm not much in favor of keeping a separate toolchain because of mynewt, is there not any other way around? ``` danman@silverhorse:~$ which arm-none-eabi-gcc /usr/bin/arm-none-eabi-gcc danman@silverhorse:~$ /usr/bin/arm-none-eabi-gcc -v Using built-in specs. COLLECT_GCC=/usr/bin/arm-none-eabi-gcc COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-none-eabi/9.2.1/lto-wrapper Target: arm-none-eabi Configured with: ../configure --build=x86_64-linux-gnu --prefix=/usr --includedir='/usr/lib/include' --mandir='/usr/lib/share/man' --infodir='/usr/lib/share/info' --sysconfdir=/etc --localstatedir=/var --disable-silent-rules --libdir='/usr/lib/lib/x86_64-linux-gnu' --libexecdir='/usr/lib/lib/x86_64-linux-gnu' --disable-maintainer-mode --disable-dependency-tracking --mandir=/usr/share/man --enable-languages=c,c++,lto --enable-multilib --disable-decimal-float --disable-libffi --disable-libgomp --disable-libmudflap --disable-libquadmath --disable-libssp --disable-libstdcxx-pch --disable-nls --disable-shared --disable-threads --enable-tls --build=x86_64-linux-gnu --target=arm-none-eabi --with-system-zlib --with-gnu-as --with-gnu-ld --with-pkgversion=15:9-2019-q4-0ubuntu1 --without-included-gettext --prefix=/usr/lib --infodir=/usr/share/doc/gcc-arm-none-eabi/info --htmldir=/usr/share/doc/gcc-arm-none-eabi/html --pdfdir=/usr/share/doc/gcc-arm-none-eabi/pdf --bindir=/usr/bin --libexecdir =/usr/lib --libdir=/usr/lib --disable-libstdc++-v3 --host=x86_64-linux-gnu --with-headers=no --without-newlib --with-multilib-list=rmprofile CFLAGS='-g -O2 -fdebug-prefix-map=/build/gcc-arm-none-eabi-Gl9kT9/gcc-arm-none-eabi-9-2019-q4=. -fstack-protector-strong' CPPFLAGS='-Wdate-time -D_FORTIFY_SOURCE=2' CXXFLAGS='-g -O2 -fdebug-prefix-map=/build/gcc-arm-none-eabi-Gl9kT9/gcc-arm-none-eabi-9-2019-q4=. -fstack-protector-strong' FCFLAGS='-g -O2 -fdebug-prefix-map=/build/gcc-arm-none-eabi-Gl9kT9/gcc-arm-none-eabi-9-2019-q4=. -fstack-protector-strong' FFLAGS='-g -O2 -fdebug-prefix-map=/build/gcc-arm-none-eabi-Gl9kT9/gcc-arm-none-eabi-9-2019-q4=. -fstack-protector-strong' GCJFLAGS='-g -O2 -fdebug-prefix-map=/build/gcc-arm-none-eabi-Gl9kT9/gcc-arm-none-eabi-9-2019-q4=. -fstack-protector-strong' LDFLAGS='-Wl,-Bsymbolic-functions -Wl,-z,relro' OBJCFLAGS='-g -O2 -fdebug-prefix-map=/build/gcc-arm-none-eabi-Gl9kT9/gcc-arm-none-eabi-9-2019-q4=. -fstack-protector-strong' OBJCXXFLAGS='-g -O2 -fdeb ug-prefix-map=/build/gcc-arm-none-eabi-Gl9kT9/gcc-arm-none-eabi-9-2019-q4=. -fstack-protector-strong' INHIBIT_LIBC_CFLAGS=-DUSE_TM_CLONE_REGISTRY=0 AR_FOR_TARGET=arm-none-eabi-ar AS_FOR_TARGET=arm-none-eabi-as LD_FOR_TARGET=arm-none-eabi-ld NM_FOR_TARGET=arm-none-eabi-nm OBJDUMP_FOR_TARGET=arm-none-eabi-objdump RANLIB_FOR_TARGET=arm-none-eabi-ranlib READELF_FOR_TARGET=arm-none-eabi-readelf STRIP_FOR_TARGET=arm-none-eabi-strip Thread model: single gcc version 9.2.1 20191025 (release) [ARM/arm-9-branch revision 277599] (15:9-2019-q4-0ubuntu1) ``` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org