[Android] build: add an env variable that disable optimizations

Thomas Guillem git at videolan.org
Fri May 22 11:58:45 CEST 2015


vlc-ports/android | branch: master | Thomas Guillem <thomas at gllm.fr> | Fri May 22 11:57:42 2015 +0200| [0ecc74b9d392900b866b0220301a057d2597bef7] | committer: Thomas Guillem

build: add an env variable that disable optimizations

> http://git.videolan.org/gitweb.cgi/vlc-ports/android.git/?a=commit;h=0ecc74b9d392900b866b0220301a057d2597bef7
---

 compile-libvlc.sh |    8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/compile-libvlc.sh b/compile-libvlc.sh
index 5fcc6fc..f2b3691 100755
--- a/compile-libvlc.sh
+++ b/compile-libvlc.sh
@@ -337,8 +337,14 @@ fi
 ##########
 # CFLAGS #
 ##########
+if [ "$NO_OPTIM" = "1" ];
+then
+     CFLAGS="-g -O0"
+else
+     CFLAGS="-g -O2"
+fi
 
-CFLAGS="-g -O2 -fstrict-aliasing -funsafe-math-optimizations"
+CFLAGS="${CFLAGS} -fstrict-aliasing -funsafe-math-optimizations"
 if [ -n "$HAVE_ARM" -a ! -n "$HAVE_64" ]; then
     CFLAGS="${CFLAGS} -mlong-calls"
 fi



More information about the Android mailing list