]>
Commit | Line | Data |
---|---|---|
d0941a31 PE |
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: | |
d0941a31 PE |
19 | # cpu_include_dir CPU-specific include directory, relative to srcdir |
20 | # os_include_dir OS-specific include directory, relative to srcdir | |
d0941a31 PE |
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 | powerpc | rs6000) | |
43 | cpu_include_dir="config/cpu/powerpc" | |
44 | ;; | |
45 | sparc64 | ultrasparc) | |
46 | cpu_include_dir="config/cpu/sparc/sparc64" | |
47 | ;; | |
48 | sparc*) | |
49 | cpu_include_dir="config/cpu/sparc/sparc32" | |
50 | ;; | |
51 | *) | |
52 | cpu_include_dir="config/cpu/generic" | |
53 | ;; | |
54 | esac | |
55 | ||
56 | ||
57 | # Set any OS dependent compiler flags. | |
58 | # THIS TABLE IS SORTED. KEEP IT THAT WAY. | |
59 | ||
60 | case "${target_os}" in | |
527b03ed | 61 | aix4.[3456789]* | aix[56789]*) |
d0941a31 | 62 | os_include_dir="config/os/aix" |
d0941a31 | 63 | ;; |
11b176c1 | 64 | bsd* | freebsd* ) |
f0bffd99 | 65 | os_include_dir="config/os/bsd/freebsd" |
d0941a31 | 66 | ;; |
c383aafd BK |
67 | cygwin*) |
68 | os_include_dir="config/os/newlib" | |
69 | ;; | |
6f87af20 LB |
70 | *djgpp*) |
71 | os_include_dir="config/os/djgpp" | |
72 | ;; | |
36efdf10 | 73 | linux* | gnu*) |
d0941a31 PE |
74 | os_include_dir="config/os/gnu-linux" |
75 | ;; | |
dd1f09c2 AO |
76 | irix[1-6] | irix[1-5].* | irix6.[0-4]) |
77 | # This is known to work on at least IRIX 5.2 and 6.3. | |
78 | os_include_dir="config/os/irix/irix5.2" | |
79 | ;; | |
80 | irix6.5) | |
81 | os_include_dir="config/os/irix/irix6.5" | |
d0941a31 | 82 | ;; |
11b176c1 | 83 | netbsd*) |
f0bffd99 | 84 | os_include_dir="config/os/bsd/netbsd" |
11b176c1 | 85 | ;; |
d0941a31 PE |
86 | solaris2.5*) |
87 | os_include_dir="config/os/solaris/solaris2.5" | |
88 | ;; | |
89 | solaris2.6*) | |
90 | os_include_dir="config/os/solaris/solaris2.6" | |
91 | ;; | |
92 | solaris2.7* | solaris2.8*) | |
93 | os_include_dir="config/os/solaris/solaris2.7" | |
94 | ;; | |
598730fe JL |
95 | hpux) |
96 | os_include_dir="config/os/hpux" | |
97 | ;; | |
d0941a31 PE |
98 | *) |
99 | os_include_dir="config/os/generic" | |
100 | ;; | |
101 | esac | |
102 | ||
103 | ||
104 | # Set any flags dependant on the full target triplet. | |
105 | # THIS TABLE IS SORTED. KEEP IT THAT WAY. | |
106 | ||
6414587c | 107 | case "${target}" in |
a75b7b0b AO |
108 | *-*-aix[456789]*) |
109 | # We set os_include_dir to config/os/aix only on AIX 4.3 and | |
110 | # newer, but config/os/aix/bits/atomicity.h works on earlier | |
111 | # versions of AIX 4.*, so we explicitly duplicate the directory | |
112 | # here, because os_include_dir. | |
113 | ATOMICITYH=config/os/aix | |
6414587c | 114 | ;; |
9c233cb3 AO |
115 | *-*-aix*) |
116 | ATOMICITYH=config/cpu/generic | |
117 | ;; | |
6414587c PE |
118 | *-*-irix*) |
119 | ATOMICITYH=$os_include_dir | |
120 | ;; | |
6414587c | 121 | *) |
6e138b89 | 122 | ATOMICITYH=$cpu_include_dir |
6414587c PE |
123 | ;; |
124 | esac | |
9f3c078e MM |
125 | |
126 | # Set LIMITSH to the directory where the configuration-dependent | |
127 | # limits.h can be found. | |
128 | # THIS TABLE IS SORTED. KEEP IT THAT WAY. | |
129 | ||
130 | case "${target}" in | |
131 | i?86-*-*) | |
132 | LIMITSH=config/cpu/i386 | |
133 | ;; | |
134 | *) | |
135 | LIMITSH=config/cpu/generic | |
136 | ;; | |
137 | esac |