Iphone - device - linker error

人走茶凉 提交于 2019-11-30 09:37:50

I "solved" this by replacing lines 117-121 in libpng's pngpriv.h:

#  ifdef __ARM_NEON__
#     define PNG_ARM_NEON_OPT 2
#  else
#     define PNG_ARM_NEON_OPT 0
#  endif

by

#define PNG_ARM_NEON_OPT 0

This disables ARM's NEON optimizations, which seems to be the cause of the problem.

This is merely a workaround though, I didn't have time to investigate the real cause of the problem further.

Adding to PSyton's comment, here is how we solved it. Compile the arm/*.c files. This however does only work for Android. For iOS, we additionally had to create a new pnglibconf.h with the entries:

#undef PNG_ARM_NEON_API_SUPPORTED
#undef PNG_ARM_NEON_CHECK_SUPPORTED
#define PNG_ARM_NEON_OPT 0

Looking at the ARM defines in libpng, it seems like they are a bit buggy currently, as PNG_ARM_NEON_API_SUPPORTED should be sufficient to turn NEON compilation off.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!