iverilog/configure.in

148 lines
3.3 KiB
Plaintext
Raw Normal View History

1999-04-25 23:54:33 +02:00
dnl Process this file with autoconf to produce a configure script.
AC_INIT(netlist.h)
AC_CONFIG_HEADER(config.h)
2003-09-30 03:33:13 +02:00
AC_CONFIG_HEADER(_pli_types.h)
1999-04-25 23:54:33 +02:00
2004-09-28 00:34:10 +02:00
AC_CANONICAL_HOST
1999-04-25 23:54:33 +02:00
dnl Checks for programs.
1999-07-03 22:50:28 +02:00
AC_PROG_CC
1999-04-25 23:54:33 +02:00
AC_PROG_CXX
AC_CHECK_TOOL(STRIP, strip, true)
2001-04-26 18:12:29 +02:00
AC_CHECK_PROGS(XGPERF,gperf,none)
if test "$XGPERF" = "none"
then
2004-01-19 00:34:00 +01:00
echo ""
echo "*** Warning: No suitable gperf found. ***"
echo " The gperf package is essential for building ivl from"
echo " CVS sources, or modifying the parse engine of ivl itself."
echo " You can get away without it when simply building from"
echo " snapshots or major releases."
echo ""
2001-04-26 18:12:29 +02:00
fi
2001-01-16 03:44:17 +01:00
2001-12-30 18:20:33 +01:00
AC_CHECK_PROGS(LEX,flex,none)
if test "$LEX" = "none"
then
echo "*** Error: No suitable flex found. ***"
echo " Please install the 'flex' package."
exit 1
fi
AC_CHECK_PROGS(YACC,bison,none)
if test "$YACC" = "none"
then
echo "*** Error: No suitable bison found. ***"
echo " Please install the 'bison' package."
exit 1
fi
2003-03-08 21:58:55 +01:00
AC_EXEEXT
AC_SUBST(EXEEXT)
2004-02-15 04:17:36 +01:00
# Combined check for Microsoft-related bogosities; sets WIN32 if found
AX_WIN32
# vvp32 is by default disabled
#enable_vvp32=no
AC_SUBST(enable_vvp32)
2003-03-08 21:58:55 +01:00
2001-01-16 03:44:17 +01:00
AC_LANG_CPLUSPLUS
AC_CHECK_HEADERS(getopt.h malloc.h inttypes.h libiberty.h iosfwd sys/wait.h)
2001-01-16 03:44:17 +01:00
2003-02-20 01:49:24 +01:00
AC_CHECK_LIB(z, gzwrite)
2003-09-13 03:28:47 +02:00
AC_CHECK_LIB(z, gzwrite, HAVE_LIBZ=yes, HAVE_LIBZ=no)
AC_SUBST(HAVE_LIBZ)
2003-03-08 21:58:55 +01:00
if test "$WIN32" = "yes"; then
AC_CHECK_LIB(bz2, main)
else
2003-02-20 01:49:24 +01:00
AC_CHECK_LIB(bz2, BZ2_bzdopen)
2003-03-08 21:58:55 +01:00
fi
2003-02-20 01:49:24 +01:00
AC_MSG_CHECKING(for sys/times)
AC_TRY_LINK(
#include <unistd.h>
#include <sys/times.h>
,{clock_t a = times(0)/sysconf(_SC_CLK_TCK);},
do_times=yes
AC_DEFINE(HAVE_TIMES,1),
do_times=no
)
AC_MSG_RESULT($do_times)
2000-12-15 06:45:25 +01:00
# --
# Look for a dl library to use. First look for the standard dlopen
# functions, and failing that look for the HP specific shl_load function.
AC_CHECK_HEADERS(dlfcn.h dl.h, break)
DLLIB=''
AC_CHECK_LIB(dl,dlopen,[DLLIB=-ldl])
if test -z "$DLLIB" ; then
AC_CHECK_LIB(dld,shl_load,[DLLIB=-ldld])
fi
AC_SUBST(DLLIB)
2000-12-15 06:45:25 +01:00
2001-01-16 03:44:17 +01:00
AC_PROG_INSTALL
AC_LANG_C
2003-03-07 03:44:33 +01:00
AC_C_BIGENDIAN
2000-09-30 05:20:47 +02:00
# $host
2004-09-28 00:34:10 +02:00
AX_LD_EXTRALIBS
2000-12-15 06:45:25 +01:00
2004-09-28 00:34:10 +02:00
# Compiler option for position independent code, needed whan making shared objects.
# CFLAGS inherited by cadpli/Makefile?
AX_C_PICFLAG
2004-09-28 00:34:10 +02:00
# may modify CPPFLAGS and CFLAGS
AX_CPP_PRECOMP
2000-12-15 06:45:25 +01:00
2004-09-28 00:34:10 +02:00
# Linker option used when compiling the target
AX_LD_RDYNAMIC
2000-12-15 06:45:25 +01:00
2004-09-28 00:34:10 +02:00
# linker options when building a shared library
AX_LD_SHAREDLIB_OPTS
2000-12-15 00:38:04 +01:00
#######################
## test for underscores. The vpi module loader needs to know this
## in order to know the name of the start symbol for the .vpi module.
#######################
AX_C_UNDERSCORES_LEADING
AX_C_UNDERSCORES_TRAILING
#######################
## end of test for underscores
#######################
2000-12-15 00:38:04 +01:00
AX_CPP_IDENT
2002-08-12 02:27:10 +02:00
# If not otherwise specified, set the libdir64 variable
# to the same as libdir.
AC_MSG_CHECKING(for libdir64 path)
if test x${libdir64} = x
then
libdir64="${libdir}"
fi
AC_SUBST(libdir64)
AC_MSG_RESULT(${libdir64})
# where to put vpi subdirectories
AC_MSG_CHECKING(for VPI subdirectories)
if test x${vpidir1} = x
then
vpidir1="."
fi
AC_SUBST(vpidir1)
AC_SUBST(vpidir2)
AC_MSG_RESULT(${vpidir1} ${vpidir2})
2002-08-12 02:27:10 +02:00
2005-07-15 01:34:18 +02:00
# XXX disable tgt-fpga for the moment
AC_CONFIG_SUBDIRS(vvp vpi tgt-stub tgt-null tgt-vvp libveriuser cadpli)
2000-12-15 00:38:04 +01:00
AC_OUTPUT(Makefile ivlpp/Makefile driver/Makefile driver-vpi/Makefile tgt-null/Makefile tgt-verilog/Makefile tgt-pal/Makefile)