Commit f3489489 authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Add parsing options for compile-libvlc.sh script

 --help
 --release
 -a ARCH
parent 0f1f835f
...@@ -12,6 +12,25 @@ checkfail() ...@@ -12,6 +12,25 @@ checkfail()
fi fi
} }
RELEASE=0
while [ $# -gt 0 ]; do
case $1 in
help|--help)
echo "Use -a to set the ARCH"
echo "Use --release to build in release mode"
exit 1
;;
a|-a)
ANDROID_ABI=$2
shift
;;
release|--release)
RELEASE=1
;;
esac
shift
done
############# #############
# ARGUMENTS # # ARGUMENTS #
############# #############
...@@ -21,7 +40,8 @@ if [ -z "$ANDROID_NDK" ]; then ...@@ -21,7 +40,8 @@ if [ -z "$ANDROID_NDK" ]; then
fi fi
if [ -z "$ANDROID_ABI" ]; then if [ -z "$ANDROID_ABI" ]; then
echo "Please set ANDROID_ABI to your architecture: echo "Please pass the ANDROID ABI to the correct architecture, using
compile-libvlc.sh -a ARCH
ARM: armeabi-v7a, armeabi, armeabi-v5, armeabi-nofpu ARM: armeabi-v7a, armeabi, armeabi-v5, armeabi-nofpu
ARM64: arm64-v8a ARM64: arm64-v8a
X86: x86, x86_64 X86: x86, x86_64
...@@ -29,18 +49,6 @@ if [ -z "$ANDROID_ABI" ]; then ...@@ -29,18 +49,6 @@ if [ -z "$ANDROID_ABI" ]; then
exit 1 exit 1
fi fi
RELEASE=0
for i in ${@}; do
case "$i" in
release|--release)
RELEASE=1
;;
*)
;;
esac
done
######### #########
# FLAGS # # FLAGS #
######### #########
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment