|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# configure.ac -- autoconf configuration for the LZO library
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# This file is part of the LZO data compression library.
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# Copyright (C) 1996-2008 Markus Franz Xaver Johannes Oberhumer
|
|
kusano |
7d535a |
# All Rights Reserved.
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# The LZO library is free software; you can redistribute it and/or
|
|
kusano |
7d535a |
# modify it under the terms of the GNU General Public License as
|
|
kusano |
7d535a |
# published by the Free Software Foundation; either version 2 of
|
|
kusano |
7d535a |
# the License, or (at your option) any later version.
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# The LZO library is distributed in the hope that it will be useful,
|
|
kusano |
7d535a |
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
kusano |
7d535a |
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
kusano |
7d535a |
# GNU General Public License for more details.
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# You should have received a copy of the GNU General Public License
|
|
kusano |
7d535a |
# along with the LZO library; see the file COPYING.
|
|
kusano |
7d535a |
# If not, write to the Free Software Foundation, Inc.,
|
|
kusano |
7d535a |
# 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
# Markus F.X.J. Oberhumer
|
|
kusano |
7d535a |
# <markus@oberhumer.com></markus@oberhumer.com>
|
|
kusano |
7d535a |
# http://www.oberhumer.com/opensource/lzo/
|
|
kusano |
7d535a |
#
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# /***********************************************************************
|
|
kusano |
7d535a |
# // Init
|
|
kusano |
7d535a |
# ************************************************************************/
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_COPYRIGHT([Copyright (C) 1996-2008 Markus Franz Xaver Johannes Oberhumer.
|
|
kusano |
7d535a |
All Rights Reserved.
|
|
kusano |
7d535a |
This configure script may be copied, distributed and modified under the
|
|
kusano |
7d535a |
terms of the GNU General Public License; see COPYING for more details.])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_PREREQ(2.59)
|
|
kusano |
7d535a |
AC_INIT([lzo],[2.03],[markus@oberhumer.com])
|
|
kusano |
7d535a |
AC_MSG_NOTICE([Configuring LZO $PACKAGE_VERSION])
|
|
kusano |
7d535a |
AC_CONFIG_SRCDIR(src/lzo_init.c)
|
|
kusano |
7d535a |
AC_CONFIG_AUX_DIR(autoconf)
|
|
kusano |
7d535a |
AC_PREFIX_DEFAULT(/usr/local)
|
|
kusano |
7d535a |
AC_CANONICAL_BUILD
|
|
kusano |
7d535a |
AC_CANONICAL_HOST
|
|
kusano |
7d535a |
AC_CANONICAL_TARGET
|
|
kusano |
7d535a |
AM_MAINTAINER_MODE
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
if test -z "$ac_abs_top_srcdir"; then
|
|
kusano |
7d535a |
_AC_SRCPATHS(.)
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
if test -r .Conf.settings1; then
|
|
kusano |
7d535a |
. ./.Conf.settings1
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_PROG_CC
|
|
kusano |
7d535a |
AC_PROG_CPP
|
|
kusano |
7d535a |
mfx_PROG_CPPFLAGS
|
|
kusano |
7d535a |
AC_C_CONST
|
|
kusano |
7d535a |
mfx_LZO_CHECK_ENDIAN
|
|
kusano |
7d535a |
AC_SYS_LARGEFILE
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AM_INIT_AUTOMAKE
|
|
kusano |
7d535a |
AC_CONFIG_HEADERS([config.h:config.hin])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_ENABLE_STATIC
|
|
kusano |
7d535a |
AC_DISABLE_SHARED
|
|
kusano |
7d535a |
AC_PROG_LIBTOOL
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# /***********************************************************************
|
|
kusano |
7d535a |
# // Checks for assembler
|
|
kusano |
7d535a |
# ************************************************************************/
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_ARG_ENABLE(asm, AS_HELP_STRING(--disable-asm,disable assembly versions))
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
asm_arch=
|
|
kusano |
7d535a |
asm_dir=
|
|
kusano |
7d535a |
asm_msg_amd64=no
|
|
kusano |
7d535a |
asm_msg_i386=no
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
case $host_cpu in
|
|
kusano |
7d535a |
amd64 | x86_64) asm_arch="amd64"; asm_dir="asm/amd64/src_gas/elf64" ;;
|
|
kusano |
7d535a |
i?86) asm_arch="i386"; asm_dir="asm/i386/src_gas" ;;
|
|
kusano |
7d535a |
*) enable_asm=no ;;
|
|
kusano |
7d535a |
esac
|
|
kusano |
7d535a |
LZO_ASM_VPATH=
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_MSG_CHECKING([whether to build assembly versions])
|
|
kusano |
7d535a |
if test "X$enable_asm" != Xno; then
|
|
kusano |
7d535a |
mfx_compile_S='${CC-cc} -c conftest.S 1>&AS_MESSAGE_LOG_FD'
|
|
kusano |
7d535a |
cat > conftest.S <
|
|
kusano |
7d535a |
#include "$ac_abs_top_srcdir/$asm_dir/lzo1x_f1.S"
|
|
kusano |
7d535a |
EOF
|
|
kusano |
7d535a |
enable_asm=no
|
|
kusano |
7d535a |
if AC_TRY_EVAL(mfx_compile_S); then
|
|
kusano |
7d535a |
if AC_TRY_COMMAND([test -s conftest.$ac_objext]); then
|
|
kusano |
7d535a |
enable_asm=yes
|
|
kusano |
7d535a |
eval asm_msg_$asm_arch="'yes [[$asm_dir]]'"
|
|
kusano |
7d535a |
LZO_ASM_VPATH=":$ac_abs_top_srcdir/$asm_dir"
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
if test "X$enable_asm" = Xno; then
|
|
kusano |
7d535a |
echo "configure: failed program was:" >&AS_MESSAGE_LOG_FD
|
|
kusano |
7d535a |
cat conftest.S >&AS_MESSAGE_LOG_FD
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
rm -rf conftest*
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
AC_MSG_RESULT([$enable_asm])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AM_CONDITIONAL(LZO_USE_ASM, [test "X$enable_asm" != Xno])
|
|
kusano |
7d535a |
AC_SUBST(LZO_ASM_VPATH)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# /***********************************************************************
|
|
kusano |
7d535a |
# // Checks for header files
|
|
kusano |
7d535a |
# ************************************************************************/
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
mfx_ACC_CHECK_HEADERS
|
|
kusano |
7d535a |
dnl AC_CHECK_HEADERS([sys/param.h sys/resource.h sys/times.h])
|
|
kusano |
7d535a |
if test "X$ac_cv_header_limits_h" != Xyes; then
|
|
kusano |
7d535a |
AC_MSG_ERROR([<limits.h> header not found])</limits.h>
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
mfx_CHECK_HEADER_SANE_LIMITS_H
|
|
kusano |
7d535a |
if test "X$mfx_cv_header_sane_limits_h" != Xyes; then
|
|
kusano |
7d535a |
AC_MSG_ERROR([your <limits.h> header is broken - for details see config.log])</limits.h>
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# /***********************************************************************
|
|
kusano |
7d535a |
# // Checks for typedefs and structures
|
|
kusano |
7d535a |
# ************************************************************************/
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_TYPE_OFF_T
|
|
kusano |
7d535a |
AC_CHECK_TYPE(ptrdiff_t,long)
|
|
kusano |
7d535a |
AC_TYPE_SIZE_T
|
|
kusano |
7d535a |
AC_TYPE_SIGNAL
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
mfx_ACC_CHECK_SIZEOF
|
|
kusano |
7d535a |
mfx_CHECK_SIZEOF
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# /***********************************************************************
|
|
kusano |
7d535a |
# // Checks for library functions
|
|
kusano |
7d535a |
# ************************************************************************/
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
mfx_ACC_CHECK_FUNCS
|
|
kusano |
7d535a |
mfx_CHECK_LIB_WINMM
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# /***********************************************************************
|
|
kusano |
7d535a |
# // Write output files
|
|
kusano |
7d535a |
# ************************************************************************/
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
mfx_MINIACC_ACCCHK(["-I$srcdir"],["src/miniacc.h"])
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
if test -r .Conf.settings2; then
|
|
kusano |
7d535a |
. ./.Conf.settings2
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
test "X$CPPFLAGS" != "X" && CPPFLAGS="$CPPFLAGS "
|
|
kusano |
7d535a |
CPPFLAGS="${CPPFLAGS}-DLZO_HAVE_CONFIG_H"
|
|
kusano |
7d535a |
if test "X$enable_asm" != Xno; then
|
|
kusano |
7d535a |
CPPFLAGS="$CPPFLAGS -DLZO_USE_ASM"
|
|
kusano |
7d535a |
fi
|
|
kusano |
7d535a |
AC_SUBST(LZO_CPPFLAGS)
|
|
kusano |
7d535a |
AC_SUBST(LZO_EXTRA_CPPFLAGS)
|
|
kusano |
7d535a |
AC_SUBST(LZO_CFLAGS)
|
|
kusano |
7d535a |
AC_SUBST(LZO_EXTRA_CFLAGS)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
configure_CPPFLAGS=$CPPFLAGS
|
|
kusano |
7d535a |
configure_CFLAGS=$CFLAGS
|
|
kusano |
7d535a |
AC_SUBST(configure_CPPFLAGS)
|
|
kusano |
7d535a |
AC_SUBST(configure_CFLAGS)
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
AC_CONFIG_FILES([Makefile examples/Makefile include/Makefile include/lzo/Makefile lzotest/Makefile minilzo/Makefile src/Makefile tests/Makefile])
|
|
kusano |
7d535a |
AC_OUTPUT
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
## enable AMD64 assembly code : ${asm_msg_amd64}
|
|
kusano |
7d535a |
cat <
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
LZO configuration summary
|
|
kusano |
7d535a |
-------------------------
|
|
kusano |
7d535a |
LZO version : ${PACKAGE_VERSION}
|
|
kusano |
7d535a |
configured for host : ${host_cpu}-${host_vendor}-${host_os}
|
|
kusano |
7d535a |
source code location : ${srcdir}
|
|
kusano |
7d535a |
compiler : ${CC}
|
|
kusano |
7d535a |
preprocessor flags : ${CPPFLAGS}
|
|
kusano |
7d535a |
compiler flags : ${CFLAGS}
|
|
kusano |
7d535a |
build static library : ${enable_static}
|
|
kusano |
7d535a |
build shared library : ${enable_shared}
|
|
kusano |
7d535a |
enable i386 assembly code : ${asm_msg_i386}
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
LZO ${PACKAGE_VERSION} configured.
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Copyright (C) 1996-2008 Markus Franz Xaver Johannes Oberhumer
|
|
kusano |
7d535a |
All Rights Reserved.
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
The LZO library is free software; you can redistribute it and/or
|
|
kusano |
7d535a |
modify it under the terms of the GNU General Public License as
|
|
kusano |
7d535a |
published by the Free Software Foundation; either version 2 of
|
|
kusano |
7d535a |
the License, or (at your option) any later version.
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
The LZO library is distributed in the hope that it will be useful,
|
|
kusano |
7d535a |
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
kusano |
7d535a |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
kusano |
7d535a |
GNU General Public License for more details.
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Markus F.X.J. Oberhumer
|
|
kusano |
7d535a |
<markus@oberhumer.com></markus@oberhumer.com>
|
|
kusano |
7d535a |
http://www.oberhumer.com/opensource/lzo/
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
Type \`make' to build LZO. Type \`make install' to install LZO.
|
|
kusano |
7d535a |
After installing LZO, please read the accompanied documentation.
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
EOF
|
|
kusano |
7d535a |
|
|
kusano |
7d535a |
# vi:ts=4:et
|