Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,5 @@ include/bard_version.h
main/bard_main.o
.time-stamp
FileList
/autom4te.cache
*~
3 changes: 2 additions & 1 deletion config/config.in
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ CPPFLAGS = @CPPFLAGS@
SHFLAGS = @SHFLAGS@
LDFLAGS = @LDFLAGS@
PLATFORM_DEFS = @PLATFORM_DEFS@
SDK = @SDK@

AR = @AR@
RANLIB = @RANLIB@
Expand All @@ -32,7 +33,7 @@ EPUBDEFS = @EPUBDEFS@
HBINCS = @HBINCS@
HBLIBS = @HBLIBS@
HBDEFS = @HBDEFS@
SDLINCLUDES = -I/usr/include/SDL ${EPUBDEFS} ${HBINCS} ${HBDEFS}
SDLINCLUDES = $(shell ${SDK}/usr/bin/pkg-config --cflags-only-I sdl) ${EPUBDEFS} ${HBINCS} ${HBDEFS}
SDLLIBS = @SDLLIBS@ ${EPUBLIBS} ${HBLIBS}

DEFAULTFONT = @DEFAULTFONT@
Expand Down
186 changes: 134 additions & 52 deletions configure
Original file line number Diff line number Diff line change
Expand Up @@ -632,6 +632,7 @@ HBDEFS
EPUBDEFS
EPUBLIBS
SDLLIBS
FLITELIBSDIR
FLITEDIR
PLATFORM_DEFS
AUDIOLIBS
Expand All @@ -643,6 +644,7 @@ SHFLAGS
OTHERLIBS
HOST_CPU
HOST_OS
SDK
VOXDEFS
LEXDEFS
NM
Expand Down Expand Up @@ -700,7 +702,6 @@ infodir
docdir
oldincludedir
includedir
runstatedir
localstatedir
sharedstatedir
sysconfdir
Expand Down Expand Up @@ -740,7 +741,8 @@ CFLAGS
LDFLAGS
LIBS
CPPFLAGS
CPP'
CPP
SDK'


# Initialize some variables set by options.
Expand Down Expand Up @@ -779,7 +781,6 @@ datadir='${datarootdir}'
sysconfdir='${prefix}/etc'
sharedstatedir='${prefix}/com'
localstatedir='${prefix}/var'
runstatedir='${localstatedir}/run'
includedir='${prefix}/include'
oldincludedir='/usr/include'
docdir='${datarootdir}/doc/${PACKAGE}'
Expand Down Expand Up @@ -1032,15 +1033,6 @@ do
| -silent | --silent | --silen | --sile | --sil)
silent=yes ;;

-runstatedir | --runstatedir | --runstatedi | --runstated \
| --runstate | --runstat | --runsta | --runst | --runs \
| --run | --ru | --r)
ac_prev=runstatedir ;;
-runstatedir=* | --runstatedir=* | --runstatedi=* | --runstated=* \
| --runstate=* | --runstat=* | --runsta=* | --runst=* | --runs=* \
| --run=* | --ru=* | --r=*)
runstatedir=$ac_optarg ;;

-sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb)
ac_prev=sbindir ;;
-sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \
Expand Down Expand Up @@ -1178,7 +1170,7 @@ fi
for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \
datadir sysconfdir sharedstatedir localstatedir includedir \
oldincludedir docdir infodir htmldir dvidir pdfdir psdir \
libdir localedir mandir runstatedir
libdir localedir mandir
do
eval ac_val=\$$ac_var
# Remove trailing slashes.
Expand Down Expand Up @@ -1331,7 +1323,6 @@ Fine tuning of the installation directories:
--sysconfdir=DIR read-only single-machine data [PREFIX/etc]
--sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
--localstatedir=DIR modifiable single-machine data [PREFIX/var]
--runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
--libdir=DIR object code libraries [EPREFIX/lib]
--includedir=DIR C header files [PREFIX/include]
--oldincludedir=DIR C header files for non-gcc [/usr/include]
Expand Down Expand Up @@ -1386,6 +1377,7 @@ Some influential environment variables:
CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if
you have headers in a nonstandard directory <include dir>
CPP C preprocessor
SDK path to your SDK directory for cross-compilation

