when I run a command simg2img
I get the following error:
/bin/bash: line 1: simg2img: command not found.
MakeFile Snippet:
if [ true = true ]; then \
simg2img out/target/product/evk_6sl/system_sparse.img out/target/product/evk_6sl/system.img; \
fi
If I check simg2img
is obtained in the path
/out/host/linux-x86/bin/simg2img
And this path is also in $PATH
.
Running sim2img --help
prints:
~/Android_Source$ simg2img --help
Usage: simg2img <sparse_image_files> <raw_image_file>
~/Android_Source/out/host/linux-x86/bin$ id
uid=1000(accord) gid=1000(accord) groups=1000(accord),4(adm),24(cdrom),27(sudo),30(dip),46(plugdev),108(lpadmin),124(sambashare)
~/Android_Source/out/host/linux-x86/bin$ ls -lZ simg2img
-rwxr-xr-x 1 root root ? 282920 Dec 9 17:36 simg2img
~/Android_Source/out/host/linux-x86/bin$ echo $PATH
/usr/lib/jvm/java-7-openjdk-amd64/bin:/home/accord/Android_Source/out/host/linux-x86/bin:/home/accord/Android_Source/prebuilts/gcc/linux-x86/arm/arm-linux-androideabi-4.8/bin:/home/accord/Android_Source/prebuilts/gcc/linux-x86/:/home/accord/Android_Source/prebuilts/gcc/linux-x86/arm/arm-eabi-4.8/bin:/home/accord/Android_Source/development/scripts:/home/accord/Android_Source/prebuilts/devtools/tools:/home/accord/Android_Source/prebuilts/android-emulator/linux-x86_64:/home/accord/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/home/accord/Android_Source/out/host/linux-x86/bin
~/Android_Source/out/host/linux-x86/bin$ which simg2img
/home/accord/Android_Source/out/host/linux-x86/bin/simg2img
Why am I still getting the simg2img command not found
error?
id
,ls -lZ /out/host/linux-x86/bin/simg2img
andecho $PATH
to your question.$PATH
. Add the information Cyrus asked for and we should be able to tell you why. Also tell us exactly how you are running the script.