Closed defencedog closed 7 months ago
Please do not set LD_LIBRARY_PATH=/system/lib
@truboxl I added that because ffmpeg will not work Your instructions work ... but now when I use ffmpeg
CANNOT LINK EXECUTABLE "ffmpeg": cannot locate symbol "_Z17createHeifDecoderv" referenced by "/system/lib/libhwui.so"...
Please install libandroid-stub
if it fixes your issue
Thanks it works...
May I ask how libandroid-stub fixed the ffmpeg issue? Ther error output has createHeifDecoder function which is not related to libandroid library.
It is related but indirectly. libandroid.so
has dependencies such as libhwui.so
, the latter fails to resolve symbol due to library conflict - Termux have libraries with same name as Android, but they different internally causing stuff to break.
This is also why one should never set LD_LIBRARY_PATH
in Termux. It messes up library search order. This variable was required for Termux running on legacy Android versions (5.x, 6.x).
Installing libandroid-stub
cause ffmpeg
to pick a stub version of libandroid.so
that is present in Termux directories instead of Android system.
The _Z17createHeifDecoderv
symbol is provided by /system/lib[64]/libheif.so
, which /system/lib[64]/libhwui.so
depends on.
The termux libheif
package also provides $PREFIX/lib/libheif.so
.
Installing the libandroid-stub
package shouldn't be required, my guess is that user has set LD_LIBRARY_PATH=/data/data/com.termux/files/usr/lib
somewhere else, which causes $PREFIX/lib/libheif.so
to be picked up instead of the system one.
This error was posted in https://www.reddit.com/r/termux/comments/17pxvw5/how_to_fix_this/ as well and unsetting LD_LIBRARY_PATH
worked.
@agnostic-apollo
Problem has resurfaced with gtt
. I had already installed libandroid-stub
CANNOT LINK EXECUTABLE "gtt": cannot locate symbol "_Z17createHeifDecoderv" referenced by "/system/lib/libhwui.so"...
Can you help try rm $PREFIX/lib/libheif.so
?
@truboxl will not rm
be dangerous what about renaming via mv
?
Unless you use packages from apt rdepends libheif
then maybe. You can always restore by apt reinstall libheif
.
Also post output of echo LD_LIBRARY_PATH=$LD_LIBRARY_PATH
after running it in the same shell in which error is triggered.
Also post output of
echo LD_LIBRARY_PATH=$LD_LIBRARY_PATH
after running it in the same shell in which error is triggered.
LD_LIBRARY_PATH=/data/data/com.termux/files/usr/lib:/data/data/com.termux/files/usr/local/lib
That is your problem, find out where it is being set and remove the command, it should be empty on Android >= 7
, termux does not set it by default. Also uninstall libandroid-stub
with apt remove libandroid-stub
and restore your $PREFIX/lib/libheif.so
file.
Problem description
cmake
is unusableWhat steps will reproduce the bug?
Install
cmake
& it gives this errorWhat is the expected behavior?
Cannot use cmake....
System information
termux-info: