Ask Your Question
2

opencv 3.0 with android nkd - undefined reference to 'std::__throw_out_of_range_fmt(char const*, ...)'

asked 2015-06-05 07:42:10 -0600

android.3.0.error gravatar image

is anyone else getting the following error when trying to compile a static build within the android ndk?

/android/opencv/native/jni/../3rdparty/libs/armeabi-v7a/libIlmImf.a(ImfChannelList.cpp.o):ImfChannelList.cpp:function Imf::ChannelList::layers(std::set<std::string, std::less<std::string>, std::allocator<std::string> >&) const: error: undefined reference to 'std::__throw_out_of_range_fmt(char const*, ...)'

this problem did not occur with the previous release candidates, so i wonder whether the mistake is on my end or there is some issue within the newly released opencv binaries for android.

edit retag flag offensive close merge delete

2 answers

Sort by ยป oldest newest most voted
3

answered 2015-06-17 08:52:35 -0600

jachstet-sea gravatar image

I'm getting the same error. The cause is that they chose to switch the toolchain they built the libraries with from gcc-4.8 to gcc-4.9 from 3.0.0-rc1 to 3.0.0 final. Try forcing your NKD build to use GCC 4.9 instead of the default 4.8.

See also http://code.opencv.org/issues/4398

edit flag offensive delete link more

Comments

2

The Android SDK will be updated soon, it will be compiled with default NDK_r10e compilers (4.8 for 32 bit, 4.9 for 64 bit).

mshabunin gravatar imagemshabunin ( 2015-06-17 09:41:19 -0600 )edit

I'm also getting a very similar error with libIlmImf. Could it be because I'm using Crystax NDK 10.3.0 (with GCC 4.9) instead of official NDK? (I need to use boost library which is available in Crystax). Link to the error in case someone can shed some light on: https://github.com/DraXus/dlib-androi...

draxus gravatar imagedraxus ( 2015-12-17 10:24:18 -0600 )edit
1

answered 2015-06-10 12:55:29 -0600

opencvdawg gravatar image

I am getting the same error too but for the ML libraries. I tried to see how they were compiling, I thought they might have compiled with a different GCC version so I used my own toolchain and it still failed. Not sure what the issue is, more banging my head against the wall and looking through make files. Hope someone knows or fixes this.

edit flag offensive delete link more

Question Tools

3 followers

Stats

Asked: 2015-06-05 07:42:10 -0600

Seen: 6,617 times

Last updated: Jun 17 '15