1

I want to compile ffmpeg on windows with cygwin and android ndk. I found this link very useful because there is step to step guide to compile ffmpeg.

Does anyone find this useful? - Compiling FFMPEG on Windows with Cywin and NDK r5

But at last point when i am going to create .so file i got this error in cygwin bash.


CONSOLE OUTPUT:

vikram mahal@vikrammahal-PC ~
$ cd /cygdrive/c/ffmpeg-0.10.3
vikram mahal@vikrammahal-PC /cygdrive/c/ffmpeg-0.10.3
$ dos2unix build_android.sh
dos2unix: converting file build_android.sh to Unix format ...
vikram mahal@vikrammahal-PC /cygdrive/c/ffmpeg-0.10.3
$ ./build_android.sh
)/configure: line 10: warning: setlocale: LC_ALL: cannot change locale (C
': not a valid identifierort: `LC_ALL
./configure: line 14: syntax error near unexpected token `$'{\r''
'/configure: line 14: `try_exec(){
./build_android.sh: line 54: make: command not found
./build_android.sh: line 55: make: command not found
C:\android-ndk-r5\toolchains\arm-linux-androideabi-4.4.3\prebuilt\windows\bin\ar
m-linux-androideabi-ld.exe: cannot open output file ./android/armv7-a/libffmpeg.
so: No such file or directory
Community
  • 1
  • 1
Vikram Mahal
  • 31
  • 1
  • 4
  • hi, i used your code to take backup but its not working and now i installed make but still giving error of "make file" in it. – Vikram Mahal Mar 28 '13 at 07:08

1 Answers1

1

1] ./configure: line 14: syntax error near unexpected token `$'{\r''

To resolve this, create a backup copy of build_android.sh and run

$dos2unix build_android_backup.sh
$sh build_android_backup.sh

2] ./build_android.sh: line 54: make: command not found

to resolve the above error check if you have install 'make' program while installing Cygwin

asloob
  • 1,308
  • 20
  • 34
  • Hi, earlier i haven't installed make in cygwin but now i installed make in it and now i get this error. – Vikram Mahal Mar 28 '13 at 07:05
  • can you run "make --version" (without quotes) and verify that make is installed in cygwin? – asloob Mar 28 '13 at 07:12
  • WHEN I RUN MAKE I GOT THIS ERROR:-Makefile:2: config.mak: No such file or directory Makefile:45: /common.mak: No such file or directory Makefile:84: /libavutil/Makefile: No such file or directory Makefile:84: /library.mak: No such file or directory Makefile:161: /doc/Makefile: No such file or directory Makefile:162: /tests/Makefile: No such file or directory MAKE: *** No rule to make target `/tests/Makefile'. Stop. – Vikram Mahal Mar 28 '13 at 07:15
  • I think there is something wrong with your make installation. Try to resolve this separtaly and then try to build ffmpeg. – asloob Mar 28 '13 at 07:20
  • when i installed make from setup then i only select - make-the gnu version of 'make' utility and make depend- X.org makefile dependency tool. so, is there anything else also to be installed with this. – Vikram Mahal Mar 28 '13 at 07:28
  • hi, this is my gmail id- "vmahal.silicon@gmail.com" add me there. – Vikram Mahal Mar 28 '13 at 07:44
  • @asloob have u successfully built ffmpeg on windows..because i have some problem regrading to it can you please help me?I have given +1 for your answer and also i have tried the dos2unix command but it still gives me error....I m using this https://github.com/guardianproject/android-ffmpeg – TheFlash Jun 18 '13 at 08:59
  • @Pratik please post your question separately with all details so that everyone can see and you may get the best answer. I'll try to answer if I have seen the problem before. – asloob Jun 19 '13 at 04:43
  • @asloob thanks dude for reply I was unable to build ffmpeg on windows and not even found single tutorial also i have posted questions 2 times but unfortunately i got nothing-no help on SO..I fed up with windows and now i m trying to build ffmpeg library on ubuntu if i face any problem i will sure post new question. – TheFlash Jun 19 '13 at 04:47