Included libjte in GNU xorriso

This commit is contained in:
2010-10-15 12:16:12 +00:00
parent 3ff054d60f
commit b7030ca35b
8 changed files with 143 additions and 70 deletions

View File

@ -215,7 +215,8 @@ then
fi
AH_TEMPLATE([Libisofs_with_zliB], [Define to use compression via libz])
AH_TEMPLATE([Libisofs_with_zliB], [Define to use compression via zlib])
AH_TEMPLATE([LIBJTE_WITH_ZLIB], [Allow libjte to use zlib])
AC_ARG_ENABLE(zlib,
[ --enable-zlib Enable use of zlib by libisofs, default=yes],
, enable_zlib=yes)
@ -225,41 +226,79 @@ dnl If not, erase this macro which would enable use of compress2() and others.
dnl Linking fails on SuSE 9.0 because zlib has compress2() but lacks
dnl compressBound(). So compressBound is the more modern thing to test.
dnl The empty parameter after "compressBound" causes -lz.
ZLIB_DEF="-DLibisofs_with_zliB"
ZLIB_DEF=yes
AC_CHECK_HEADER(zlib.h, AC_CHECK_LIB(z, compressBound, , ZLIB_DEF= ), ZLIB_DEF= )
else
ZLIB_DEF=
fi
if test x$ZLIB_DEF = x-DLibisofs_with_zliB
if test x$ZLIB_DEF = xyes
then
AC_DEFINE([Libisofs_with_zliB], [])
AC_DEFINE([LIBJTE_WITH_ZLIB], [])
fi
# libjte source is included in GNU xorriso. Enable it if zlib is enabled.
AH_TEMPLATE([Xorriso_with_libjtE],
[Define to use Jigdo Template Extraction via libjte])
AH_TEMPLATE([Libisofs_with_libjtE],
[Define to use Jigdo Template Extraction via libjte])
AC_ARG_ENABLE(libjte,
[ --enable-libjte Enable use of libjte by xorriso, default=yes],
, enable_libjte=yes)
if test "x$enable_libjte" = xyes; then
LIBJTE_DEF=yes
AC_CHECK_HEADER(libjte/libjte.h, AC_CHECK_LIB(jte, libjte_new, , LIBJTE_DEF= ), LIBJTE_DEF= )
else
LIBJTE_DEF=
fi
if test x$LIBJTE_DEF = xyes
if test x$ZLIB_DEF = xyes
then
AC_DEFINE([Xorriso_with_libjtE], [])
AC_DEFINE([Libisofs_with_libjtE], [])
LIBJTE_DEF="-DXorriso_with_libjtE -DLibisofs_with_libjtE"
# >>> Only until built-in libjte becomes default with xorriso-standalone
AH_TEMPLATE([Xorriso_jte_standalonE], [Preliminary switch])
AC_DEFINE([Xorriso_jte_standalonE], [])
LIBJTE_DEF=yes
echo "enabled built-in libjte"
else
LIBJTE_DEF=
echo "disabled libjte because zlib not enabled or not available"
fi
AH_TEMPLATE([THREADED_CHECKSUMS],
[Define to use multi-threading in built-in libjte])
AC_ARG_ENABLE(jtethreads,
[ --enable-jtethreads Enable multi-threading in libjte, default=yes],
, enable_jtethreads=yes)
if test x$LIBJTE_DEF = xyes
then
if test "x$enable_jtethreads" = xyes; then
AC_DEFINE([THREADED_CHECKSUMS], [])
echo "enabled multi-threading in libjte"
else
echo "disabled multi-threading in libjte"
fi
fi
AH_TEMPLATE([LIBJTE_WITH_LIBBZ2],
[Define to use libbz2 by built-in libjte])
AC_ARG_ENABLE(libbz2,
[ --enable-libbz2 Enable use of libbz2 by libjte, default=yes],
, enable_libbz2=yes)
if test "x$enable_libbz2" = xyes -a x$LIBJTE_DEF = xyes ; then
dnl Check whether there is the header for libbz2.
BZIP2_DEF=yes
AC_CHECK_HEADER(bzlib.h, AC_CHECK_LIB(bz2, BZ2_bzCompressInit, , BZIP2_DEF= ), BZIP2_DEF= )
else
BZIP2_DEF=
fi
if test x$BZIP2_DEF = xyes
then
AC_DEFINE([LIBJTE_WITH_LIBBZ2], [])
BZIP2_DEF="-DLIBJTE_WITH_LIBBZ2"
fi
AH_TEMPLATE([Libburn_use_libcdiO], [Define to use libcdio as system adapter])
AC_ARG_ENABLE(libcdio,
[ --enable-libcdio Enable EXPERIMENTAL use of libcdio as system adapter, default=no],
[ --enable-libcdio Enable EXPERIMENTAL use of libcdio as system adapter, default=no],
, enable_libcdio=no)
if test x$enable_libcdio = xyes; then
dnl Check whether there is libcdio-devel and libcdio-runtime.