Use these variables to override the choices made by `configure' or to help
it to find libraries and programs with nonstandard names/locations.
Expand Down Expand Up @@ -2167,6 +2159,7 @@ ac_compiler_gnu=$ac_cv_c_compiler_gnu




ac_aux_dir=
for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do
if test -f "$ac_dir/install-sh"; then
Expand Down Expand Up @@ -2306,7 +2299,6 @@ test -n "$target_alias" &&
test "$program_prefix$program_suffix$program_transform_name" = \
NONENONEs,x,x, &&
program_prefix=${target_alias}-

ac_ext=c
ac_cpp='$CPP $CPPFLAGS'
ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
Expand Down Expand Up @@ -4020,6 +4012,7 @@ case "$target_cpu" in
;;
esac
TARGET_OS=$target_os
TARGET_PLATFORM=$target_cpu-$target_os

M68KCC=
M68KCLAGS=
Expand Down Expand Up @@ -4149,6 +4142,7 @@ esac




case "$host_cpu" in
i386|i486|i586|i686)
HOST_CPU=i386
Expand Down Expand Up @@ -4398,7 +4392,7 @@ fi
PLATFORM_DEFS=


if test "x$FLITEDIR" = x; then
if test "x$FLITEDIR" = x && test "$build_os" = "$target_os"; then
if test -f /usr/include/flite.h; then
FLITEDIR=/usr
fi
Expand All @@ -4409,11 +4403,26 @@ if test "x$FLITEDIR" = x; then
fi
fi
if test "x$FLITEDIR" = x; then
as_fn_error $? "\"Cannot locate CMU Flite specify FLITEDIR explicitly.\"" "$LINENO" 5
if test -f "$PWD/flite/include/flite.h"; then
FLITEDIR="$PWD/flite"
fi
fi
if test "x$FLITEDIR" = x; then
as_fn_error $? "Cannot locate CMU Flite specify FLITEDIR explicitly." "$LINENO" 5
fi
echo CMU Flite found in $FLITEDIR


if test -f /usr/local/lib/libflite.a && test "$build_os" = "$target_os"; then
FLITELIBSDIR="/usr/local/lib"
elif test -f $FLITEDIR/build/$TARGET_PLATFORM/lib/libflite.a; then
FLITELIBSDIR="$FLITEDIR/build/$TARGET_PLATFORM/lib"
else
as_fn_error $? "Cannot locate CMU Flite libraries, please configure and build flite pkg dependency." "$LINENO" 5
fi
echo CMU Flite libraries found in $FLITELIBSDIR


ac_fn_c_check_header_mongrel "$LINENO" "zip.h" "ac_cv_header_zip_h" "$ac_includes_default"
if test "x$ac_cv_header_zip_h" = xyes; then :
EPUBDEFS=-DBARD_EPUB
Expand All @@ -4424,7 +4433,7 @@ fi
ac_fn_c_check_header_mongrel "$LINENO" "harfbuzz/hb.h" "ac_cv_header_harfbuzz_hb_h" "$ac_includes_default"
if test "x$ac_cv_header_harfbuzz_hb_h" = xyes; then :
HBDEFS=-DBARD_HARFBUZZ
HBINCS="-I/usr/include/freetype2"
HBINCS="$($SDK/usr/bin/pkg-config --cflags-only-I freetype2)"
HBLIBS="-lfreetype -lcairo"
fi

Expand Down Expand Up @@ -4466,62 +4475,133 @@ fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_harfbuzz_hb_icu_get_unicode_funcs" >&5
$as_echo "$ac_cv_lib_harfbuzz_hb_icu_get_unicode_funcs" >&6; }
if test "x$ac_cv_lib_harfbuzz_hb_icu_get_unicode_funcs" = xyes; then :
HBLIBS+=" -lharfbuzz"
HBDEFS+=" -DBARD_HARFBUZZ_ICU"
HBLIBS+=" -lharfbuzz"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for hb_icu_get_unicode_funcs in -lharfbuzz-icu" >&5
$as_echo_n "checking for hb_icu_get_unicode_funcs in -lharfbuzz-icu... " >&6; }
if ${ac_cv_lib_harfbuzz_icu_hb_icu_get_unicode_funcs+:} false; then :
$as_echo_n "(cached) " >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lharfbuzz-icu $LIBS"
cat confdefs.h - <<_ACEOF >conftest.$ac_ext
/* end confdefs.h. */

/* Override any GCC internal prototype to avoid an error.
Use char because int might match the return type of a GCC
builtin and then its argument prototype would still apply. */
#ifdef __cplusplus
extern "C"
#endif
char hb_icu_get_unicode_funcs ();
int
main ()
{
return hb_icu_get_unicode_funcs ();
;
return 0;
}
_ACEOF
if ac_fn_c_try_link "$LINENO"; then :
ac_cv_lib_harfbuzz_icu_hb_icu_get_unicode_funcs=yes
else
HBLIBS+=" -lharfbuzz -lharfbuzz-icu"
ac_cv_lib_harfbuzz_icu_hb_icu_get_unicode_funcs=no
fi
rm -f core conftest.err conftest.$ac_objext \
conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_harfbuzz_icu_hb_icu_get_unicode_funcs" >&5
$as_echo "$ac_cv_lib_harfbuzz_icu_hb_icu_get_unicode_funcs" >&6; }
if test "x$ac_cv_lib_harfbuzz_icu_hb_icu_get_unicode_funcs" = xyes; then :
HBDEFS+=" -DBARD_HARFBUZZ_ICU"
HBLIBS+=" -lharfbuzz -lharfbuzz-icu"
else
{ $as_echo "$as_me:${as_lineno-$LINENO}: no ICU support found in harfbuzz" >&5
$as_echo "$as_me: no ICU support found in harfbuzz" >&6;}
HBLIBS+=" -lharfbuzz"
fi

fi


if ! test -f /usr/include/SDL/SDL.h; then
as_fn_error $? "\"Cannot locate /usr/include/SDL/SDL.h.\"" "$LINENO" 5
ac_fn_c_check_header_mongrel "$LINENO" "SDL/SDL.h" "ac_cv_header_SDL_SDL_h" "$ac_includes_default"
if test "x$ac_cv_header_SDL_SDL_h" = xyes; then :

else
as_fn_error $? "Cannot locate SDL/SDL.h" "$LINENO" 5
fi



SDLLIBS="-lSDL_mixer -lSDL"

if ! test -f /usr/include/SDL/SDL_ttf.h; then
as_fn_error $? "\"Cannot locate /usr/include/SDL/SDL_ttf.h.\"" "$LINENO" 5
ac_fn_c_check_header_mongrel "$LINENO" "SDL/SDL.h" "ac_cv_header_SDL_SDL_h" "$ac_includes_default"
if test "x$ac_cv_header_SDL_SDL_h" = xyes; then :

else
as_fn_error $? "Cannot locate SDL/SDL_ttf.h" "$LINENO" 5
fi



SDLLIBS="-lSDL_ttf $SDLLIBS"

if ! test "x$EPUBDEFS" = x; then
if test -f /usr/include/SDL/SDL_image.h -a -f /usr/include/SDL/SDL_rotozoom.h
then
echo "EPUB (with SDL images) support found"
SDLLIBS="-lSDL_gfx -lSDL_image $SDLLIBS"
EPUBDEFS="-DBARD_EPUB_IMAGES $EPUBDEFS"
else
echo "EPUB (without SDL images) support found"
fi
for ac_header in SDL/SDL_image.h SDL/SDL_rotozoom.h
do :
as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh`
ac_fn_c_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default"
if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
cat >>confdefs.h <<_ACEOF
#define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
_ACEOF
{ $as_echo "$as_me:${as_lineno-$LINENO}: EPUB (with SDL images) support found" >&5
$as_echo "$as_me: EPUB (with SDL images) support found" >&6;}
SDLLIBS="-lSDL_gfx -lSDL_image $SDLLIBS"
EPUBDEFS="-DBARD_EPUB_IMAGES $EPUBDEFS"
else
echo "No EPUB support found (missing libzip)"
{ $as_echo "$as_me:${as_lineno-$LINENO}: EPUB (without SDL images) support found" >&5
$as_echo "$as_me: EPUB (without SDL images) support found" >&6;}
fi

