Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to run a shell script in Ubuntu to flash my Firefox OS phone. I've downloaded and unzipped the new version. I've launched the shell and navigated to the directory where the .sh file is.

All of the files required to flash the phone are in the same directory. It uses two executables - adb and flashboot - which are both in the that directory. I type in ./flash.sh and it produces the output 'no such file or directory' errors.

I've typed in ./adb (which is the first command in the shell script) and it gives the same error - even though I can see the executable is there.

What am I doing wrong? I'm sure it is something simple.

EDIT #1

Here is the ls output for the adb executable:

-rwxr-xr-x 1 parallels parallels    204436 Jun 13 18:41 adb

Yes, I'm definitely in the right directory

parallels@~/Downloads$ pwd    
/home/parallels/Downloads

Full ls -la:

drwxrwxr-x  2 parallels parallels      4096 Sep  8 13:17 .  
drwxr-xr-x 39 parallels parallels      4096 Sep  8 13:16 ..  
-rwxr-xr-x  1 parallels parallels    204436 Jun 13 18:41 adb  
-rw-r--r--  1 parallels parallels    191488 Jun 13 18:41 adb.exe  
-rw-r--r--  1 parallels parallels     96256 Jun 13 18:41 AdbWinApi.dll  
-rw-r--r--  1 parallels parallels     60928 Jun 13 18:41 AdbWinUsbApi.dll  
-rw-r--r--  1 parallels parallels   4923392 Jun 13 18:41 boot.img  
-rwxr-xr-x  1 parallels parallels    149928 Jun 13 18:41 fastboot  
-rw-r--r--  1 parallels parallels    140800 Jun 13 18:41 fastboot.exe  
-rw-r--r--  1 parallels parallels      1044 Jun 13 18:41 flash.bat  
-rwxr-xr-x  1 parallels parallels       170 Jun 13 18:41 flash_mac.sh  
-rwxr-xr-x  1 parallels parallels       182 Jun 13 18:41 flash.sh  
-rw-rw-r--  1 parallels parallels  99863338 Sep  7 22:57 images-peak-2013-06-13.Gecko-86f00ac.Gaia-619c980.zip  
-rw-r--r--  1 parallels parallels 153211752 Jun 13 18:41 system.img  
-rw-r--r--  1 parallels parallels  33649328 Jun 13 18:41 userdata.img  

This is what I get trying to execute adb. (I've created a new directory 'flash' to make sure it is not specific to the Downloads directory):

parallels@~/flash$ ./adb
bash: ./adb: No such file or directory

EDIT #2

Found this:

Looks like it might be the same thing. Something to do with the executables being 32 bit on a 64 bit system and therefore required libs are missing.

share|improve this question
    
Are you sure you're in the right directory? Can you show us the output of ls -la? –  slhck Sep 8 '13 at 11:43
    
Are you sure they have (x - executable) mod on the files? Try chmod +x ./adb and then run it again? (and maybe need to run as sudo) –  Darius Sep 8 '13 at 11:54
    
@Darius If there weren't appropriate execute permissions, the OP would have gotten a permission denied error, not a no such file one. –  slhck Sep 8 '13 at 12:08
    
Just to be sure: It says './adb: No such file or directory'? –  Tim Sep 8 '13 at 12:53
    
@Tim yes, thats what it says.parallels@~/flash$ ./adb bash: ./adb: No such file or directory –  anthonyc Sep 8 '13 at 13:50

1 Answer 1

you are trying to run a Windows executable. Try wine adb.exe.

share|improve this answer
    
He appears to be trying to run the adb file, not the adb.exe file. –  ChrisInEdmonton Oct 21 '13 at 19:56

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.