Commit | Line | Data |
---|---|---|
b7577823 ILT |
1 | # This file is a shell script that overrides some of the tools and |
2 | # flags used on a host specific basis. | |
60ac749c ILT |
3 | |
4 | # Since the "bfd/hosts" directory is shared by the bfd, opcodes, and | |
5 | # binutils directories (at least), the index to it is also shared. | |
6 | # This is that index. Each configure.in file should source this file | |
7 | # in its per-host part. | |
8 | ||
b7577823 ILT |
9 | # This sets the following shell variables: |
10 | # CC compiler to use (only if needed and not already set) | |
11 | # CFLAGS override CFLAGS (only if needed and not already set) | |
12 | # LDFLAGS override LDFLAGS (only if needed and not already set) | |
13 | # AR archiver to use (only if needed and not already set) | |
14 | # RANLIB ranlib to use (only if needed and not already set) | |
15 | # HDEFINES host specific compiler options | |
16 | # host64 set to true if this is a 64 bit host | |
17 | # HOST_64BIT_TYPE host 64 bit type | |
18 | ||
19 | HDEFINES= | |
20 | host64=false | |
21 | HOST_64BIT_TYPE= | |
22 | ||
60ac749c ILT |
23 | case "${host}" in |
24 | # WHEN ADDING ENTRIES TO THIS MATRIX: | |
25 | # Make sure that the left side always has two dashes. Otherwise you | |
26 | # can get spurious matches. Even for unambiguous cases, do this as a | |
27 | # convention, else the table becomes a real mess to understand and maintain. | |
28 | # | |
29 | # Note that these entries cannot be fully alphabetical. Don't try. | |
30 | # The order of matching is critical when multiple lines could match. | |
31 | ||
b7577823 ILT |
32 | alpha-*-*) host64=true; HOST_64BIT_TYPE=long ;; |
33 | ||
34 | a29k-*-*) CC=${CC-u3cc}; AR=${AR-u3ar} ;; | |
35 | ||
36 | hppa*-*-hpux*) HDEFINES=-DHOST_HPPAHPUX ;; | |
37 | hppa*-*-hiux*) HDEFINES=-DHOST_HPPAHPUX ;; | |
38 | hppa*-*-bsd*) HDEFINES=-DHOST_HPPABSD ;; | |
39 | hppa*-*-osf*) HDEFINES=-DHOST_HPPAOSF ;; | |
40 | ||
41 | i[345]86-sequent-bsd*) HDEFINES=-Dshared=genshared ;; | |
42 | i[345]86-sequent-sysv4*) ;; | |
43 | i[345]86-sequent-sysv*) HDEFINES=-Dshared=genshared ;; | |
44 | i[345]86-ncr*-sysv4*) CC=${CC-/usr/ccs/ATT/cc} | |
45 | test -z "$CFLAGS" && CFLAGS=" " | |
46 | ;; | |
47 | i[345]86-*-go32*) test -z "$CC" && CC="i386-go32-gcc -fno-omit-frame-pointer -O2 -Wl,-S" | |
48 | AR=${AR-i386-go32-ar} | |
49 | RANLIB=${RANLIB-i386-go32-ranlib} | |
50 | ;; | |
51 | i[345]86-*-win32) test -z "$CC" && CC="i386-win32-gcc -O2" | |
52 | AR=${AR-i386-win32-ar} | |
53 | RANLIB=${RANLIB-i386-win32-ranlib} | |
54 | ;; | |
55 | ||
56 | mips-dec-*) HDEFINES="-G 4" ;; | |
57 | mips-sgi-irix3*) HDEFINES="-G 4" | |
58 | test -z "$LDFLAGS" && LDFLAGS=-lmalloc | |
59 | ;; | |
60 | mips-sgi-irix4*) HDEFINES="-G 4" | |
61 | test -z "$LDFLAGS" && LDFLAGS=-lmalloc | |
62 | ;; | |
63 | mips-*-sysv4*) ;; | |
64 | mips-*-sysv*) HDEFINES="-G 4" ;; | |
65 | mips-*-riscos*) HDEFINES="-G 4" ;; | |
66 | ||
67 | m68*-apollo*-sysv*) # sef@cygnus.com says this is how to compile | |
68 | # on an apollo in the SysV environment. | |
69 | test -z "$CC" && CC="cc -A nansi -A cpu,3000 -A runtype,any -A systype,any -DSHORT_ENUM_BUG -DUSG -U__STDC__ -Dm68000=mc68000" | |
70 | ;; | |
71 | m68*-hp-hpux*) HDEFINES=-DHOST_HP300HPUX ;; | |
72 | ||
73 | m88*-*-dgux*) test -z "$CC" && CC="gcc -Wall -ansi -D__using_DGUX" | |
74 | ;; | |
75 | ||
76 | romp-*-*) # hc/pcc just can't cut it | |
77 | CC=${CC-gcc} | |
78 | ;; | |
79 | ||
80 | rs6000-*-aix4) HDEFINES=-DHOST_AIX ;; | |
81 | rs6000-*-*) HDEFINES=-DHOST_AIX ;; | |
82 | powerpc-*-aix4*) HDEFINES=-DHOST_AIX ;; | |
83 | powerpc-*-aix*) HDEFINES=-DHOST_AIX ;; | |
60ac749c ILT |
84 | |
85 | esac |