done

else
{ $as_echo "$as_me:${as_lineno-$LINENO}: No EPUB support found (missing libzip)" >&5
$as_echo "$as_me: No EPUB support found (missing libzip)" >&6;}
fi






if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /usr/share/fonts -name LiberationSerif-Regular.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /usr/share/fonts -name DejaVuSerif.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /usr/share/fonts -name DroidSerif.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /system/fonts -name DroidSerif.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"


if test "$build_os" = "$target_os"
then
DEFAULTFONT=`find /usr/share/fonts -name NtmRR4nh.ttf | head -1`
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /usr/share/fonts -name LiberationSerif-Regular.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /usr/share/fonts -name DejaVuSerif.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /usr/share/fonts -name DroidSerif.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /system/fonts -name DroidSerif.ttf | head -1`
fi
if test "x$DEFAULTFONT" = "x"
then
DEFAULTFONT=`find /usr/share/fonts -name NtmRR4nh.ttf | head -1`
fi
fi
if test "x$DEFAULTFONT" = "x"; then
echo No installed font found
Expand Down Expand Up @@ -4573,6 +4653,8 @@ fi





ac_config_files="$ac_config_files config/config config/system.mak"

cat >confcache <<\_ACEOF
Expand Down Expand Up @@ -5175,7 +5257,7 @@ config.status
configured by $0, generated by GNU Autoconf 2.69,
with options \\"\$ac_cs_config\\"

Copyright (C) 2012 Free Software Foundation, Inc.
Copyright (C) Free Software Foundation, Inc.
This config.status script is free software; the Free Software Foundation
gives unlimited permission to copy, distribute and modify it."

Expand Down
Loading