OSDN Git Service

2001-08-28 Eric Christopher <echristo@redhat.com>
[pf3gnuchains/gcc-fork.git] / libstdc++-v3 / configure.target
1 # configure.target
2
3 # This shell script handles all target based configuration for libstdc++.
4 # It sets various shell variables based on the the target and the
5 # configuration options.  You can modify this shell script without
6 # needing to rerun autoconf.
7
8 # This shell script should be invoked as
9 #   . configure.target
10 # If it encounters an error, it will exit with a message.
11
12 # It uses the following shell variables:
13 #   target                The configuration target
14 #   target_cpu            The configuration target CPU
15 #   target_os             The configuration target OS
16 #   target_optspace       --enable-target-optspace ("yes", "no", "")
17
18 # It possibly modifies the following shell variables:
19 #   cpu_include_dir        CPU-specific include directory, relative to srcdir
20 #   os_include_dir         OS-specific include directory, relative to srcdir
21
22
23 # Set any CPU dependent compiler flags.
24 # THIS TABLE IS SORTED.  KEEP IT THAT WAY.
25
26 case "${target_cpu}" in
27   alpha*)
28     cpu_include_dir="config/cpu/alpha"
29     ;;
30   arm*)
31     cpu_include_dir="config/cpu/arm"
32     ;;
33   ia64)
34     cpu_include_dir="config/cpu/ia64"
35     ;;
36   i386)
37     cpu_include_dir="config/cpu/i386"
38     ;;
39   i486 | i586 | i686 | i786)
40     cpu_include_dir="config/cpu/i486"
41     ;;
42   m68k | m680[246]0)
43     cpu_include_dir="config/cpu/m68k"
44     ;;
45   powerpc | rs6000)
46     cpu_include_dir="config/cpu/powerpc"
47     ;;
48   s390 | s390x)
49     cpu_include_dir="config/cpu/s390"
50     ;;
51   sparc64 | ultrasparc)
52     cpu_include_dir="config/cpu/sparc/sparc64"
53     ;;
54   sparc*)
55     cpu_include_dir="config/cpu/sparc/sparc32"
56     ;;
57   *)
58     cpu_include_dir="config/cpu/generic"
59     ;;
60 esac
61
62
63 # Set any OS dependent compiler flags.
64 # THIS TABLE IS SORTED.  KEEP IT THAT WAY.
65
66 case "${target_os}" in
67   aix4.[3456789]* | aix[56789]*)
68     os_include_dir="config/os/aix"
69     ;;
70   bsd* | freebsd* )
71     os_include_dir="config/os/bsd/freebsd"
72     ;;
73   cygwin*)
74     os_include_dir="config/os/newlib"
75     ;;
76   *djgpp*)
77     os_include_dir="config/os/djgpp"
78     ;;
79   linux* | gnu*)
80     os_include_dir="config/os/gnu-linux"
81     ;;
82   irix[1-6] | irix[1-5].* | irix6.[0-4])
83    # This is known to work on at least IRIX 5.2 and 6.3.
84    os_include_dir="config/os/irix/irix5.2"
85    ;;
86   irix6.5)
87     os_include_dir="config/os/irix/irix6.5"
88     ;;
89   netbsd*)
90     os_include_dir="config/os/bsd/netbsd"
91     ;;
92   solaris2.5*)
93     os_include_dir="config/os/solaris/solaris2.5"
94     ;;
95   solaris2.6*)
96     os_include_dir="config/os/solaris/solaris2.6"
97     ;;
98   solaris2.7* | solaris2.8*)
99     os_include_dir="config/os/solaris/solaris2.7"
100     ;;
101   hpux)
102     os_include_dir="config/os/hpux"
103     ;;
104   *)
105     os_include_dir="config/os/generic"
106     ;;
107 esac
108
109
110 # Set any flags dependant on the full target triplet.
111 # THIS TABLE IS SORTED.  KEEP IT THAT WAY.
112
113 case "${target}" in
114    *-*-aix[456789]*)
115      # We set os_include_dir to config/os/aix only on AIX 4.3 and
116      # newer, but config/os/aix/bits/atomicity.h works on earlier
117      # versions of AIX 4.*, so we explicitly duplicate the directory
118      # here, because os_include_dir.
119      ATOMICITYH=config/os/aix
120      ;;
121    *-*-aix*)
122      ATOMICITYH=config/cpu/generic
123      ;;
124    *-*-irix*)
125      ATOMICITYH=$os_include_dir
126      ;;
127    *)
128      ATOMICITYH=$cpu_include_dir
129      ;;
130 esac
131
132 # Set LIMITSH to the directory where the configuration-dependent
133 # limits.h can be found.
134 # THIS TABLE IS SORTED.  KEEP IT THAT WAY.
135
136 case "${target}" in
137    i?86-*-*)
138      LIMITSH=config/cpu/i386
139      ;;
140    powerpc-*-*)
141      LIMITSH=config/cpu/powerpc
142      ;;
143    *)
144      LIMITSH=config/cpu/generic
145      ;;
146 esac