Skip to content

Could not Compile ARM Compute library on Raspberry Pi  #1143

@pegasus-git

Description

@pegasus-git

Output of 'strings libarm_compute.so | grep arm_compute_version':

Platform: Raspberry Pi 5

Operating System: Raspberry Pi Bookworm OS

GCC version: g++ -v
Using built-in specs.
COLLECT_GCC=g++
COLLECT_LTO_WRAPPER=/usr/lib/gcc/arm-linux-gnueabihf/12/lto-wrapper
Target: arm-linux-gnueabihf
Configured with: ../src/configure -v --with-pkgversion='Raspbian 12.2.0-14+rpi1' --with-bugurl=file:///usr/share/doc/gcc-12/README.Bugs --enable-languages=c,ada,c++,go,d,fortran,objc,obj-c++,m2 --prefix=/usr --with-gcc-major-version-only --program-suffix=-12 --program-prefix=arm-linux-gnueabihf- --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --libdir=/usr/lib --enable-nls --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --with-default-libstdcxx-abi=new --enable-gnu-unique-object --disable-libitm --disable-libquadmath --disable-libquadmath-support --enable-plugin --with-system-zlib --enable-libphobos-checking=release --with-target-system-zlib=auto --enable-objc-gc=auto --enable-multiarch --disable-sjlj-exceptions --with-arch=armv6+fp --with-float=hard --disable-werror --enable-checking=release --build=arm-linux-gnueabihf --host=arm-linux-gnueabihf --target=arm-linux-gnueabihf
Thread model: posix
Supported LTO compression algorithms: zlib zstd
gcc version 12.2.0 (Raspbian 12.2.0-14+rpi1)

Problem description: I have followed the instructions provided in this page: https://developer.arm.com/documentation/ecm0752397/ac/Install-and-build-the-Arm-Compute-Library-on-Pi
ACL version: 20.02.1
This used to work in the past. But when I tried this on my new raspberry pi 5 board I get the below error:

Installing ARM Compute library 20.02.1

scons: Reading SConscript files ...
Mkdir("build")
scons: done reading SConscript files.
scons: Building targets ...
scons: arm_compute' is up to date. scons: support' is up to date.
scons: building associated VariantDir targets: build/utils
g++ -o build/utils/CommonGraphOptions.o -c -Wall -DARCH_ARM -Wextra -pedantic -Wdisabled-optimization -Wformat=2 -Winit-self -Wstrict-overflow=2 -Wswitch-default -std=gnu++11 -Woverloaded-virtual -Wformat-security -Wctor-dtor-privacy -Wsign-promo -Weffc++ -Wno-overlength-strings -Wlogical-op -Wnoexcept -Wstrict-null-sentinel -march=armv7-a -mthumb -mfpu=neon -mfloat-abi=hard -Wno-ignored-attributes -O3 -D_GLIBCXX_USE_NANOSLEEP -DARM_COMPUTE_CPP_SCHEDULER=1 -DEMBEDDED_KERNELS -Iinclude -I. -I. utils/CommonGraphOptions.cpp
g++ -o build/utils/GraphUtils.o -c -Wall -DARCH_ARM -Wextra -pedantic -Wdisabled-optimization -Wformat=2 -Winit-self -Wstrict-overflow=2 -Wswitch-default -std=gnu++11 -Woverloaded-virtual -Wformat-security -Wctor-dtor-privacy -Wsign-promo -Weffc++ -Wno-overlength-strings -Wlogical-op -Wnoexcept -Wstrict-null-sentinel -march=armv7-a -mthumb -mfpu=neon -mfloat-abi=hard -Wno-ignored-attributes -O3 -D_GLIBCXX_USE_NANOSLEEP -DARM_COMPUTE_CPP_SCHEDULER=1 -DEMBEDDED_KERNELS -Iinclude -I. -I. utils/GraphUtils.cpp
In file included from ./utils/Utils.h:36,
from ./utils/ImageLoader.h:32,
from utils/GraphUtils.cpp:34:
include/libnpy/npy.hpp: In function ‘std::string npy::pyparse::write_tuple(const std::vector&)’:
include/libnpy/npy.hpp:298:42: error: ‘ostream_iterator’ is not a member of ‘std’
298 | std::copy(v.begin(), v.end()-1, std::ostream_iterator(ss, delimiter.c_str()));
| ^~~~~~~~~~~~~~~~
include/libnpy/npy.hpp:33:1: note: ‘std::ostream_iterator’ is defined in header ‘’; did you forget to ‘#include ’?
32 | #include
+++ |+#include
33 | #include
include/libnpy/npy.hpp:298:60: error: expected primary-expression before ‘>’ token
298 | std::copy(v.begin(), v.end()-1, std::ostream_iterator(ss, delimiter.c_str()));
| ^
scons: *** [build/utils/GraphUtils.o] Error 1
scons: building terminated because of errors.

I think this is because of the strictness enforced by newer versions of g++ compiler in Bookworm OS. Does this repo need a code update to include proper headers?

Any help or direction is appreciated.

Thanks

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions