1 dnl Process this file with autoconf to produce a configure script.
3 AC_CONFIG_AUX_DIR(../../config)
4 AM_INIT_AUTOMAKE(sidcomp,0.1)
5 AM_CONFIG_HEADER(config.h:config.in)
17 AC_CHECK_LIB(pthread, pthread_create)
18 AC_CHECK_FUNCS(getopt)
20 dnl Need extra defines for Solaris threads
23 # Note: If _REENTRANT isn't defined, then Solaris
24 # won't define thread-safe library routines.
25 cpu_defs="-D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS"
32 dnl Check if we need libintl.
33 AC_MSG_CHECKING([whether libintl is required for gettext])
36 AC_TRY_LINK_FUNC([textdomain],
37 [INTLLIBS=; AC_MSG_RESULT([no])],
38 [INTLLIBS='-L../../../intl -lintl']; AC_MSG_RESULT([yes]))
41 dnl Perform --target/--enable-targets processing.
44 # Add per-target-family subdirectories here
48 if test $sidtarget_arm -eq 1; then
49 cpu_subdirs="$cpu_subdirs arm7t"
50 AC_CONFIG_SUBDIRS(arm7t)
52 if test $sidtarget_m32r -eq 1; then
53 cpu_subdirs="$cpu_subdirs m32r"
54 AC_CONFIG_SUBDIRS(m32r)
56 if test $sidtarget_mep -eq 1; then
57 cpu_subdirs="$cpu_subdirs mep"
58 AC_CONFIG_SUBDIRS(mep)
60 if test $sidtarget_mt -eq 1; then
61 cpu_subdirs="$cpu_subdirs mt"
64 if test $sidtarget_sh -eq 1 -o $sidtarget_sh64 -eq 1; then
65 cpu_subdirs="$cpu_subdirs sh"
68 if test $sidtarget_xstormy16 -eq 1; then
69 cpu_subdirs="$cpu_subdirs xstormy16"
70 AC_CONFIG_SUBDIRS(xstormy16)
73 for dir in $cpu_subdirs; do
74 cpu_libs="$cpu_libs $dir/lib$dir.la"
75 cpu_incl="$cpu_incl -I$srcdir/$dir"
85 dnl Look for GUILE in install tree
86 AC_CHECK_PROGS(GUILE, guile, false)
91 gcc_AC_CHECK_DECLS([vasprintf asprintf basename getopt], [], [], [
97 AC_OUTPUT(Makefile CGEN.sh)