* Makefile.in (bindir, libdir, datadir, mandir, infodir, includedir,
[deliverable/binutils-gdb.git] / sim / configure.in
CommitLineData
1ffd292b
C
1dnl Process this file with autoconf to produce a configure script.
2AC_PREREQ(2.3)dnl
3AC_INIT(Makefile.in)
b0c9f026 4
ed086b0a
FF
5AC_PROG_CC
6AC_CHECK_TOOL(AR, ar)
7AC_CHECK_TOOL(RANLIB, ranlib, :)
8
1ffd292b
C
9AC_CONFIG_AUX_DIR(`cd $srcdir;pwd`/..)
10AC_CANONICAL_SYSTEM
11AC_ARG_PROGRAM
6f07ee29
MM
12AC_PROG_CC
13AC_SUBST(CFLAGS)
14AC_SUBST(HDEFINES)
15AR=${AR-ar}
16AC_SUBST(AR)
17AC_PROG_RANLIB
18
19# Put a plausible default for CC_FOR_BUILD in Makefile.
20AC_C_CROSS
21if test "x$cross_compiling" = "xno"; then
22 CC_FOR_BUILD='$(CC)'
23else
24 CC_FOR_BUILD=gcc
25fi
26AC_SUBST(CC_FOR_BUILD)
b0c9f026 27
e218c1be
MM
28# The PowerPC simulator uses the GCC extension long long as well as
29# ANSI prototypes, so don't enable it for random host compilers
30# unless asked to.
31
f50dc105
MM
32AC_ARG_ENABLE(sim-powerpc,
33[ --enable-sim-powerpc ],
34[case "${enableval}" in
35yes) powerpc_sim=yes ;;
36no) powerpc_sim=no ;;
37*) AC_MSG_ERROR(bad value ${enableval} given for sim-powerpc option) ;;
38esac],[if test x"$GCC" != x""; then powerpc_sim=yes; else powerpc_sim=no; fi])
39
b0c9f026
SC
40# WHEN ADDING ENTRIES TO THIS MATRIX:
41# Make sure that the left side always has two dashes. Otherwise you
42# can get spurious matches. Even for unambiguous cases, do this as a
43# convention, else the table becomes a real mess to understand and maintain.
44
45case "${target}" in
d32033ad 46 arm*-*-*) sim_target=arm ;;
1ffd292b 47 h8300*-*-*) sim_target=h8300 ;;
47dba87a 48 h8500-*-*) sim_target=h8500 ;;
595a6ec3 49 mips*-*-*) sim_target=mips ;;
6c19c2ef 50 sh*-*-*) sim_target=sh ;;
5ea7fa7a
MM
51 powerpc*-*-eabi* | powerpc*-*-solaris* | powerpc*-*-sysv4* | powerpc*-*-elf* )
52 if test x"$powerpc_sim" = x"yes"; then sim_target=ppc; fi ;;
6c19c2ef 53 w65-*-*) sim_target=w65 ;;
1ffd292b 54 z8k*-*-*) sim_target=z8k ;;
d4663715
RS
55 sparc*-*-*) case "${host}" in # don't build for non Unix systems
56 *-*-go32) sim_target=none ;;
57 *-*-winnt) sim_target=none ;;
58 *-*-cygwin32) sim_target=none ;;
aac160d2
ILT
59 *)
60 # The SPARC simulator can only be compiled
61 # by gcc. Highly bogus, but just skip
62 # building it for now.
63 if test "${GCC}" = "yes"; then
64 sim_target=erc32
65 else
66 sim_target=non
67 fi
68 ;;
d4663715 69 esac ;;
47dba87a 70 *) sim_target=none ;;
b0c9f026
SC
71esac
72
73configdirs=${sim_target}
1ffd292b 74AC_CONFIG_SUBDIRS($configdirs)
b0c9f026 75
1ffd292b 76AC_OUTPUT(Makefile)
23de525f
PS
77
78exit 0
This page took 0.140374 seconds and 4 git commands to generate.