1

I am compile VLC for Android according to following recommendations on Ubuntu 14.04

https://wiki.videolan.org/AndroidCompile

export ANDROID_SDK=/home/user/my/tools/android-sdk
export ANDROID_NDK=/home/user/my/tools/android-ndk-r9c
export PATH=$PATH:$ANDROID_SDK/platform-tools:$ANDROID_SDK/tools
export ANDROID_ABI=armeabi-v7a
export NO_FPU=0

git clone git://git.videolan.org/vlc-ports/android.git
sh compile.sh

But I am getting following error

gcc -std=gnu99  -I.     -g -O2 -MT freading.o -MD -MP -MF .deps/freading.Tpo -c -o freading.o freading.c
gcc -std=gnu99  -I.     -g -O2 -MT gl_list.o -MD -MP -MF .deps/gl_list.Tpo -c -o gl_list.o gl_list.c
mv -f .deps/gl_list.Tpo .deps/gl_list.Po
In file included from clean-temp.h:22:0,
                 from clean-temp.c:23:
./stdio.h:477:1: error: 'gets' undeclared here (not in a function)
 _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
 ^
gcc -std=gnu99  -I.     -g -O2 -MT localcharset.o -MD -MP -MF .deps/localcharset.Tpo -c -o localcharset.o localcharset.c
In file included from freadahead.h:18:0,
                 from freadahead.c:20:
./stdio.h:477:1: error: 'gets' undeclared here (not in a function)
 _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
 ^
In file included from freading.h:18:0,
                 from freading.c:20:
./stdio.h:477:1: error: 'gets' undeclared here (not in a function)
 _GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
 ^
make[4]: *** [freading.o] Error 1
make[4]: *** Waiting for unfinished jobs....
make[4]: *** [freadahead.o] Error 1

The only thing I have not tried is to update NDK or switch to CrystaX NDK.

PS I had NDK r9 (as adviced on project page) but after failing to compiling I got latest r10d and same problem.

I git checkout tags/1.0.0 and git checkout tags/0.9.9.

I have Ubuntu 14.04 64 bit.

Max
  • 6,286
  • 5
  • 44
  • 86

1 Answers1

2

I am suggesting that you are cloning from that master branch and there are errors in the master, try cloning from another head or with a tag for an overview take a look here:
http://git.videolan.org/?p=vlc-ports/android.git;a=summary

Nickolaus
  • 4,785
  • 4
  • 38
  • 60
  • `compile.sh` downloads VLC source code. There is following line: `TESTED_HASH=036010e` Most likes it downloads correct version. – Max Jan 22 '15 at 22:19
  • I don't mean that the download fails I mean that there are errors in the current source code of the master branch, therefore you should try to clone another branch – Nickolaus Jan 22 '15 at 22:21
  • I did `git checkout tags/1.0.0` and `git checkout tags/0.9.9` same problem. – Max Jan 23 '15 at 00:11