2005-11-02 12:50:21 +00:00
|
|
|
dnl Process this file with autoconf to produce a configure script.
|
2007-09-18 23:46:18 +00:00
|
|
|
|
2015-01-08 14:36:54 +00:00
|
|
|
dnl Copyright (C) 2005-2015 Red Hat, Inc.
|
2013-05-14 23:42:12 +00:00
|
|
|
dnl
|
|
|
|
dnl This library is free software; you can redistribute it and/or
|
|
|
|
dnl modify it under the terms of the GNU Lesser General Public
|
|
|
|
dnl License as published by the Free Software Foundation; either
|
|
|
|
dnl version 2.1 of the License, or (at your option) any later version.
|
|
|
|
dnl
|
|
|
|
dnl This library is distributed in the hope that it will be useful,
|
|
|
|
dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
|
|
dnl Lesser General Public License for more details.
|
|
|
|
dnl
|
|
|
|
dnl You should have received a copy of the GNU Lesser General Public
|
|
|
|
dnl License along with this library. If not, see
|
|
|
|
dnl <http://www.gnu.org/licenses/>.
|
2011-07-28 18:56:24 +00:00
|
|
|
|
2008-05-22 15:34:02 +00:00
|
|
|
AC_CONFIG_AUX_DIR([build-aux])
|
2019-04-03 00:21:28 +00:00
|
|
|
dnl Make automake keep quiet about wildcards & other GNUmake-isms
|
2019-04-03 00:01:30 +00:00
|
|
|
AM_INIT_AUTOMAKE([
|
2019-04-03 00:29:03 +00:00
|
|
|
foreign
|
2019-04-03 00:01:30 +00:00
|
|
|
-Wno-portability
|
|
|
|
tar-pax
|
|
|
|
no-dist-gzip
|
|
|
|
dist-xz
|
|
|
|
subdir-objects
|
|
|
|
])
|
2015-06-02 15:17:43 +00:00
|
|
|
dnl older automake's default of ARFLAGS=cru is noisy on newer binutils;
|
|
|
|
dnl we don't really need the 'u' even in older toolchains. Then there is
|
|
|
|
dnl older libtool, which spelled it AR_FLAGS
|
|
|
|
m4_divert_text([DEFAULTS], [: "${ARFLAGS=cr} ${AR_FLAGS=cr}"])
|
2009-07-08 09:51:59 +00:00
|
|
|
|
2013-09-04 16:26:30 +00:00
|
|
|
# Default to using the silent-rules feature when possible. Formatting
|
|
|
|
# chosen to bypass 'grep' checks that cause older automake to warn.
|
|
|
|
# Users (include rpm) can still change the default at configure time.
|
|
|
|
m4_ifndef([AM_SILENT_RULES],
|
|
|
|
[m4_define([AM_SILENT_RULES],[])])AM_SILENT_RULES([yes])
|
2009-07-08 09:51:59 +00:00
|
|
|
|
2005-11-02 12:50:21 +00:00
|
|
|
AC_CANONICAL_HOST
|
|
|
|
|
2007-11-29 17:41:57 +00:00
|
|
|
dnl Checks for C compiler.
|
2005-11-02 13:19:10 +00:00
|
|
|
AC_PROG_CC
|
|
|
|
AC_PROG_INSTALL
|
|
|
|
AC_PROG_CPP
|
2007-09-20 18:40:36 +00:00
|
|
|
|
2020-01-17 11:26:26 +00:00
|
|
|
dnl get 64-int interfaces on 32-bit platforms
|
2020-07-24 12:02:39 +00:00
|
|
|
CFLAGS="$CFLAGS -D_FILE_OFFSET_BITS=64"
|
2020-01-17 11:26:26 +00:00
|
|
|
|
2007-11-29 17:41:57 +00:00
|
|
|
dnl Support building Win32 DLLs (must appear *before* AM_PROG_LIBTOOL)
|
|
|
|
AC_LIBTOOL_WIN32_DLL
|
|
|
|
|
2013-04-02 15:52:31 +00:00
|
|
|
m4_ifndef([LT_INIT], [
|
|
|
|
AM_PROG_LIBTOOL
|
|
|
|
], [
|
|
|
|
LT_INIT([shared disable-static])
|
|
|
|
])
|
2007-03-15 17:24:56 +00:00
|
|
|
AM_PROG_CC_C_O
|
2010-04-27 07:43:55 +00:00
|
|
|
AM_PROG_LD
|
2007-03-15 17:24:56 +00:00
|
|
|
|
2013-09-17 16:25:42 +00:00
|
|
|
dnl Make some notes about which OS we're compiling for, as the lxc and qemu
|
|
|
|
dnl drivers require linux headers, and storage_mpath, dtrace, and nwfilter
|
|
|
|
dnl are also linux specific. The "network" and storage_fs drivers are known
|
2019-04-02 09:04:46 +00:00
|
|
|
dnl to not work on macOS presently, so we also make a note if compiling
|
2013-09-17 16:25:42 +00:00
|
|
|
dnl for that
|
|
|
|
|
2020-01-14 18:34:26 +00:00
|
|
|
with_linux=no with_macos=no with_freebsd=no with_win=no
|
2013-09-17 16:25:42 +00:00
|
|
|
case $host in
|
|
|
|
*-*-linux*) with_linux=yes ;;
|
2019-04-02 09:04:46 +00:00
|
|
|
*-*-darwin*) with_macos=yes ;;
|
2013-09-17 16:25:42 +00:00
|
|
|
*-*-freebsd*) with_freebsd=yes ;;
|
2014-04-28 12:30:36 +00:00
|
|
|
*-*-mingw* | *-*-msvc* ) with_win=yes ;;
|
2013-09-17 16:25:42 +00:00
|
|
|
esac
|
|
|
|
|
|
|
|
AM_CONDITIONAL([WITH_LINUX], [test "$with_linux" = "yes"])
|
|
|
|
AM_CONDITIONAL([WITH_FREEBSD], [test "$with_freebsd" = "yes"])
|
2019-08-21 16:13:19 +00:00
|
|
|
AM_CONDITIONAL([WITH_MACOS], [test "$with_macos" = "yes"])
|
2013-09-17 16:25:42 +00:00
|
|
|
|
2017-05-18 09:55:12 +00:00
|
|
|
|
2005-12-02 12:11:06 +00:00
|
|
|
dnl
|
2010-09-09 15:06:00 +00:00
|
|
|
dnl in case someone want to build static binaries
|
|
|
|
dnl STATIC_BINARIES="-static"
|
2005-12-02 12:11:06 +00:00
|
|
|
dnl
|
2010-09-09 15:06:00 +00:00
|
|
|
STATIC_BINARIES=
|
2008-05-22 15:34:02 +00:00
|
|
|
AC_SUBST([STATIC_BINARIES])
|
2005-12-02 12:11:06 +00:00
|
|
|
|
2010-03-25 17:46:12 +00:00
|
|
|
|
2009-09-10 13:21:10 +00:00
|
|
|
dnl Need to test if pkg-config exists
|
|
|
|
PKG_PROG_PKG_CONFIG
|
|
|
|
|
2009-05-25 11:56:00 +00:00
|
|
|
|
2008-02-28 17:07:37 +00:00
|
|
|
# Set LV_LIBTOOL_OBJDIR to "." or $lt_cv_objdir, depending on whether
|
|
|
|
# we're building shared libraries. This is the name of the directory
|
|
|
|
# in which .o files will be created.
|
|
|
|
test "$enable_shared" = no && lt_cv_objdir=.
|
|
|
|
LV_LIBTOOL_OBJDIR=${lt_cv_objdir-.}
|
2008-05-22 15:34:02 +00:00
|
|
|
AC_SUBST([LV_LIBTOOL_OBJDIR])
|
2008-02-28 17:07:37 +00:00
|
|
|
|
2008-11-21 12:27:11 +00:00
|
|
|
|
2019-10-02 16:04:31 +00:00
|
|
|
GNUmakefile=GNUmakefile
|
|
|
|
m4_if(m4_version_compare([2.61a.100],
|
|
|
|
m4_defn([m4_PACKAGE_VERSION])), [1], [],
|
|
|
|
[AC_CONFIG_LINKS([$GNUmakefile:$GNUmakefile], [],
|
|
|
|
[GNUmakefile=$GNUmakefile])])
|
|
|
|
|
2013-07-31 20:52:16 +00:00
|
|
|
AC_CONFIG_FILES([\
|
2020-06-25 16:15:02 +00:00
|
|
|
Makefile \
|
2017-04-21 14:05:19 +00:00
|
|
|
.color_coded \
|
2020-07-28 15:51:53 +00:00
|
|
|
.ycm_extra_conf.py])
|
2013-07-31 20:52:16 +00:00
|
|
|
AC_OUTPUT
|