Skip to content

Commit

Permalink
[build] Android compilation, bug-fixes (#1502)
Browse files Browse the repository at this point in the history
  • Loading branch information
jcsilva authored and danpovey committed Mar 19, 2017
1 parent eac0baa commit 25ca8e4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions src/configure
Original file line number Diff line number Diff line change
Expand Up @@ -952,7 +952,7 @@ do
static_fst=true;
dynamic_kaldi=false;
MATHLIB='OPENBLAS';
ANDROIDINCDIR=`read_dirname $1`;
ANDROIDINC=`read_dirname $1`;
shift;;
*) echo "Unknown argument: $1, exiting"; usage; exit 1 ;;
esac
Expand Down Expand Up @@ -1076,7 +1076,7 @@ echo >> kaldi.mk
echo "Doing OS specific configurations ..."

if $android ; then
if [ -z $ANDROIDINCDIR ] ; then
if [ -z $ANDROIDINC ] ; then
failure "--android-incdir must be specified for android builds."
fi

Expand All @@ -1097,7 +1097,7 @@ if $android ; then
OPENBLASLIBS="$OPENBLASROOT/lib/libopenblas.a $OPENBLASROOT/lib/libclapack.a $OPENBLASROOT/lib/liblapack.a $OPENBLASROOT/lib/libblas.a $OPENBLASROOT/lib/libf2c.a"
echo "OPENBLASINC = $OPENBLASROOT/include" >> kaldi.mk
echo "OPENBLASLIBS = $OPENBLASLIBS" >> kaldi.mk
echo "ANDROIDINCDIR = $ANDROIDINCDIR" >> kaldi.mk
echo "ANDROIDINC = $ANDROIDINC" >> kaldi.mk

cat makefiles/android_openblas.mk >> kaldi.mk

Expand Down
2 changes: 1 addition & 1 deletion src/makefiles/android_openblas.mk
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ CXXFLAGS = -std=c++11 -I.. -I$(OPENFSTINC) $(EXTRA_CXXFLAGS) \
-Wall -Wno-sign-compare -Wno-unused-local-typedefs \
-Wno-deprecated-declarations -Winit-self -Wno-mismatched-tags \
-DKALDI_DOUBLEPRECISION=$(DOUBLE_PRECISION) \
-DHAVE_EXECINFO_H=1 -DHAVE_CXXABI_H -DHAVE_OPENBLAS -DANDROID_BUILD \
-DHAVE_CXXABI_H -DHAVE_OPENBLAS -DANDROID_BUILD \
-I$(OPENBLASINC) -I$(ANDROIDINC) -ftree-vectorize -mfloat-abi=hard \
-mfpu=neon -mhard-float -D_NDK_MATH_NO_SOFTFP=1 -pthread \
-g # -O0 -DKALDI_PARANOID
Expand Down

0 comments on commit 25ca8e4

Please sign in to comment.