Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Open sidebar
Ewout ter Hoeven
VLC-Android
Commits
ec890fd3
Commit
ec890fd3
authored
Oct 21, 2014
by
Thomas Guillem
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
compile.sh: handle arguments in one place
parent
b8414128
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
31 additions
and
20 deletions
+31
-20
compile.sh
compile.sh
+31
-20
No files found.
compile.sh
View file @
ec890fd3
...
...
@@ -6,22 +6,6 @@
set
-e
BUILD
=
FETCH
=
case
"
$1
"
in
--fetch
)
FETCH
=
1
shift
;;
--build
)
BUILD
=
1
shift
;;
*
)
FETCH
=
1
BUILD
=
1
;;
esac
if
[
-z
"
$ANDROID_NDK
"
-o
-z
"
$ANDROID_SDK
"
]
;
then
echo
"You must define ANDROID_NDK, ANDROID_SDK and ANDROID_ABI before starting."
...
...
@@ -34,6 +18,35 @@ if [ -z "$ANDROID_ABI" ]; then
exit
1
fi
BUILD
=
0
FETCH
=
0
RELEASE
=
0
JNI
=
0
for
i
in
${
@
}
;
do
case
"
$i
"
in
--fetch
)
FETCH
=
1
;;
--build
)
BUILD
=
1
;;
release|--release
)
RELEASE
=
1
;;
jni|--jni
)
JNI
=
1
;;
*
)
;;
esac
done
if
[
"
$BUILD
"
=
0
-a
"
$FETCH
"
=
0
]
;
then
BUILD
=
1
FETCH
=
1
fi
# Set up ABI variables
if
[
${
ANDROID_ABI
}
=
"x86"
]
;
then
TARGET_TUPLE
=
"i686-linux-android"
...
...
@@ -274,13 +287,11 @@ cd contrib/contrib-android-${TARGET_TUPLE}
[
${
ANDROID_ABI
}
=
"armeabi-v7a"
]
&&
echo
"NOTHUMB := -marm"
>>
config.mak
# Release or not?
if
[
$#
-ne
0
]
&&
[
"
$1
"
=
"release"
]
;
then
if
[
"
$RELEASE
"
=
1
]
;
then
OPTS
=
""
EXTRA_CFLAGS
=
"
${
EXTRA_CFLAGS
}
-DNDEBUG "
RELEASE
=
1
else
OPTS
=
"--enable-debug"
RELEASE
=
0
fi
echo
"EXTRA_CFLAGS= -g
${
EXTRA_CFLAGS
}
"
>>
config.mak
...
...
@@ -300,7 +311,7 @@ make $MAKEFLAGS
############
cd
../..
&&
mkdir
-p
build-android-
${
TARGET_TUPLE
}
&&
cd
build-android-
${
TARGET_TUPLE
}
if
[
$#
-eq
1
]
&&
[
"
$1
"
=
"jni"
]
;
then
if
[
"
$JNI
"
=
1
]
;
then
CLEAN
=
"jniclean"
TARGET
=
"vlc-android/obj/local/
${
ANDROID_ABI
}
/libvlcjni.so"
else
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment